Class implements adapter for gsl_function_fdf. More...

#include <GslFunctionFdfAdapter.hpp>

Inheritance diagram for julian::GslFunctionFdfAdapter< F, dF >:

Public Member Functions

 GslFunctionFdfAdapter (const F &kf, const dF &kdf)
 Constructor. More...
 

Static Private Member Functions

static double call_f (double x, void *params)
 Method called by the GSL algorithm. More...
 
static double call_df (double x, void *params)
 Method called by the GSL algorithm. More...
 
static void call_fdf (double x, void *params, double *f, double *df)
 Method called by the GSL algorithm. More...
 

Private Attributes

const F & f_
 F must be a functor. More...
 
const dF & df_
 dF must be a functor. dF is derivative of F. More...
 

Detailed Description

template<typename F, typename dF>
class julian::GslFunctionFdfAdapter< F, dF >

Class implements adapter for gsl_function_fdf.

Class implements adapter for gsl_function_fdf. Class wraps callable class F and dF so that it can be statically casted to gsl_function_fdf. F must be a functor with overloaded double operator()(double) implementing value of the function. dF must be a functor with overloaded double operator()(double) implementing derivative of the function.

Constructor & Destructor Documentation

template<typename F, typename dF>
julian::GslFunctionFdfAdapter< F, dF >::GslFunctionFdfAdapter ( const F &  kf,
const dF &  kdf 
)
inline

Constructor.

F must be a functor with overloaded double operator()(double) implementing value of the function. dF must be a functor with overloaded double operator()(double) implementing derivative of the function.

Member Function Documentation

template<typename F, typename dF>
static double julian::GslFunctionFdfAdapter< F, dF >::call_df ( double  x,
void *  params 
)
inlinestaticprivate

Method called by the GSL algorithm.

Returns
Returns derivative of gsl_function_fdf for x.
template<typename F, typename dF>
static double julian::GslFunctionFdfAdapter< F, dF >::call_f ( double  x,
void *  params 
)
inlinestaticprivate

Method called by the GSL algorithm.

Returns
Returns value of called gsl_function_fdf for x.
template<typename F, typename dF>
static void julian::GslFunctionFdfAdapter< F, dF >::call_fdf ( double  x,
void *  params,
double *  f,
double *  df 
)
inlinestaticprivate

Method called by the GSL algorithm.

Returns
Returns by reference value of gsl_function_fdf and derivative of gsl_function_fdf for x.

Member Data Documentation

template<typename F, typename dF>
const dF& julian::GslFunctionFdfAdapter< F, dF >::df_
private

dF must be a functor. dF is derivative of F.

template<typename F, typename dF>
const F& julian::GslFunctionFdfAdapter< F, dF >::f_
private

F must be a functor.


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