Logo ROOT   6.10/09
Reference Guide
List of all members | Public Member Functions | Private Member Functions | List of all members
ROOT::Math::IGradientMultiDim Class Referenceabstract

Gradient interface (abstract class) defining the signature for calculating the gradient of a multi-dimensional function.

Three methods are provided:

Concrete classes should derive from ROOT::Math::IGradientFunctionMultiDim and not from this class.

Definition at line 199 of file IFunction.h.

Public Member Functions

virtual ~IGradientMultiDim ()
 virual destructor More...
 
double Derivative (const double *x, unsigned int icoord=0) const
 Return the partial derivative with respect to the passed coordinate. More...
 
virtual void FdF (const double *x, double &f, double *df) const =0
 Optimized method to evaluate at the same time the function value and derivative at a point x. More...
 
virtual void Gradient (const double *x, double *grad) const =0
 Evaluate all the vector of function derivatives (gradient) at a point x. More...
 

Private Member Functions

virtual double DoDerivative (const double *x, unsigned int icoord) const =0
 function to evaluate the derivative with respect each coordinate. More...
 

#include <Math/IFunction.h>

Inheritance diagram for ROOT::Math::IGradientMultiDim:
[legend]

Constructor & Destructor Documentation

◆ ~IGradientMultiDim()

virtual ROOT::Math::IGradientMultiDim::~IGradientMultiDim ( )
inlinevirtual

virual destructor

Definition at line 204 of file IFunction.h.

Member Function Documentation

◆ Derivative()

double ROOT::Math::IGradientMultiDim::Derivative ( const double *  x,
unsigned int  icoord = 0 
) const
inline

Return the partial derivative with respect to the passed coordinate.

Definition at line 215 of file IFunction.h.

◆ DoDerivative()

virtual double ROOT::Math::IGradientMultiDim::DoDerivative ( const double *  x,
unsigned int  icoord 
) const
privatepure virtual

function to evaluate the derivative with respect each coordinate.

To be implemented by the derived class

Implemented in ROOT::Math::GradFunctor, ROOT::Math::LSResidualFunc, ROOT::Math::MultiNumGradFunction, ROOT::Math::MinimTransformFunction, and TPyMultiGradFunction.

◆ FdF()

virtual void ROOT::Math::IGradientMultiDim::FdF ( const double *  x,
double &  f,
double *  df 
) const
pure virtual

Optimized method to evaluate at the same time the function value and derivative at a point x.

Often both value and derivatives are needed and it is often more efficient to compute them at the same time. Derived class should implement this method if performances play an important role and if it is faster to evaluate value and derivative at the same time

Implemented in ROOT::Math::IGradientFunctionMultiDim, ROOT::Math::LSResidualFunc, and TPyMultiGradFunction.

◆ Gradient()

virtual void ROOT::Math::IGradientMultiDim::Gradient ( const double *  x,
double *  grad 
) const
pure virtual

Evaluate all the vector of function derivatives (gradient) at a point x.

Derived classes must re-implement if it is more efficient than evaluting one at a time

Implemented in ROOT::Math::IGradientFunctionMultiDim, ROOT::Math::LSResidualFunc, and TPyMultiGradFunction.


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