Class AbstractEvaluation
java.lang.Object
org.hipparchus.optim.nonlinear.vector.leastsquares.AbstractEvaluation
- All Implemented Interfaces:
 LeastSquaresProblem.Evaluation
An implementation of 
LeastSquaresProblem.Evaluation that is designed for extension. All of the
 methods implemented here use the methods that are left unimplemented.- 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptiondoubleGet the sum of the squares of the residuals.doublegetCost()Get the cost.getCovariances(double threshold) Get the covariance matrix of the optimized parameters.doublegetReducedChiSquare(int numberOfFittedParameters) Get the reduced chi-square.doublegetRMS()Get the normalized cost.getSigma(double covarianceSingularityThreshold) Get an estimate of the standard deviation of the parameters.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.hipparchus.optim.nonlinear.vector.leastsquares.LeastSquaresProblem.Evaluation
getJacobian, getPoint, getResiduals 
- 
Constructor Details
- 
AbstractEvaluation
protected AbstractEvaluation(int observationSize) Constructor.- Parameters:
 observationSize- the number of observations. Needed forgetRMS()andgetReducedChiSquare(int).
 
 - 
 - 
Method Details
- 
getCovariances
Get the covariance matrix of the optimized parameters.
Note that this operation involves the inversion of theJTJmatrix, whereJis the Jacobian matrix. Thethresholdparameter is a way for the caller to specify that the result of this computation should be considered meaningless, and thus trigger an exception.- Specified by:
 getCovariancesin interfaceLeastSquaresProblem.Evaluation- Parameters:
 threshold- Singularity threshold.- Returns:
 - the covariance matrix.
 
 - 
getSigma
Get an estimate of the standard deviation of the parameters. The returned values are the square root of the diagonal coefficients of the covariance matrix,sd(a[i]) ~= sqrt(C[i][i]), wherea[i]is the optimized value of thei-th parameter, andCis the covariance matrix.- Specified by:
 getSigmain interfaceLeastSquaresProblem.Evaluation- Parameters:
 covarianceSingularityThreshold- Singularity threshold (seecomputeCovariances).- Returns:
 - an estimate of the standard deviation of the optimized parameters
 
 - 
getRMS
public double getRMS()Get the normalized cost. It is the square-root of the sum of squared of the residuals, divided by the number of measurements.- Specified by:
 getRMSin interfaceLeastSquaresProblem.Evaluation- Returns:
 - the cost.
 
 - 
getCost
public double getCost()Get the cost. It is the square-root of theobjective function.- Specified by:
 getCostin interfaceLeastSquaresProblem.Evaluation- Returns:
 - the cost.
 - See Also:
 
 - 
getChiSquare
public double getChiSquare()Get the sum of the squares of the residuals.- Specified by:
 getChiSquarein interfaceLeastSquaresProblem.Evaluation- Returns:
 - the cost.
 - See Also:
 
 - 
getReducedChiSquare
public double getReducedChiSquare(int numberOfFittedParameters) Get the reduced chi-square.- Specified by:
 getReducedChiSquarein interfaceLeastSquaresProblem.Evaluation- Parameters:
 numberOfFittedParameters- Number of fitted parameters.- Returns:
 - the sum of the squares of the residuals divided by the number of degrees of freedom.
 
 
 -