Index: /issm/trunk-jpl/src/c/classes/Cfdragcoeffabsgrad.h
===================================================================
--- /issm/trunk-jpl/src/c/classes/Cfdragcoeffabsgrad.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Cfdragcoeffabsgrad.h	(revision 28263)
@@ -9,6 +9,4 @@
 #include "./Definition.h"
 #include "./FemModel.h"
-
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum);
 
 class Cfdragcoeffabsgrad: public Object, public Definition{
Index: /issm/trunk-jpl/src/c/classes/Cfdragcoeffabsgradtransient.h
===================================================================
--- /issm/trunk-jpl/src/c/classes/Cfdragcoeffabsgradtransient.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Cfdragcoeffabsgradtransient.h	(revision 28263)
@@ -9,6 +9,4 @@
 #include "./Definition.h"
 class FemModel;
-
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum);
 
 class Cfdragcoeffabsgradtransient: public Object, public Definition{
Index: /issm/trunk-jpl/src/c/classes/Cflevelsetmisfit.h
===================================================================
--- /issm/trunk-jpl/src/c/classes/Cflevelsetmisfit.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Cflevelsetmisfit.h	(revision 28263)
@@ -9,6 +9,4 @@
 #include "./Definition.h"
 #include "./FemModel.h"
-
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum);
 
 class Cflevelsetmisfit: public Object, public Definition{
Index: /issm/trunk-jpl/src/c/classes/Cfrheologybbarabsgrad.h
===================================================================
--- /issm/trunk-jpl/src/c/classes/Cfrheologybbarabsgrad.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Cfrheologybbarabsgrad.h	(revision 28263)
@@ -9,7 +9,4 @@
 #include "./Definition.h"
 #include "./FemModel.h"
-
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum);
-void  GetVectorFromInputsx( IssmDouble** pvector, int* pvector_size, FemModel* femmodel,int name);
 
 class Cfrheologybbarabsgrad: public Object, public Definition{
Index: /issm/trunk-jpl/src/c/classes/Cfrheologybbarabsgradtransient.h
===================================================================
--- /issm/trunk-jpl/src/c/classes/Cfrheologybbarabsgradtransient.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Cfrheologybbarabsgradtransient.h	(revision 28263)
@@ -9,6 +9,4 @@
 #include "./Definition.h"
 class FemModel;
-
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum);
 
 class Cfrheologybbarabsgradtransient: public Object, public Definition{
Index: /issm/trunk-jpl/src/c/classes/Cfsurfacelogvel.h
===================================================================
--- /issm/trunk-jpl/src/c/classes/Cfsurfacelogvel.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Cfsurfacelogvel.h	(revision 28263)
@@ -9,6 +9,4 @@
 #include "./Definition.h"
 #include "./FemModel.h"
-
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum);
 
 class Cfsurfacelogvel: public Object, public Definition{
Index: /issm/trunk-jpl/src/c/classes/Cfsurfacesquare.h
===================================================================
--- /issm/trunk-jpl/src/c/classes/Cfsurfacesquare.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Cfsurfacesquare.h	(revision 28263)
@@ -9,6 +9,4 @@
 #include "./Definition.h"
 #include "./FemModel.h"
-
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum);
 
 class Cfsurfacesquare: public Object, public Definition{
Index: /issm/trunk-jpl/src/c/classes/Cfsurfacesquaretransient.h
===================================================================
--- /issm/trunk-jpl/src/c/classes/Cfsurfacesquaretransient.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Cfsurfacesquaretransient.h	(revision 28263)
@@ -9,6 +9,4 @@
 #include "./Definition.h"
 class FemModel;
-
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum);
 
 class Cfsurfacesquaretransient: public Object, public Definition{
Index: /issm/trunk-jpl/src/c/classes/DependentObject.cpp
===================================================================
--- /issm/trunk-jpl/src/c/classes/DependentObject.cpp	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/DependentObject.cpp	(revision 28263)
@@ -72,7 +72,10 @@
 void  DependentObject::RecordResponsex(FemModel* femmodel){/*{{{*/
 
+	int ierr;
+
 	/*Is this some special type of response for which we need to go in the output definitions? :*/
-	if (StringToEnumx(this->name,false)==-1){
-		this->response_value = OutputDefinitionsResponsex(femmodel,this->name);
+	if(StringToEnumx(this->name,false)==-1){
+		ierr = this->response_value = OutputDefinitionsResponsex(&this->response_value, femmodel, this->name);
+		if(ierr) _error_("Could not find response "<<this->name);
 	}
 	else{
Index: /issm/trunk-jpl/src/c/classes/FemModel.cpp
===================================================================
--- /issm/trunk-jpl/src/c/classes/FemModel.cpp	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/FemModel.cpp	(revision 28263)
@@ -2398,5 +2398,5 @@
 	/*Intermediaries*/
 	bool        isvec,results_on_nodes;
-	int         step,output_enum,numonnodes;
+	int         step,output_enum,numonnodes,ierr;
 	IssmDouble  time;
 	IssmDouble  double_result;
@@ -2422,7 +2422,9 @@
 		/*If string is not an enum, it is defined in output definitions*/
 		if(output_enum<0){
-			double_result = OutputDefinitionsResponsex(this,output_string);
+			ierr = OutputDefinitionsResponsex(&double_result, this,output_string);
 			if(save_results){
-				results->AddResult(new GenericExternalResult<IssmPDouble>(results->Size()+1,output_string,reCast<IssmPDouble>(double_result),step,time));
+				if(!ierr){
+					results->AddResult(new GenericExternalResult<IssmPDouble>(results->Size()+1,output_string,reCast<IssmPDouble>(double_result),step,time));
+				}
 				continue;
 			}
@@ -2431,7 +2433,9 @@
 			/*last chance for the output definition, if the enum is one of Outputdefinition[1-10]Enum:*/
 			if(output_enum>=Outputdefinition1Enum && output_enum <=Outputdefinition100Enum){
-				double_result = OutputDefinitionsResponsex(this,output_enum);
+				ierr = OutputDefinitionsResponsex(&double_result, this, output_enum);
 				if(save_results){
-					results->AddResult(new GenericExternalResult<IssmPDouble>(results->Size()+1,output_string,reCast<IssmPDouble>(double_result),step,time));
+					if(!ierr){
+						results->AddResult(new GenericExternalResult<IssmPDouble>(results->Size()+1,output_string,reCast<IssmPDouble>(double_result),step,time));
+					}
 					continue;
 				}
@@ -2757,6 +2761,6 @@
 		default:
 			if(response_descriptor_enum>=Outputdefinition1Enum && response_descriptor_enum <=Outputdefinition100Enum){
-				IssmDouble double_result = OutputDefinitionsResponsex(this,response_descriptor_enum);
-				*responses=double_result;
+				int ierr = OutputDefinitionsResponsex(responses, this,response_descriptor_enum);
+				if(ierr) _error_("could not evaluate response");
 			}
 			else _error_("response descriptor \"" << EnumToStringx(response_descriptor_enum) << "\" not supported yet!");
Index: /issm/trunk-jpl/src/c/classes/Massconaxpby.h
===================================================================
--- /issm/trunk-jpl/src/c/classes/Massconaxpby.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Massconaxpby.h	(revision 28263)
@@ -14,5 +14,5 @@
 #include "./FemModel.h"
 #include "../classes/Params/Parameters.h"
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,const char* output_string);
+int OutputDefinitionsResponsex(IssmDouble* pres, FemModel* femmodel,const char* output_string);
 /*}}}*/
 class Massconaxpby: public Object, public Definition{
@@ -108,9 +108,12 @@
 		 IssmDouble Response(FemModel* femmodel){/*{{{*/
 
+			 int ierr;
 			 IssmDouble xresponse,yresponse;
 
 			 /*Get response from both masscons: */
-			 xresponse=OutputDefinitionsResponsex(femmodel,this->namex);
-			 yresponse=OutputDefinitionsResponsex(femmodel,this->namey);
+			 ierr=OutputDefinitionsResponsex(&xresponse,femmodel,this->namex);
+			 if(ierr) _error_("not found");
+			 ierr=OutputDefinitionsResponsex(&yresponse,femmodel,this->namey);
+			 if(ierr) _error_("not found");
 
 			 return this->alpha*xresponse+this->beta*yresponse;
Index: /issm/trunk-jpl/src/c/classes/Misfit.cpp
===================================================================
--- /issm/trunk-jpl/src/c/classes/Misfit.cpp	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Misfit.cpp	(revision 28263)
@@ -19,4 +19,6 @@
 #include "./FemModel.h"
 #include "../modules/SurfaceAreax/SurfaceAreax.h"
+#include "../modules/OutputDefinitionsResponsex/OutputDefinitionsResponsex.h"
+#include "../modules/GetVectorFromInputsx/GetVectorFromInputsx.h"
 #include "../classes/Params/Parameters.h"
 #include "../classes/gauss/Gauss.h"
@@ -226,4 +228,5 @@
 
 		 IssmDouble model, observation;
+		 int ierr;
 
 		 /*If we are locked, return time average: */
@@ -231,5 +234,7 @@
 
 		 /*First, the global  model response: */
-		 model=OutputDefinitionsResponsex(femmodel,this->model_enum);
+		 ierr = OutputDefinitionsResponsex(&model, femmodel, this->model_enum);
+		 if(ierr) _error_("could not evaluate response");
+
 		 /*Now, the observation is buried inside the elements, go fish it in the first element (cludgy, needs fixing): */
 		 Element* element = (Element*)femmodel->elements->GetObjectByOffset(0); _assert_(element);
Index: /issm/trunk-jpl/src/c/classes/Misfit.h
===================================================================
--- /issm/trunk-jpl/src/c/classes/Misfit.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Misfit.h	(revision 28263)
@@ -9,7 +9,4 @@
 #include "./Definition.h"
 #include "./FemModel.h"
-
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum);
-void  GetVectorFromInputsx( IssmDouble** pvector, int* pvector_size, FemModel* femmodel,int name);
 
 class Misfit: public Object, public Definition{
Index: /issm/trunk-jpl/src/c/classes/Nodalvalue.h
===================================================================
--- /issm/trunk-jpl/src/c/classes/Nodalvalue.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Nodalvalue.h	(revision 28263)
@@ -13,5 +13,4 @@
 
 void NodalValuex( IssmDouble* pnodalvalue, int natureofdataenum,Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters);
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum);
 
 class Nodalvalue: public Object, public Definition{
Index: /issm/trunk-jpl/src/c/classes/Numberedcostfunction.h
===================================================================
--- /issm/trunk-jpl/src/c/classes/Numberedcostfunction.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Numberedcostfunction.h	(revision 28263)
@@ -9,6 +9,4 @@
 #include "./Definition.h"
 #include "./FemModel.h"
-
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum);
 
 class Numberedcostfunction: public Object, public Definition{
Index: /issm/trunk-jpl/src/c/classes/Radar.h
===================================================================
--- /issm/trunk-jpl/src/c/classes/Radar.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/classes/Radar.h	(revision 28263)
@@ -9,6 +9,4 @@
 #include "./Definition.h"
 #include "./FemModel.h"
-
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum);
 
 class Radar: public Object, public Definition{
Index: /issm/trunk-jpl/src/c/modules/OutputDefinitionsResponsex/OutputDefinitionsResponsex.cpp
===================================================================
--- /issm/trunk-jpl/src/c/modules/OutputDefinitionsResponsex/OutputDefinitionsResponsex.cpp	(revision 28262)
+++ /issm/trunk-jpl/src/c/modules/OutputDefinitionsResponsex/OutputDefinitionsResponsex.cpp	(revision 28263)
@@ -8,5 +8,5 @@
 #include "../../classes/classes.h"
 
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,const char* output_string){
+int OutputDefinitionsResponsex(IssmDouble* presponse, FemModel* femmodel,const char* output_string){
 
 	/*Ok, go find the output definitions dataset in the parameters, where our responses are hiding: */
@@ -21,11 +21,9 @@
 
 			/*This is the object that we have been chasing for. compute the response and return: */
-			IssmDouble return_value=definition->Response(femmodel);
+			*presponse = definition->Response(femmodel);
 
-			/*cleanup: */
+			/*cleanup and return*/
 			xDelete<char>(name);
-
-			/*return:*/
-			return return_value;
+			return 0;
 		}
 		xDelete<char>(name);
@@ -33,8 +31,16 @@
 
 	/*If we are here, did not find the definition for this response, not good!: */
-	_error_("Could not find the response for output definition " << output_string << " because could not find the definition itself!");
+	_printf0_("=================================================================\n");
+	_printf0_("WARNING: Could not find the output \"" << output_string << "\"\n");
+	_printf0_("         - either this output is unavailable for this model run \n");
+	_printf0_("         - or there may be a spelling error in your requested_outputs \n");
+	_printf0_("         - or there may be a spelling error in an outputdefinition \n");
+	_printf0_("           object name (unlikely)\n");
+	_printf0_("=================================================================\n");
+
+	return 1;
 }
 
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum){
+int OutputDefinitionsResponsex(IssmDouble* presponse, FemModel* femmodel,int output_enum){
 
 	/*Ok, go find the output definitions dataset in the parameters, where our responses are hiding: */
@@ -49,14 +55,18 @@
 
 			/*This is the object that we have been chasing for. compute the response and return: */
-			IssmDouble return_value=definition->Response(femmodel);
-
-			/*return:*/
-			return return_value;
+			*presponse = definition->Response(femmodel);
+			return 0;
 		}
 	}
 
 	/*If we are here, did not find the definition for this response, not good!: */
-	_error_("Could not find the response for output definition " << EnumToStringx(output_enum)
-				<<" ("<<output_enum<<")"
-				<< " because could not find the definition itself!");
+	_printf0_("=================================================================\n");
+	_printf0_("WARNING: Could not find the output \"" << EnumToStringx(output_enum)<< "\"\n");
+	_printf0_("         - either this output is unavailable for this model run \n");
+	_printf0_("         - or there may be a spelling error in your requested_outputs \n");
+	_printf0_("         - or there may be a spelling error in an outputdefinition \n");
+	_printf0_("           object name (unlikely)\n");
+	_printf0_("=================================================================\n");
+
+	return 1;
 }
Index: /issm/trunk-jpl/src/c/modules/OutputDefinitionsResponsex/OutputDefinitionsResponsex.h
===================================================================
--- /issm/trunk-jpl/src/c/modules/OutputDefinitionsResponsex/OutputDefinitionsResponsex.h	(revision 28262)
+++ /issm/trunk-jpl/src/c/modules/OutputDefinitionsResponsex/OutputDefinitionsResponsex.h	(revision 28263)
@@ -8,6 +8,6 @@
 
 /* local prototypes: */
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,const char* output_string);
-IssmDouble OutputDefinitionsResponsex(FemModel* femmodel,int output_enum);
+int OutputDefinitionsResponsex(IssmDouble* presponse, FemModel* femmodel,const char* output_string);
+int OutputDefinitionsResponsex(IssmDouble* presponse, FemModel* femmodel,int output_enum);
 
 #endif  /* _OUTPUTDEFINITIONSRESPONSEXX_H */
