MtxIntDiff.NumericGradDifference Method

procedure NumericGradDifference(Fun: TRealFunction; const Pars: TVec; const Consts: TVec; const ObjConst: TObjectArray; const Grad: TVec);

Numerical gradient by numerical differentiation using the forward difference quotient.

#NameDescription
1FunReal function of several variables.
2ParsFunction variables.
3ConstsArray of additional constants which can be used in math formula.
4ObjConstArray of additional constants (pointers) which can be used in math formula.
5GradReturns calculated gradient. If needed, Grad Length and Complex properties are adjusted automatically.

Result: stored in self (calling object)

Remarks:

Calculates the numerical gradient by numerical differentiation using the forward difference quotient. The NumericGradDifference procedure can be used with a very moderate ( >= 1.0e-4) precision requirement.

See Also: MtxIntDiff.NumericGradRichardson