public class BaseNewtonVectorRootFinder extends VectorRootFinder implements NewtonVectorRootFinder
| Constructor and Description |
|---|
BaseNewtonVectorRootFinder(double absoluteTol,
double relativeTol,
int maxSteps,
NewtonRootFinderDirectionFunction directionFunction,
NewtonRootFinderMatrixInitializationFunction initializationFunction,
NewtonRootFinderMatrixUpdateFunction updateFunction) |
| Modifier and Type | Method and Description |
|---|---|
DoubleArray |
findRoot(Function<DoubleArray,DoubleArray> function,
DoubleArray startPosition)
Finds the root from the specified start position.
|
DoubleArray |
findRoot(Function<DoubleArray,DoubleArray> function,
Function<DoubleArray,DoubleMatrix> jacobianFunction,
DoubleArray startPosition)
Finds the root from the specified start position.
|
DoubleArray |
getRoot(Function<DoubleArray,DoubleArray> function,
DoubleArray startPosition) |
protected void |
updatePosition(DoubleArray p,
Function<DoubleArray,DoubleArray> function,
com.opengamma.strata.math.impl.rootfinding.newton.BaseNewtonVectorRootFinder.DataBundle data) |
checkInputsAndApplyFunction, getRootclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitbroyden, broyden, broydenpublic BaseNewtonVectorRootFinder(double absoluteTol,
double relativeTol,
int maxSteps,
NewtonRootFinderDirectionFunction directionFunction,
NewtonRootFinderMatrixInitializationFunction initializationFunction,
NewtonRootFinderMatrixUpdateFunction updateFunction)
public DoubleArray getRoot(Function<DoubleArray,DoubleArray> function, DoubleArray startPosition)
getRoot in class VectorRootFinderfunction - The (vector) function, not nullstartPosition - The starting point, not nullpublic DoubleArray findRoot(Function<DoubleArray,DoubleArray> function, DoubleArray startPosition)
NewtonVectorRootFinderThis applies the specified function to find the root. Note if multiple roots exist which one is found will depend on the start position.
findRoot in interface NewtonVectorRootFinderfunction - the vector functionstartPosition - the start position of the root finder forpublic DoubleArray findRoot(Function<DoubleArray,DoubleArray> function, Function<DoubleArray,DoubleMatrix> jacobianFunction, DoubleArray startPosition)
NewtonVectorRootFinderThis applies the specified function and Jacobian function to find the root. Note if multiple roots exist which one is found will depend on the start position.
findRoot in interface NewtonVectorRootFinderfunction - the vector functionjacobianFunction - the function to calculate the JacobianstartPosition - the start position of the root finder forprotected void updatePosition(DoubleArray p, Function<DoubleArray,DoubleArray> function, com.opengamma.strata.math.impl.rootfinding.newton.BaseNewtonVectorRootFinder.DataBundle data)
Copyright 2009-Present by OpenGamma Inc. and individual contributors
Apache v2 licensed
Additional documentation can be found at strata.opengamma.io.