IGLib  1.7.2
The IGLib base library EXTENDED - with other lilbraries and applications.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
IG.Num.ZeroFinderBase Class Referenceabstract

Base class for single variable nonlinear exuation solvers. More...

+ Inheritance diagram for IG.Num.ZeroFinderBase:
+ Collaboration diagram for IG.Num.ZeroFinderBase:

Public Member Functions

 ZeroFinderBase (IRealFunction function, double toleranceFunctionValue, int maxIterations, double maxStepSize, double numericalDifferentiationStep)
 Constructs a new solver for finding zeros of nonlinear functions. More...
 
 ZeroFinderBase (IRealFunction function, double initialGuess, double toleranceFunctionValue, int maxIterations, double maxStepSize, double numericalDifferentiationStep)
 Constructs a new solver for finding zeros of nonlinear functions. More...
 
 ZeroFinderBase (IRealFunction function, double initialGuess, double toleranceFunctionValue, int maxIterations)
 Constructs a new solver for finding zeros of nonlinear functions. More...
 
 ZeroFinderBase (IRealFunction function)
 Constructs a new solver for finding zeros of nonlinear functions. More...
 
 ZeroFinderBase (DlgFunctionValue function, DlgFunctionValue functionDerivative, double toleranceFunctionValue, int maxIterations, double maxStepSize, double numericalDifferentiationStep)
 Constructs a new solver for finding zeros of nonlinear functions. More...
 
 ZeroFinderBase (DlgFunctionValue function, DlgFunctionValue functionDerivative, double initialGuess, double toleranceFunctionValue, int maxIterations, double maxStepSize, double numericalDifferentiationStep)
 Constructs a new solver for finding zeros of nonlinear functions. More...
 
 ZeroFinderBase (DlgFunctionValue function, DlgFunctionValue functionDerivative, double initialGuess, double toleranceFunctionValue, int maxIterations)
 Constructs a new solver for finding zeros of nonlinear functions. More...
 
 ZeroFinderBase (DlgFunctionValue function, DlgFunctionValue functionDerivative)
 Constructs a new solver for finding zeros of nonlinear functions. More...
 
 ZeroFinderBase (DlgFunctionValue function)
 Constructs a new solver for finding zeros of nonlinear functions. More...
 
void SetFunction (DlgFunctionValue valueDelegate, DlgFunctionValue derivativeDelegate)
 Sets definition of the function whose zeros are searched for. More...
 
virtual double FunctionValue (double x)
 calculates and returns value of the function whose zeros are searched for at the specified value of independent variable. More...
 
virtual double FunctionDerivative (double x)
 calculates and returns derivative of the function whose zeros are searched for at the specified value of independent variable. More...
 
virtual double NumericalFunctionDerivative (double x)
 Calculates and returns numerical derivative of the function whose zero is searched for. More...
 
abstract void Solve ()
 Tries to find problem solution according to settings and solution data. More...
 

Static Public Member Functions

static void ExampleNewton ()
 Example where a nonlinear equation equation is solved by a solver class for finding zeros of a function by the Newton's method. More...
 
static void ExampleNewton (DlgFunctionValue function, DlgFunctionValue functionDerivative)
 Example where a nonlinear equation equation is solved by a solver class for finding zeros of a function by the Newton's method. More...
 
static double ExampleFunction (double x)
 Example function whose zero is searched for in the example. More...
 
static double ExampleFunctionDerivative (double x)
 Derivative of the example function whose zero is searched for in the example. More...
 

Protected Member Functions

virtual void ResetSolutionData ()
 Resets output data that contains information about the solution and solution procedure. More...
 
virtual void ResetProblemDependentData ()
 Resets data that is not valid any more when problem changes. More...
 
virtual void ResetSolutionAndProblemDependentData ()
 Resets the following data: More...
 

Protected Attributes

int _outputLevel = DefaultOutputLevel
 
int _maxIterations = DefaultMaxIterations
 
