PARTONS/NumA++  
Numerical Analysis C++ routines
Static Public Member Functions | List of all members
NumA::FunctorUtils Class Reference

Utilities for Functors. More...

Static Public Member Functions

template<typename PointerToObj , typename PointerToMemFn >
static Functor1D< PointerToObj, PointerToMemFn > * newFunctor1D (PointerToObj *object, PointerToMemFn function)
 Defines a new functor with the given one-dimensional function. More...
 
template<typename PointerToObj , typename PointerToMemFn >
static FunctorMD< PointerToObj, PointerToMemFn > * newFunctorMD (PointerToObj *object, PointerToMemFn function)
 Defines a new functor with the given multi-dimensional function. More...
 

Detailed Description

Utilities for Functors.

Member Function Documentation

◆ newFunctor1D()

template<typename PointerToObj , typename PointerToMemFn >
static Functor1D<PointerToObj, PointerToMemFn>* NumA::FunctorUtils::newFunctor1D ( PointerToObj *  object,
PointerToMemFn  function 
)
inlinestatic

Defines a new functor with the given one-dimensional function.

See FunctionType1D documentation for an example.

Parameters
objectPointer to the object instantiating a class where the function is defined as a method.
functionReference to the function defining the functor. Should have the following signature:
double MyClass::myFunction(double variable, std::vector<double>& parameters);
Returns
Functor pointer.

◆ newFunctorMD()

template<typename PointerToObj , typename PointerToMemFn >
static FunctorMD<PointerToObj, PointerToMemFn>* NumA::FunctorUtils::newFunctorMD ( PointerToObj *  object,
PointerToMemFn  function 
)
inlinestatic

Defines a new functor with the given multi-dimensional function.

See FunctionTypeMD documentation for an example.

Parameters
objectPointer to the object instantiating a class where the function is defined as a method.
functionReference to the function defining the functor. Should have the signature:
double MyClass::myFunction(NumA::VectorD& variables, std::vector<double>& parameters);
Object representing a mathematical vector.
Definition: VectorD.h:33
Returns
Functor pointer.

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