Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn > Class Template Reference

template<class ParentFunctor, typename PointerToObj, typename PointerToMemFn, typename PointerToGradMemFn>
class ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >

Functor Handler to Wrap pointers to member functions for the evaluation of the function and the gradient.

The member function type must be (XXX means any name is allowed) : double XXX ( double x) for 1D function and derivative evaluation double XXX (const double *x) for multi-dimensional function evaluation and double XXX (cost double *x, int icoord) for partial derivatives evaluation

Definition at line 293 of file Functor.h.

Public Member Functions

 MemGradFunHandler (const PointerToObj &pObj, PointerToMemFn pMemFn, PointerToGradMemFn pGradMemFn)
 constructor from a pointer to the class and a pointer to the function
 
 MemGradFunHandler (unsigned int dim, const PointerToObj &pObj, PointerToMemFn pMemFn, PointerToGradMemFn pGradMemFn)
 constructor from a pointer to the class and a pointer to the function
 
virtual ~MemGradFunHandler ()
 
BaseFuncClone () const
 
ImplFuncCopy () const
 
unsigned int NDim () const
 

Private Types

typedef ImplFunc::BaseFunc BaseFunc
 
typedef ParentFunctor::Impl ImplFunc
 

Private Member Functions

double DoDerivative (const double *x, unsigned int icoord) const
 
double DoDerivative (double x) const
 
double DoEval (const double *x) const
 
double DoEval (double x) const
 

Private Attributes

unsigned int fDim
 
PointerToGradMemFn fGradMemFn
 
PointerToMemFn fMemFn
 
PointerToObj fObj
 

#include <Math/Functor.h>

Inheritance diagram for ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >:
[legend]

Member Typedef Documentation

◆ BaseFunc

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
typedef ImplFunc::BaseFunc ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::BaseFunc
private

Definition at line 296 of file Functor.h.

◆ ImplFunc

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
typedef ParentFunctor::Impl ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::ImplFunc
private

Definition at line 295 of file Functor.h.

Constructor & Destructor Documentation

◆ MemGradFunHandler() [1/2]

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::MemGradFunHandler ( const PointerToObj &  pObj,
PointerToMemFn  pMemFn,
PointerToGradMemFn  pGradMemFn 
)
inline

constructor from a pointer to the class and a pointer to the function

Definition at line 302 of file Functor.h.

◆ MemGradFunHandler() [2/2]

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::MemGradFunHandler ( unsigned int  dim,
const PointerToObj &  pObj,
PointerToMemFn  pMemFn,
PointerToGradMemFn  pGradMemFn 
)
inline

constructor from a pointer to the class and a pointer to the function

Definition at line 310 of file Functor.h.

◆ ~MemGradFunHandler()

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
virtual ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::~MemGradFunHandler ( )
inlinevirtual

Definition at line 320 of file Functor.h.

Member Function Documentation

◆ Clone()

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
BaseFunc * ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::Clone ( ) const
inline

Definition at line 326 of file Functor.h.

◆ Copy()

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
ImplFunc * ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::Copy ( ) const
inline

Definition at line 323 of file Functor.h.

◆ DoDerivative() [1/2]

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
double ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::DoDerivative ( const double x,
unsigned int  icoord 
) const
inlineprivate

Definition at line 347 of file Functor.h.

◆ DoDerivative() [2/2]

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
double ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::DoDerivative ( double  x) const
inlineprivate

Definition at line 343 of file Functor.h.

◆ DoEval() [1/2]

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
double ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::DoEval ( const double x) const
inlineprivate

Definition at line 339 of file Functor.h.

◆ DoEval() [2/2]

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
double ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::DoEval ( double  x) const
inlineprivate

Definition at line 335 of file Functor.h.

◆ NDim()

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
unsigned int ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::NDim ( ) const
inline

Definition at line 329 of file Functor.h.

Member Data Documentation

◆ fDim

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
unsigned int ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::fDim
private

Definition at line 351 of file Functor.h.

◆ fGradMemFn

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
PointerToGradMemFn ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::fGradMemFn
private

Definition at line 354 of file Functor.h.

◆ fMemFn

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
PointerToMemFn ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::fMemFn
private

Definition at line 353 of file Functor.h.

◆ fObj

template<class ParentFunctor , typename PointerToObj , typename PointerToMemFn , typename PointerToGradMemFn >
PointerToObj ROOT::Math::MemGradFunHandler< ParentFunctor, PointerToObj, PointerToMemFn, PointerToGradMemFn >::fObj
mutableprivate

Definition at line 352 of file Functor.h.

  • math/mathcore/inc/Math/Functor.h