double _toleranceFunctionValue = DefaultToleranceFunctionValue
 
double _initialGuess = DefaultInitialGuess
 
double _maxStepSize = DefaultMaxStepSize
 
double _stepReductionFactor = DefaultStepReductionFactor
 
int _maxStepReductions = DefaultMaxStepReductions
 
double _numericalDifferentiationStep = DefaultNumericalDifferentiationStep
 
IRealFunction _function
 
int _numIterations = 0
 
int _numFunctionEvaluations = 0
 
int _numDerivativeEvaluations = 0
 
double _solution = double.NaN
 
double _functionValueInSolution = double.NaN
 
bool _isSolutionObtained = false
 
bool _recordLastFunctionValue = true
 
double _lastFunctionArgument = double.NaN
 

Static Protected Attributes

static int _defaultOutputLevel = 0
 
static int _defaultMaxiIterations = 1000
 
static double _defaultInitialGuess = 0
 
static double _defaultToleranceFunctionValue = 1.0e-6
 
static double _defaultMaxStepSize = double.MaxValue
 
static double _defaultStepReductionFactor = 4.0
 
static int _defaultMaxStepReductions = 20
 
static double _defaultNumericalDifferentiationStep = 1.0e-4
 

Properties

static int DefaultOutputLevel [get, set]
 Default output level for nonlinear equation solvers. More...
 
static int DefaultMaxIterations [get, set]
 Default value for the maximal number of iterations. More...
 
static double DefaultInitialGuess [get, set]
 Default value for the initial guess in solvers for finding zeros of nonlinear functions. More...
 
static double DefaultToleranceFunctionValue [get, set]
 Default tolerance on absolute value of the function in solution. More...
 
static double DefaultMaxStepSize [get, set]
 Default value for maximal step size. More...
 
static double DefaultStepReductionFactor [get, set]
 Default value for step reduction factor. More...
 
static int DefaultMaxStepReductions [get, set]
 Default value for maximal number of step reductions. More...
 
static double DefaultNumericalDifferentiationStep [get, set]
 Default value for the step size for numerical differentiation. More...
 
virtual int OutputLevel [get, set]
 Level of console output for nonlinear equation solvers. More...
 
virtual int MaxIterations [get, set]
 Maximal number of iterations. More...
 
virtual double ToleranceFunctionValue [get, set]
 Tolerance on absolute value of the function in solution. More...
 
double InitialGuess [get, set]
 Initial guess for finding function zero. More...
 
virtual double MaxStepSize [get, set]
 Default value maximal step size. More...
 
virtual double StepReductionFactor [get, set]
 Step reduction factor. More...
 
virtual int MaxStepReductions [get, set]
 Maximal number of step reductions. More...
 
virtual double NumericalDifferentiationStep [get, set]
 Step size for numerical differentiation. More...
 
IRealFunction Function [get, set]
 
virtual int NumIterations [get, protected set]
 Number of iterations performed up to the current point. More...
 
virtual int NumFunctionEvaluations [get, protected set]
 Number of function evaluations performed by the solution algorithm up to the current point. More...
 
virtual int NumDerivativeEvaluations [get, protected set]
 Number of function derivative evaluations performed by the solution algorithm up to the current point. More...
 
virtual double Solution [get, protected set]
 Calculated solution of the problem (i.e. zero of the function whose value is calculated by the FunctionValue method). More...
 
double FunctionValueInSolution [get, protected set]
 Value of the function whose zero is searched for in the calculated approximate solution. More...
 
bool IsSolutionObtained [get, protected set]
 Flag specifying whether the problem has been successfully solved. More...
 

Private Member Functions

 ZeroFinderBase ()
 Constructs a new solver for finding zeros of nonlinear functions. More...
 

Private Attributes

double _lastFunctionValue = double.NaN
 

Detailed Description

Base class for single variable nonlinear exuation solvers.

Constructor & Destructor Documentation

