Index: ../trunk-jpl/src/c/solutionsequences/convergence.cpp
===================================================================
--- ../trunk-jpl/src/c/solutionsequences/convergence.cpp	(revision 18618)
+++ ../trunk-jpl/src/c/solutionsequences/convergence.cpp	(revision 18619)
@@ -6,7 +6,7 @@
 #include "../modules/modules.h"
 #include "../shared/shared.h"
 
-void convergence(bool* pconverged, Matrix<IssmDouble>* Kff,Vector<IssmDouble>* pf,Vector<IssmDouble>* uf,Vector<IssmDouble>* old_uf,Parameters* parameters){
+void convergence(bool* pconverged, Matrix<IssmDouble>* Kff,Vector<IssmDouble>* pf,Vector<IssmDouble>* uf,Vector<IssmDouble>* old_uf,IssmDouble eps_res,IssmDouble eps_rel,IssmDouble eps_abs){
 
 	/*output*/
 	bool converged=false;
@@ -24,12 +24,6 @@
 	IssmDouble solver_residue,res;
 	int analysis_type;
 
-	/*convergence options*/
-	IssmDouble eps_res;
-	IssmDouble eps_rel;
-	IssmDouble eps_abs;
-	IssmDouble yts;
-
 	if(VerboseModule()) _printf0_("   checking convergence\n");
 
 	/*If uf is NULL in input, f-set is nil, model is fully constrained, therefore converged from 
@@ -39,20 +33,6 @@
 		return;
 	}
 
-	/*get convergence options*/
-	parameters->FindParam(&eps_res,StressbalanceRestolEnum);
-	// get analysis type
-	parameters->FindParam(&analysis_type,AnalysisTypeEnum);
-	if(analysis_type==StressbalanceAnalysisEnum)
-		parameters->FindParam(&eps_rel,StressbalanceReltolEnum);
-	else if(analysis_type==EnthalpyAnalysisEnum)
-		parameters->FindParam(&eps_rel,ThermalReltolEnum);
-	else
-		eps_rel = NAN;
-
-	parameters->FindParam(&eps_abs,StressbalanceAbstolEnum);
-	parameters->FindParam(&yts,ConstantsYtsEnum);
-
 	/*Display solver caracteristics*/
 	if (VerboseConvergence()){
 
@@ -138,15 +118,15 @@
 
 		//print
 		if (!xIsNan<IssmDouble>(eps_abs)){
-			if ((nduinf*yts)<eps_abs){
-				if(VerboseConvergence()) _printf0_(setw(50) << left << "   Convergence criterion: max(du)" << nduinf*yts << " < " << eps_abs << " m/yr\n");
+			if ((nduinf)<eps_abs){
+				if(VerboseConvergence()) _printf0_(setw(50) << left << "   Convergence criterion: max(du)" << nduinf << " < " << eps_abs << "\n");
 			}
 			else{
-				if(VerboseConvergence()) _printf0_(setw(50) << left << "   Convergence criterion: max(du)" << nduinf*yts << " > " << eps_abs << " m/yr\n");
+				if(VerboseConvergence()) _printf0_(setw(50) << left << "   Convergence criterion: max(du)" << nduinf << " > " << eps_abs << "\n");
 				converged=false;
 			}
 		}
-		else  _printf0_(setw(50) << left << "   Convergence criterion: max(du)" << nduinf*yts << " m/yr\n");
+		else  _printf0_(setw(50) << left << "   Convergence criterion: max(du)" << nduinf << "\n");
 
 	}
 
Index: ../trunk-jpl/src/c/solutionsequences/solutionsequence_newton.cpp
===================================================================
--- ../trunk-jpl/src/c/solutionsequences/solutionsequence_newton.cpp	(revision 18618)
+++ ../trunk-jpl/src/c/solutionsequences/solutionsequence_newton.cpp	(revision 18619)
@@ -29,12 +29,16 @@
 
 	/*parameters:*/
 	int max_nonlinear_iterations;
-	int  configuration_type;
+	int configuration_type;
+	IssmDouble eps_res,eps_rel,eps_abs;
 
 	/*Recover parameters: */
 	femmodel->parameters->FindParam(&max_nonlinear_iterations,StressbalanceMaxiterEnum);
 	femmodel->parameters->FindParam(&configuration_type,ConfigurationTypeEnum);
 	femmodel->parameters->FindParam(&newton,StressbalanceIsnewtonEnum);
+	femmodel->parameters->FindParam(&eps_res,StressbalanceRestolEnum);
+	femmodel->parameters->FindParam(&eps_rel,StressbalanceReltolEnum);
+	femmodel->parameters->FindParam(&eps_abs,StressbalanceAbstolEnum);
 	femmodel->UpdateConstraintsx();
 
 	count=1;
@@ -82,7 +86,7 @@
 		InputUpdateFromSolutionx(femmodel,ug);
 
 		/*Check convergence*/
-		convergence(&converged,Kff,pf,uf,old_uf,femmodel->parameters); 
+		convergence(&converged,Kff,pf,uf,old_uf,eps_res,eps_rel,eps_abs); 
 		delete Kff; delete pf;
 		if(converged==true){	
 			int step; IssmDouble time;
Index: ../trunk-jpl/src/c/solutionsequences/solutionsequence_stokescoupling_nonlinear.cpp
===================================================================
--- ../trunk-jpl/src/c/solutionsequences/solutionsequence_stokescoupling_nonlinear.cpp	(revision 18618)
+++ ../trunk-jpl/src/c/solutionsequences/solutionsequence_stokescoupling_nonlinear.cpp	(revision 18619)
@@ -32,10 +32,14 @@
 	int  min_mechanical_constraints;
 	int  max_nonlinear_iterations;
 	int  configuration_type;
+	IssmDouble eps_res,eps_rel,eps_abs;
 
 	/*Recover parameters: */
 	femmodel->parameters->FindParam(&min_mechanical_constraints,StressbalanceRiftPenaltyThresholdEnum);
 	femmodel->parameters->FindParam(&max_nonlinear_iterations,StressbalanceMaxiterEnum);
+	femmodel->parameters->FindParam(&eps_res,StressbalanceRestolEnum);
+	femmodel->parameters->FindParam(&eps_rel,StressbalanceReltolEnum);
+	femmodel->parameters->FindParam(&eps_abs,StressbalanceAbstolEnum);
 	femmodel->UpdateConstraintsx();
 
 	count=1;
@@ -67,7 +71,7 @@
 		Mergesolutionfromftogx(&ug_horiz, uf_horiz,ys,femmodel->nodes,femmodel->parameters); delete ys;
 		InputUpdateFromSolutionx(femmodel,ug_horiz);
 
-		convergence(&converged,Kff_horiz,pf_horiz,uf_horiz,old_uf_horiz,femmodel->parameters); delete Kff_horiz; delete pf_horiz; delete df_horiz;
+		convergence(&converged,Kff_horiz,pf_horiz,uf_horiz,old_uf_horiz,eps_res,eps_rel,eps_abs); delete Kff_horiz; delete pf_horiz; delete df_horiz;
 
 		/*Second compute vertical velocity: */
 		femmodel->SetCurrentConfiguration(StressbalanceVerticalAnalysisEnum);
Index: ../trunk-jpl/src/c/solutionsequences/solutionsequence_thermal_nonlinear.cpp
===================================================================
--- ../trunk-jpl/src/c/solutionsequences/solutionsequence_thermal_nonlinear.cpp	(revision 18618)
+++ ../trunk-jpl/src/c/solutionsequences/solutionsequence_thermal_nonlinear.cpp	(revision 18619)
@@ -30,22 +30,23 @@
 	int count;
 	int thermal_penalty_threshold;
 	int thermal_maxiter;
-	IssmDouble thermal_reltol;
 
 	/*parameters:*/
 	int  configuration_type;
+	IssmDouble eps_rel;
 
 	/*Recover parameters: */
 	femmodel->parameters->FindParam(&isenthalpy,ThermalIsenthalpyEnum);
 	femmodel->parameters->FindParam(&configuration_type,ConfigurationTypeEnum);
 	femmodel->parameters->FindParam(&thermal_maxiter,ThermalMaxiterEnum);
+	femmodel->parameters->FindParam(&eps_rel,ThermalReltolEnum);
 
 	converged=false;
 	InputUpdateFromConstantx(femmodel,converged,ConvergedEnum);
 
 	if(isenthalpy){
 		femmodel->parameters->FindParam(&isdynamicbasalspc,ThermalIsdynamicbasalspcEnum);
-		femmodel->parameters->FindParam(&thermal_reltol,ThermalReltolEnum);
+		femmodel->parameters->FindParam(&eps_rel,ThermalReltolEnum);
 		femmodel->UpdateConstraintsx();
 
 		//Update the solution to make sure that vx and vxold are similar (for next step in transient or steadystate)
@@ -72,7 +73,7 @@
 		Solverx(&tf, Kff, pf, tf_old, df, femmodel->parameters);
 		Mergesolutionfromftogx(&tg, tf,ys,femmodel->nodes,femmodel->parameters); delete ys;
 		if(isenthalpy){ 
-			convergence(&converged,Kff,pf,tf,tf_old,femmodel->parameters); 
+			convergence(&converged,Kff,pf,tf,tf_old,0.05,eps_rel,NAN); 
 			InputUpdateFromConstantx(femmodel,converged,ConvergedEnum);
 		}
 		delete Kff; delete pf; delete df;
Index: ../trunk-jpl/src/c/solutionsequences/solutionsequence_nonlinear.cpp
===================================================================
--- ../trunk-jpl/src/c/solutionsequences/solutionsequence_nonlinear.cpp	(revision 18618)
+++ ../trunk-jpl/src/c/solutionsequences/solutionsequence_nonlinear.cpp	(revision 18619)
@@ -30,10 +30,15 @@
 	int min_mechanical_constraints;
 	int max_nonlinear_iterations;
 	int configuration_type;
+	IssmDouble eps_res,eps_rel,eps_abs;
 
+
 	/*Recover parameters: */
 	femmodel->parameters->FindParam(&min_mechanical_constraints,StressbalanceRiftPenaltyThresholdEnum);
 	femmodel->parameters->FindParam(&max_nonlinear_iterations,StressbalanceMaxiterEnum);
+	femmodel->parameters->FindParam(&eps_res,StressbalanceRestolEnum);
+	femmodel->parameters->FindParam(&eps_rel,StressbalanceReltolEnum);
+	femmodel->parameters->FindParam(&eps_abs,StressbalanceAbstolEnum);
 	femmodel->parameters->FindParam(&configuration_type,ConfigurationTypeEnum);
 	femmodel->UpdateConstraintsx();
 
@@ -65,7 +70,7 @@
 		Solverx(&uf, Kff, pf, old_uf, df, femmodel->parameters);
 		Mergesolutionfromftogx(&ug, uf,ys,femmodel->nodes,femmodel->parameters);delete ys;
 
-		convergence(&converged,Kff,pf,uf,old_uf,femmodel->parameters); delete Kff; delete pf; delete df;
+		convergence(&converged,Kff,pf,uf,old_uf,eps_res,eps_rel,eps_abs); delete Kff; delete pf; delete df;
 		InputUpdateFromConstantx(femmodel,converged,ConvergedEnum);
 		InputUpdateFromSolutionx(femmodel,ug);
 
Index: ../trunk-jpl/src/c/solutionsequences/solutionsequences.h
===================================================================
--- ../trunk-jpl/src/c/solutionsequences/solutionsequences.h	(revision 18618)
+++ ../trunk-jpl/src/c/solutionsequences/solutionsequences.h	(revision 18619)
@@ -23,6 +23,6 @@
 void solutionsequence_adjoint_linear(FemModel* femmodel);
 
 /*convergence*/
-void convergence(bool* pconverged, Matrix<IssmDouble>* K_ff,Vector<IssmDouble>* p_f,Vector<IssmDouble>* u_f,Vector<IssmDouble>* u_f_old,Parameters* parameters);
+void convergence(bool* pconverged, Matrix<IssmDouble>* K_ff,Vector<IssmDouble>* p_f,Vector<IssmDouble>* u_f,Vector<IssmDouble>* u_f_old,IssmDouble eps_res,IssmDouble eps_rel,IssmDouble eps_abs);
 
 #endif
Index: ../trunk-jpl/src/m/classes/stressbalance.py
===================================================================
--- ../trunk-jpl/src/m/classes/stressbalance.py	(revision 18618)
+++ ../trunk-jpl/src/m/classes/stressbalance.py	(revision 18619)
@@ -172,7 +172,7 @@
 		WriteData(fid,'object',self,'class','stressbalance','fieldname','spcvz','format','DoubleMat','mattype',1,'scale',1./yts,'forcinglength',md.mesh.numberofvertices+1)
 		WriteData(fid,'object',self,'class','stressbalance','fieldname','restol','format','Double')
 		WriteData(fid,'object',self,'class','stressbalance','fieldname','reltol','format','Double')
-		WriteData(fid,'object',self,'class','stressbalance','fieldname','abstol','format','Double')
+		WriteData(fid,'object',self,'class','stressbalance','fieldname','abstol','format','Double','scale',1./yts)
 		WriteData(fid,'object',self,'class','stressbalance','fieldname','isnewton','format','Integer')
 		WriteData(fid,'object',self,'class','stressbalance','fieldname','FSreconditioning','format','Double')
 		WriteData(fid,'object',self,'class','stressbalance','fieldname','viscosity_overshoot','format','Double')
Index: ../trunk-jpl/src/m/classes/stressbalance.m
===================================================================
--- ../trunk-jpl/src/m/classes/stressbalance.m	(revision 18618)
+++ ../trunk-jpl/src/m/classes/stressbalance.m	(revision 18619)
@@ -222,7 +222,7 @@
 			WriteData(fid,'object',obj,'class','stressbalance','fieldname','spcvz','format','DoubleMat','mattype',1,'scale',1./yts,'forcinglength',md.mesh.numberofvertices+1);
 			WriteData(fid,'object',obj,'class','stressbalance','fieldname','restol','format','Double');
 			WriteData(fid,'object',obj,'class','stressbalance','fieldname','reltol','format','Double');
-			WriteData(fid,'object',obj,'class','stressbalance','fieldname','abstol','format','Double');
+			WriteData(fid,'object',obj,'class','stressbalance','fieldname','abstol','format','Double','scale',1./yts);
 			WriteData(fid,'object',obj,'class','stressbalance','fieldname','isnewton','format','Integer');
 			WriteData(fid,'object',obj,'class','stressbalance','fieldname','FSreconditioning','format','Double');
 			WriteData(fid,'object',obj,'class','stressbalance','fieldname','viscosity_overshoot','format','Double');
