org.apache.commons.math3.optim.nonlinear.scalar.gradient
Class NonLinearConjugateGradientOptimizer
java.lang.Object
org.apache.commons.math3.optim.BaseOptimizer<PAIR>
org.apache.commons.math3.optim.BaseMultivariateOptimizer<PointValuePair>
org.apache.commons.math3.optim.nonlinear.scalar.MultivariateOptimizer
org.apache.commons.math3.optim.nonlinear.scalar.GradientMultivariateOptimizer
org.apache.commons.math3.optim.nonlinear.scalar.gradient.NonLinearConjugateGradientOptimizer
public class NonLinearConjugateGradientOptimizer
- extends GradientMultivariateOptimizer
Non-linear conjugate gradient optimizer.
This class supports both the Fletcher-Reeves and the Polak-Ribière
update formulas for the conjugate search directions.
It also supports optional preconditioning.
- Since:
- 2.0
- Version:
- $Id: NonLinearConjugateGradientOptimizer.java 7721 2013-02-14 14:07:13Z CardosoP $
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
NonLinearConjugateGradientOptimizer
public NonLinearConjugateGradientOptimizer(NonLinearConjugateGradientOptimizer.Formula updateFormula,
ConvergenceChecker<PointValuePair> checker)
- Constructor with default
line search solver
and
preconditioner
.
- Parameters:
updateFormula
- formula to use for updating the β parameter,
must be one of NonLinearConjugateGradientOptimizer.Formula.FLETCHER_REEVES
or
NonLinearConjugateGradientOptimizer.Formula.POLAK_RIBIERE
.checker
- Convergence checker.
NonLinearConjugateGradientOptimizer
public NonLinearConjugateGradientOptimizer(NonLinearConjugateGradientOptimizer.Formula updateFormula,
ConvergenceChecker<PointValuePair> checker,
UnivariateSolver lineSearchSolver)
- Constructor with default
preconditioner
.
- Parameters:
updateFormula
- formula to use for updating the β parameter,
must be one of NonLinearConjugateGradientOptimizer.Formula.FLETCHER_REEVES
or
NonLinearConjugateGradientOptimizer.Formula.POLAK_RIBIERE
.checker
- Convergence checker.lineSearchSolver
- Solver to use during line search.
NonLinearConjugateGradientOptimizer
public NonLinearConjugateGradientOptimizer(NonLinearConjugateGradientOptimizer.Formula updateFormula,
ConvergenceChecker<PointValuePair> checker,
UnivariateSolver lineSearchSolver,
Preconditioner preconditioner)
- Parameters:
updateFormula
- formula to use for updating the β parameter,
must be one of NonLinearConjugateGradientOptimizer.Formula.FLETCHER_REEVES
or
NonLinearConjugateGradientOptimizer.Formula.POLAK_RIBIERE
.checker
- Convergence checker.lineSearchSolver
- Solver to use during line search.preconditioner
- Preconditioner.
optimize
public PointValuePair optimize(OptimizationData... optData)
throws TooManyEvaluationsException
- Stores data and performs the optimization.
The list of parameters is open-ended so that sub-classes can extend it
with arguments specific to their concrete implementations.
When the method is called multiple times, instance data is overwritten
only when actually present in the list of arguments: when not specified,
data set in a previous call is retained (and thus is optional in
subsequent calls).
- Overrides:
optimize
in class GradientMultivariateOptimizer
- Parameters:
optData
- Optimization data.
The following data will be looked for:
- Returns:
- a point/value pair that satifies the convergence criteria.
- Throws:
TooManyEvaluationsException
- if the maximal number of
evaluations (of the objective function) is exceeded.
doOptimize
protected PointValuePair doOptimize()
- Performs the bulk of the optimization algorithm.
- Specified by:
doOptimize
in class BaseOptimizer<PointValuePair>
- Returns:
- the point/value pair giving the optimal value of the
objective function.
Copyright © 2016 CNES. All Rights Reserved.