IG.Num.ZeroFinderBase.ZeroFinderBase ( IRealFunction  function,
double  toleranceFunctionValue,
int  maxIterations,
double  maxStepSize,
double  numericalDifferentiationStep 
)
inline

Constructs a new solver for finding zeros of nonlinear functions.

Parameters
functionFunction whose zeros are searched for. May also contain method for derivative calculation.
maxIterationsMaximal number of iteratioins.

If less or equal to 0 then the default value is taken.

Parameters
maxStepSizeMaximal step size.

If less or equal to 0 then default value is taken.

Parameters
numericalDifferentiationStepStep size for numerical differentiation (when used internally).

If less or equal to 0 then the default value is used.

IG.Num.ZeroFinderBase.ZeroFinderBase ( IRealFunction  function,
double  initialGuess,
double  toleranceFunctionValue,
int  maxIterations,
double  maxStepSize,
double  numericalDifferentiationStep 
)
inline

Constructs a new solver for finding zeros of nonlinear functions.

Parameters
functionFunction whose zeros are searched for. May also contain method for derivative calculation.
initialGuessInitial guess.
toleranceFunctionValueTolerance on absolute function value in solution.

If less or equal to 0 then the default value is taken.

Parameters
maxIterationsMaximal number of iteratioins.

If less or equal to 0 then the default value is taken.

Parameters
maxStepSizeMaximal step size.

If less or equal to 0 then default value is taken.

Parameters
numericalDifferentiationStepStep size for numerical differentiation (when used internally).

If less or equal to 0 then the default value is used.

IG.Num.ZeroFinderBase.ZeroFinderBase ( IRealFunction  function,
double  initialGuess,
double  toleranceFunctionValue,
int  maxIterations 
)
inline

Constructs a new solver for finding zeros of nonlinear functions.

Parameters
functionFunction whose zeros are searched for. May also contain method for derivative calculation.
initialGuessInitial guess.
toleranceFunctionValueTolerance on absolute function value in solution.

If less or equal to 0 then the default value is taken.

Parameters
maxIterationsMaximal number of iteratioins.

If less or equal to 0 then the default value is taken.

IG.Num.ZeroFinderBase.ZeroFinderBase ( IRealFunction  function)
inline

Constructs a new solver for finding zeros of nonlinear functions.

Parameters
functionFunction whose zeros are searched for.
IG.Num.ZeroFinderBase.ZeroFinderBase ( )
inlineprivate

Constructs a new solver for finding zeros of nonlinear functions.

IG.Num.ZeroFinderBase.ZeroFinderBase ( DlgFunctionValue  function,
DlgFunctionValue  functionDerivative,
double  toleranceFunctionValue,
int  maxIterations,
double  maxStepSize,
double  numericalDifferentiationStep 
)
inline

Constructs a new solver for finding zeros of nonlinear functions.

Parameters
functionFunction whose zeros are searched for.
functionDerivativeDerivative of the function whose zeros are searched for.

If null then derivatives will be calculated by numerical differentiation when necessary.

Parameters
toleranceFunctionValueTolerance on absolute function value in solution.

If less or equal to 0 then the default value is taken.

Parameters
maxIterationsMaximal number of iteratioins.

If less or equal to 0 then the default value is taken.

Parameters
maxStepSizeMaximal step size.

If less or equal to 0 then default value is taken.

Parameters
numericalDifferentiationStepStep size for numerical differentiation (when used internally).

If less or equal to 0 then the default value is used.

IG.Num.ZeroFinderBase.ZeroFinderBase ( DlgFunctionValue  function,
DlgFunctionValue  functionDerivative,
double  initialGuess,
double  toleranceFunctionValue,
int  maxIterations,
double  maxStepSize,
double  numericalDifferentiationStep 
)
inline

Constructs a new solver for finding zeros of nonlinear functions.

Parameters
functionFunction whose zeros are searched for.
functionDerivativeDerivative of the function whose zeros are searched for.

