Package org.ddogleg.optimization.math
Class HessianBFGS_DDRM
java.lang.Object
org.ddogleg.optimization.math.HessianMath_DDRM
org.ddogleg.optimization.math.HessianBFGS_DDRM
- All Implemented Interfaces:
HessianBFGS,HessianMath
Uses DFP to estimate the Hessian and BFGS to estimate the inverse Hessian. See [1].
A more efficient way to do this would be to compute the Cholesky decomposition directly, then
use that for forward and inverse operations
[1] Jorge Nocedal,and Stephen J. Wright "Numerical Optimization" 2nd Ed. Springer 2006
-
Field Summary
Fields inherited from class org.ddogleg.optimization.math.HessianMath_DDRM
hessian, solver -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddivideRowsCols(DMatrixRMaj scaling) Applies row and column division using the scaling vector.voidinit(int numParameters) Initialize Hessian to be in its initial state with the specified dimensionsbooleanInitializes the solverbooleansolve(DMatrixRMaj Y, DMatrixRMaj step) Solves the system step = inv(B)*Yvoidupdate(DMatrixRMaj s, DMatrixRMaj y) Updates the Hessian using BFGSMethods inherited from class org.ddogleg.optimization.math.HessianMath_DDRM
extractDiagonals, getHessian, innerVectorHessian, setDiagonalsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.ddogleg.optimization.math.HessianMath
extractDiagonals, innerVectorHessian, setDiagonals
-
Constructor Details
-
HessianBFGS_DDRM
public HessianBFGS_DDRM(boolean computeInverse)
-
-
Method Details
-
divideRowsCols
Description copied from interface:HessianMathApplies row and column division using the scaling vector. B = inv(diag(s))*B*inv(diag(s))- Specified by:
divideRowsColsin interfaceHessianMath- Overrides:
divideRowsColsin classHessianMath_DDRM
-
init
public void init(int numParameters) Description copied from interface:HessianMathInitialize Hessian to be in its initial state with the specified dimensions- Specified by:
initin interfaceHessianMath- Overrides:
initin classHessianMath_DDRM- Parameters:
numParameters- Number of optimization parameters. Hessian will be N by N
-
update
Description copied from interface:HessianBFGSUpdates the Hessian using BFGS- Specified by:
updatein interfaceHessianBFGS- Parameters:
s- change in state (new - old)y- change in gradient (new - old)
-
initializeSolver
public boolean initializeSolver()Description copied from interface:HessianMathInitializes the solver- Specified by:
initializeSolverin interfaceHessianMath- Overrides:
initializeSolverin classHessianMath_DDRM- Returns:
- true if successful
-
solve
Description copied from interface:HessianMathSolves the system step = inv(B)*Y- Specified by:
solvein interfaceHessianMath- Overrides:
solvein classHessianMath_DDRM- Parameters:
Y- (Input) vectorstep- (output) vector
-