Class StochasticNewtonMethod
java.lang.Object
net.finmath.rootfinder.StochasticNewtonMethod
- All Implemented Interfaces:
StochasticRootFinderUsingDerivative
Implementation of Newtons method for maps on random variables.
- Version:
- 1.0
- Author:
- Christian Fries, Stefan Sedlmair
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescription -
Method Summary
Modifier and TypeMethodDescriptiondoubleintbooleanisDone()voidsetValueAndDerivative(RandomVariable value, RandomVariable derivative)
-
Constructor Details
-
StochasticNewtonMethod
public StochasticNewtonMethod(RandomVariable guess, StochasticNewtonMethod.MethodForAccuracy method) - Parameters:
guess-RandomVariablerepresenting a first guess to start of the Newton Methodmethod- defines the Method used to gain the accuracy for the Newton Iteration
-
-
Method Details
-
getNextPoint
- Specified by:
getNextPointin interfaceStochasticRootFinderUsingDerivative- Returns:
- Next point for which a value should be set using
setValue.
-
setValueAndDerivative
- Specified by:
setValueAndDerivativein interfaceStochasticRootFinderUsingDerivative- Parameters:
value- The value corresponding to the point returned by previousgetNextPointcall.derivative- The derivative corresponding to the point returned by previousgetNextPointcall.
-
getNumberOfIterations
public int getNumberOfIterations()- Specified by:
getNumberOfIterationsin interfaceStochasticRootFinderUsingDerivative- Returns:
- Returns the numberOfIterations.
-
getAccuracy
public double getAccuracy()- Specified by:
getAccuracyin interfaceStochasticRootFinderUsingDerivative- Returns:
- Returns the accuracy.
-
isDone
public boolean isDone()- Specified by:
isDonein interfaceStochasticRootFinderUsingDerivative- Returns:
- Returns true if further improvement is not possible.
-
getBestPoint
- Specified by:
getBestPointin interfaceStochasticRootFinderUsingDerivative- Returns:
- Best point obtained so far
-