If null then derivatives will be calculated by numerical differentiation when necessary.

Parameters
initialGuessInitial guess.
toleranceFunctionValueTolerance on absolute function value in solution.

If less or equal to 0 then the default value is taken.

Parameters
maxIterationsMaximal number of iteratioins.

If less or equal to 0 then the default value is taken.

Parameters
maxStepSizeMaximal step size.

If less or equal to 0 then default value is taken.

Parameters
numericalDifferentiationStepStep size for numerical differentiation (when used internally).

If less or equal to 0 then the default value is used.

IG.Num.ZeroFinderBase.ZeroFinderBase ( DlgFunctionValue  function,
DlgFunctionValue  functionDerivative,
double  initialGuess,
double  toleranceFunctionValue,
int  maxIterations 
)
inline

Constructs a new solver for finding zeros of nonlinear functions.

Parameters
functionFunction whose zeros are searched for.
functionDerivativeDerivative of the function whose zeros are searched for.

If null then derivatives will be calculated by numerical differentiation when necessary.

Parameters
initialGuessInitial guess.
toleranceFunctionValueTolerance on absolute function value in solution.

If less or equal to 0 then the default value is taken.

Parameters
maxIterationsMaximal number of iteratioins.

If less or equal to 0 then the default value is taken.

IG.Num.ZeroFinderBase.ZeroFinderBase ( DlgFunctionValue  function,
DlgFunctionValue  functionDerivative 
)
inline

Constructs a new solver for finding zeros of nonlinear functions.

Parameters
functionFunction whose zeros are searched for.
functionDerivativeDerivative of the function whose zeros are searched for.

If null then derivatives will be calculated by numerical differentiation when necessary.

IG.Num.ZeroFinderBase.ZeroFinderBase ( DlgFunctionValue  function)
inline

Constructs a new solver for finding zeros of nonlinear functions.

Since function for calculation of function derivatives is not set, derivatives will be calculated numerically if needed.

Parameters
functionFunction whose zeros are searched for.

Member Function Documentation

void IG.Num.ZeroFinderBase.SetFunction ( DlgFunctionValue  valueDelegate,
DlgFunctionValue  derivativeDelegate 
)
inline

Sets definition of the function whose zeros are searched for.

Parameters
valueDelegateDelegate used for calculation of function values.
derivativeDelegateDelegate used for calculation of function derivatives.
virtual void IG.Num.ZeroFinderBase.ResetSolutionData ( )
inlineprotectedvirtual

Resets output data that contains information about the solution and solution procedure.

virtual void IG.Num.ZeroFinderBase.ResetProblemDependentData ( )
inlineprotectedvirtual

Resets data that is not valid any more when problem changes.

virtual void IG.Num.ZeroFinderBase.ResetSolutionAndProblemDependentData ( )
inlineprotectedvirtual

Resets the following data:

- output data that contains information about the solution and solution procedure

- data that is not valid any more when problem changes.

virtual double IG.Num.ZeroFinderBase.FunctionValue ( double  x)
inlinevirtual

calculates and returns value of the function whose zeros are searched for at the specified value of independent variable.

Parameters
xArgument of the function (value of independent variable) for which function value is returned.
Returns
Function value.

Delegate FunctionValueDelegate is used for calculation of function value.

Function remembers last evaluated values and stores them, which speeds up some operation such as evaluation of numerical derivatives. Last function argument is stored to the internal variable _lastFunctionArgument and function value at that argument is stored to the internal variable _lastFunctionValue. Before any function value is calculated, these variables have the value double.NaN. Fields are also reset to these values when definition of the function changes. Implementers of derived classes are responsible to restore this behavior if properties that interact with function definitions are overriden. If the _recordLastFunctionValue field is set to false then the last calculated value is not remembered. This is used e.g. in the NumericalFunctionDerivative method for calculation of numerical derivatives to switch off recording of the last function value when function is evaluated at perturbed parameters.

