public abstract class AbstractLeastSquaresOptimizer extends BaseAbstractMultivariateVectorOptimizer<DifferentiableMultivariateVectorFunction> implements DifferentiableMultivariateVectorOptimizer
DifferentiableMultivariateVectorFunction.jacobian()
of the function argument in method
optimize and assumes that, in the matrix returned by the
value method, the rows
iterate on the model functions while the columns iterate on the parameters; thus,
the numbers of rows is equal to the length of the target array while the
number of columns is equal to the length of the startPoint array.| Modifier and Type | Method and Description |
|---|---|
double |
getChiSquare()
Get a Chi-Square-like value assuming the N residuals follow N
distinct normal distributions centered on 0 and whose variances are
the reciprocal of the weights.
|
double[][] |
getCovariances()
Get the covariance matrix of the optimized parameters.
|
double[][] |
getCovariances(double threshold)
Get the covariance matrix of the optimized parameters.
|
int |
getJacobianEvaluations() |
double |
getRMS()
Get the Root Mean Square value.
|
double[] |
guessParametersErrors()
Guess the errors in optimized parameters.
|
PointVectorValuePair |
optimize(int maxEval,
DifferentiableMultivariateVectorFunction f,
double[] target,
double[] weights,
double[] startPoint)
Optimize an objective function.
|
getConvergenceChecker, getEvaluations, getMaxEvaluations, getStartPointequals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetConvergenceChecker, getEvaluations, getMaxEvaluationspublic int getJacobianEvaluations()
public double getRMS()
public double getChiSquare()
public double[][] getCovariances()
SingularMatrixException - if the covariance matrix cannot be computed (singular problem).getCovariances(double)public double[][] getCovariances(double threshold)
JTJ matrix, where J is the
Jacobian matrix.
The threshold parameter is a way for the caller to specify
that the result of this computation should be considered meaningless,
and thus trigger an exception.threshold - Singularity threshold.SingularMatrixException - if the covariance matrix cannot be computed (singular problem).public double[] guessParametersErrors()
SingularMatrixException - if the covariances matrix cannot be computed.NumberIsTooSmallException - if the number of degrees of freedom is not
positive, i.e. the number of measurements is less or equal to the number of
parameters.public PointVectorValuePair optimize(int maxEval, DifferentiableMultivariateVectorFunction f, double[] target, double[] weights, double[] startPoint)
∑weighti(objectivei - targeti)2optimize in interface BaseMultivariateVectorOptimizer<DifferentiableMultivariateVectorFunction>optimize in class BaseAbstractMultivariateVectorOptimizer<DifferentiableMultivariateVectorFunction>maxEval - Maximum number of function evaluations.f - Objective function.target - Target value for the objective functions at optimum.weights - Weights for the least squares cost computation.startPoint - Start point for optimization.jHepWork 3.5 ©