@@ -102,6 +106,36 @@ void print_newmat(const NEWMAT::GeneralMatrix& m,
std::stringfname);
std::stringNonlinParam::TextStatus()const
{
switch(status){
caseNL_UNDEFINED:
return(std::string("Status is undefined. Object has been created but no minimisation has been performed"));
break;
caseNL_MAXITER:
return(std::string("The optimisation did not converge because the maximum number of iterations was exceeded"));
break;
caseNL_LM_MAXITER:
return(std::string("The optimisation did not converge because the maximum number of iterations for a single line minimisation was exceeded"));
break;
caseNL_PARCONV:
return(std::string("The optimisation converged. The convergence criterion was that the last step in parameter space was very short"));
break;
caseNL_GRADCONV:
return(std::string("The optimisation converged. The convergence criterion was that all the elements of the gradient were very small"));
break;
caseNL_CFCONV:
return(std::string("The optimisation converged. The convergence criterion was that the last step changed the cost-function by an insignificant amount"));
break;
caseNL_LCONV:
return(std::string("The optimisation converged. The convergence criterion was that lambda became too large"));
break;
default:
return(std::string("Impossible status. This indicates there is a bug"));
break;
}
}
// If user choses not to overide the grad-method of the NonlinCF
// base class this routine will be used to calculate numerical derivatives.