virtual double IG.Num.ZeroFinderBase.FunctionDerivative ( double  x)
inlinevirtual

calculates and returns derivative of the function whose zeros are searched for at the specified value of independent variable.

Parameters
xArgument of the function (value of independent variable) for which function derivative is returned.
Returns
Function value.

Delegate FunctionDerivativeDelegate is used for calculation of function value when it is defined (non-null).

If the derivative delegate (FunctionDerivativeDelegate) is not defined then function derivative is calculated numerically by the NumericalFunctionDerivative method.

virtual double IG.Num.ZeroFinderBase.NumericalFunctionDerivative ( double  x)
inlinevirtual

Calculates and returns numerical derivative of the function whose zero is searched for.

Parameters
xFunction argumebnt at which numerical derivative is calculated.

Property NumericalDifferentiationStep is used as step size for numerical differentiation.

This method uses the forward difference scheme for numerical differentiation.

abstract void IG.Num.ZeroFinderBase.Solve ( )
pure virtual

Tries to find problem solution according to settings and solution data.

This method must be overridden in derived classes.

Implemented in IG.Num.ZeroFinderNewton.

static void IG.Num.ZeroFinderBase.ExampleNewton ( )
inlinestatic

Example where a nonlinear equation equation is solved by a solver class for finding zeros of a function by the Newton's method.

Equation solved is defined by f(x) == 0, where the function f(x) is represented by the ExampleFunction method and its derivative by the ExampleFunctionDerivative method.

Class ZeroFinderNewton is used to solve the equation.

Referenced by IG.Script.AppTestShell.DevelopFunctionTestZeroFinderNewtonApp().

static void IG.Num.ZeroFinderBase.ExampleNewton ( DlgFunctionValue  function,
DlgFunctionValue  functionDerivative 
)
inlinestatic

Example where a nonlinear equation equation is solved by a solver class for finding zeros of a function by the Newton's method.

Parameters
functionDelegate used for calculation of values of the function whose zeros are searched for.
functionDerivativeDelegate used for calculation of derivatives of the function whose zeros are searched for.

Equation solved is defined by f(x) == 0, where the function f(x) is represented by the function delegate and its derivative by the functionDerivative delegate.

Class ZeroFinderNewton is used to solve the equation.

References IG.Num.ZeroFinderBase.FunctionValueInSolution, IG.Num.ZeroFinderBase.InitialGuess, IG.Num.ZeroFinderBase.IsSolutionObtained, IG.Num.ZeroFinderNewton.MaxIterations, IG.Num.ZeroFinderNewton.MaxStepSize, IG.Num.ZeroFinderBase.NumIterations, IG.Num.ZeroFinderBase.OutputLevel, IG.Num.ZeroFinderBase.Solution, IG.Num.ZeroFinderNewton.Solve(), and IG.Num.ZeroFinderBase.ToleranceFunctionValue.

static double IG.Num.ZeroFinderBase.ExampleFunction ( double  x)
inlinestatic

Example function whose zero is searched for in the example.

f(x) = exp(x) - 10

Equation to be solved: exp(x) == 10

static double IG.Num.ZeroFinderBase.ExampleFunctionDerivative ( double  x)
inlinestatic

Derivative of the example function whose zero is searched for in the example.

f(x) = exp(x) - 10

f'(x) = exp(x)

Equation to be solved: exp(x) == 10

Member Data Documentation

