11 #include "gsl/gsl_mode.h" 12 #include "gsl/gsl_sf_result.h" 24 namespace GaudiMathImplementation
30 , m_function (
function )
31 , m_result (
new gsl_sf_result() )
33 m_result -> val = -1.e+10 ;
34 m_result -> err = -1.e+10 ;
41 , m_result (
new gsl_sf_result() )
43 m_result -> val = func.
m_result -> val ;
44 m_result -> err = func.
m_result -> err ;
47 double GSLFunctionWithError::operator()
50 (*m_function)( x , m_result.get() ) ;
51 return m_result -> val ;
54 double GSLFunctionWithError::operator()
55 (
const Genfun::Argument& x )
const 57 (*m_function)( x[0] , m_result.get() ) ;
58 return m_result -> val ;
62 (
unsigned int i )
const 67 return Genfun::FunctionNoop( &aux ) ;
70 return Genfun::FunctionNoop( &aux ) ;
85 const gsl_mode_t&
mod )
88 , m_mode (
new gsl_mode_t() )
97 , m_mode (
new gsl_mode_t () )
102 double GSLFunctionWithMode::operator()
106 double GSLFunctionWithMode::operator()
107 (
const Genfun::Argument& x )
const 111 (
unsigned int i )
const 116 return Genfun::FunctionNoop( &aux ) ;
119 return Genfun::FunctionNoop( &aux ) ;
131 const gsl_mode_t& mod )
134 , m_mode (
new gsl_mode_t() )
146 , m_mode (
new gsl_mode_t () )
149 *m_mode = *(func.
m_mode) ;
154 double GSLFunctionWithModeAndError::operator()
161 double GSLFunctionWithModeAndError::operator()
162 (
const Genfun::Argument& x )
const 169 (
unsigned int i )
const 174 return Genfun::FunctionNoop( &aux ) ;
177 return Genfun::FunctionNoop( &aux ) ;
Function function() const
get the function itself
Function function() const
get the function itself
std::unique_ptr< gsl_mode_t > m_mode
const gsl_sf_result & result() const
get the last evaluated result
double(* Function)(double, gsl_mode_t)
the actual type of the function
const gsl_sf_result & result() const
get the last evaluated result
Genfun::GaudiMathImplementation::NumericalDerivative Derivative
int(* Function)(double, gsl_sf_result *)
the actual type of the function
mandatory macro from CLHEP/GenericFunctions
Genfun::Derivative partial(unsigned int i) const override
std::unique_ptr< gsl_sf_result > m_result
Genfun::Derivative partial(unsigned int i) const override
const gsl_mode_t & mode() const
get the current mode
std::unique_ptr< gsl_sf_result > m_result
Function function() const
get the function itself
Genfun::Derivative partial(unsigned int i) const override
GSLFunctionWithModeAndError()
const gsl_mode_t & mode() const
get the current mode
double error() const
get the error in the last estimate of the result
mandatory macro from CLHEP/GenericFunctions
Genfun::GaudiMathImplementation::Constant Constant
double error() const
get the error in the last estimate of the result
int(* Function)(double, gsl_mode_t, gsl_sf_result *)
the actual type of the function