int IG.Num.ZeroFinderBase._defaultOutputLevel = 0
staticprotected
int IG.Num.ZeroFinderBase._defaultMaxiIterations = 1000
staticprotected
double IG.Num.ZeroFinderBase._defaultInitialGuess = 0
staticprotected
double IG.Num.ZeroFinderBase._defaultToleranceFunctionValue = 1.0e-6
staticprotected
double IG.Num.ZeroFinderBase._defaultMaxStepSize = double.MaxValue
staticprotected
double IG.Num.ZeroFinderBase._defaultStepReductionFactor = 4.0
staticprotected
int IG.Num.ZeroFinderBase._defaultMaxStepReductions = 20
staticprotected
double IG.Num.ZeroFinderBase._defaultNumericalDifferentiationStep = 1.0e-4
staticprotected
int IG.Num.ZeroFinderBase._outputLevel = DefaultOutputLevel
protected
int IG.Num.ZeroFinderBase._maxIterations = DefaultMaxIterations
protected
double IG.Num.ZeroFinderBase._toleranceFunctionValue = DefaultToleranceFunctionValue
protected
double IG.Num.ZeroFinderBase._initialGuess = DefaultInitialGuess
protected
double IG.Num.ZeroFinderBase._maxStepSize = DefaultMaxStepSize
protected
double IG.Num.ZeroFinderBase._stepReductionFactor = DefaultStepReductionFactor
protected
int IG.Num.ZeroFinderBase._maxStepReductions = DefaultMaxStepReductions
protected
double IG.Num.ZeroFinderBase._numericalDifferentiationStep = DefaultNumericalDifferentiationStep
protected
IRealFunction IG.Num.ZeroFinderBase._function
protected
int IG.Num.ZeroFinderBase._numIterations = 0
protected
int IG.Num.ZeroFinderBase._numFunctionEvaluations = 0
protected
int IG.Num.ZeroFinderBase._numDerivativeEvaluations = 0
protected
double IG.Num.ZeroFinderBase._solution = double.NaN
protected
double IG.Num.ZeroFinderBase._functionValueInSolution = double.NaN
protected
bool IG.Num.ZeroFinderBase._isSolutionObtained = false
protected
bool IG.Num.ZeroFinderBase._recordLastFunctionValue = true
protected
double IG.Num.ZeroFinderBase._lastFunctionArgument = double.NaN
protected
double IG.Num.ZeroFinderBase._lastFunctionValue = double.NaN
private

Property Documentation

int IG.Num.ZeroFinderBase.DefaultOutputLevel
staticgetset

Default output level for nonlinear equation solvers.

Output level defines to which extent operation of the solver is logged to the console.

int IG.Num.ZeroFinderBase.DefaultMaxIterations
staticgetset

Default value for the maximal number of iterations.

Must be greater or equal to 1.

double IG.Num.ZeroFinderBase.DefaultInitialGuess
staticgetset

Default value for the initial guess in solvers for finding zeros of nonlinear functions.

double IG.Num.ZeroFinderBase.DefaultToleranceFunctionValue
staticgetset

Default tolerance on absolute value of the function in solution.

Must be a positive value.

double IG.Num.ZeroFinderBase.DefaultMaxStepSize
staticgetset

Default value for maximal step size.

Must be greater than 0.

double IG.Num.ZeroFinderBase.DefaultStepReductionFactor
staticgetset

Default value for step reduction factor.

Must be greater than one.

By this factor, step size is reduced (sometimes iteratively) if improvement in solution quality is not achieved.

int IG.Num.ZeroFinderBase.DefaultMaxStepReductions
staticgetset

Default value for maximal number of step reductions.

Must be greater or equal to 0. 0 means that step reductions are not allowed.

In some algorithms, step size is reduced (sometimes iteratively) if improvement in solution quality is not achieved.

double IG.Num.ZeroFinderBase.DefaultNumericalDifferentiationStep
staticgetset

Default value for the step size for numerical differentiation.

Must be greater than 0.

Numerical differentiation is sometimes used if the zero searching algorithm uses derivatives and function derivative is not explicitly specified.

virtual int IG.Num.ZeroFinderBase.OutputLevel
getset

Level of console output for nonlinear equation solvers.

Output level defines to which extent operation of the solver is logged to the console.

Should be greater or equal to 0, 0 means no output is generated on the application's console.

Default value is specified by the ZeroFinderBase.DefaultOutputLevel property.

Referenced by IG.Num.ZeroFinderBase.ExampleNewton().

virtual int IG.Num.ZeroFinderBase.MaxIterations
getset

Maximal number of iterations.

Must be greater or equal to 1.

Default value is defined by the ZeroFinderBase.DefaultMaxIterations property.

virtual double IG.Num.ZeroFinderBase.ToleranceFunctionValue
getset

Tolerance on absolute value of the function in solution.

Must be a positive value.

Default value is defined by the ZeroFinderBase.DefaultToleranceFunctionValue property.

Referenced by IG.Num.ZeroFinderBase.ExampleNewton().

double IG.Num.ZeroFinderBase.InitialGuess
getset

Initial guess for finding function zero.

Default value is defined by the ZeroFinderBase.DefaultInitialGuess property.

Referenced by IG.Num.ZeroFinderBase.ExampleNewton().

virtual double IG.Num.ZeroFinderBase.MaxStepSize
getset

Default value maximal step size.

Must be greater than 0. Default value is specified by ZeroFinderBase.DefaultMaxStepSize.

With this value, step size during iterations is limited. This can be used as means of stabilization of the algorithm.

virtual double IG.Num.ZeroFinderBase.StepReductionFactor
getset

Step reduction factor.

Must be greater than one. Default value is ZeroFinderBase.DefaultStepReductionFactor.

By this factor, step size is reduced (sometimes iteratively) if improvement in solution quality is not achieved.

virtual int IG.Num.ZeroFinderBase.MaxStepReductions
getset

Maximal number of step reductions.

Must be greater or equal to 0. 0 means that step reductions are not allowed. Default value is ZeroFinderBase.DefaultMaxStepReductions.

In some algorithms, step size is reduced (sometimes iteratively) if improvement in solution quality is not achieved.

virtual double IG.Num.ZeroFinderBase.NumericalDifferentiationStep
getset

Step size for numerical differentiation.

Must be greater than 0.

Numerical differentiation is sometimes used if the zero searching algorithm uses derivatives and function derivative is not explicitly specified.

IRealFunction IG.Num.ZeroFinderBase.Function
getset
virtual int IG.Num.ZeroFinderBase.NumIterations
getprotected set

Number of iterations performed up to the current point.

After the algorithm completes, this contains the total number of iterations.

Referenced by IG.Num.ZeroFinderBase.ExampleNewton().

virtual int IG.Num.ZeroFinderBase.NumFunctionEvaluations
getprotected set

Number of function evaluations performed by the solution algorithm up to the current point.

After the algorithm completes, this contains the total number of function evaluations.

In the case that numerical differentiation is used, additional function evaluations that are used in numerical differentiation are counted in.

virtual int IG.Num.ZeroFinderBase.NumDerivativeEvaluations
getprotected set

Number of function derivative evaluations performed by the solution algorithm up to the current point.

After the algorithm completes, this contains the total number of derivative evaluations.

virtual double IG.Num.ZeroFinderBase.Solution
getprotected set

Calculated solution of the problem (i.e. zero of the function whose value is calculated by the FunctionValue method).

Valid if IsSolutionObtained == true.

Referenced by IG.Num.ZeroFinderBase.ExampleNewton().

double IG.Num.ZeroFinderBase.FunctionValueInSolution
getprotected set

Value of the function whose zero is searched for in the calculated approximate solution.

Valid if IsSolutionObtained == true.

Referenced by IG.Num.ZeroFinderBase.ExampleNewton().

bool IG.Num.ZeroFinderBase.IsSolutionObtained
getprotected set

Flag specifying whether the problem has been successfully solved.

Value becomes true after the solution algorithm is successfully performed and yields a solution that is within the prescribed tolerances. Otherwise, the value is false.

Referenced by IG.Num.ZeroFinderBase.ExampleNewton().


The documentation for this class was generated from the following file: