1 #ifndef GAUDIMATH_NUMERICALDERIVATIVE_H 2 #define GAUDIMATH_NUMERICALDERIVATIVE_H 1 12 #include "CLHEP/GenericFunctions/AbsFunction.hh" 15 #if defined( __clang__ ) || defined( __CLING__ ) 16 #pragma clang diagnostic push 17 #pragma clang diagnostic ignored "-Winconsistent-missing-override" 18 #elif defined( __GNUC__ ) && __GNUC__ >= 5 19 #pragma GCC diagnostic push 20 #pragma GCC diagnostic ignored "-Wsuggest-override" 25 namespace GaudiMathImplementation
46 enum Type { Central, Forward, Backward };
100 double operator()(
double argument )
const override;
102 double operator()(
const Argument& argument )
const override;
108 Derivative partial(
unsigned int index )
const override;
112 const AbsFunction&
function()
const {
return *m_function; }
114 size_t index()
const {
return m_index; }
119 const Type& setType(
const Type& value );
122 double result()
const {
return m_result; }
124 double error()
const {
return m_error; }
151 #if defined( __clang__ ) || defined( __CLING__ ) 152 #pragma clang diagnostic pop 153 #elif defined( __GNUC__ ) && __GNUC__ >= 5 154 #pragma GCC diagnostic pop 160 #endif // GAUDIMATH_NUMERICALDERIVATIVE_H size_t index() const
index
bool hasAnalyticDerivative() const override
Does this function have an analytic derivative?
double error() const
the absolute error estimate for the last call
const Type & type() const
type
Type
the type of numerical differentiation
std::unique_ptr< const AbsFunction > m_function
Genfun::GaudiMathImplementation::NumericalDerivative Derivative
PropertyMgr & operator=(const PropertyMgr &)=delete
unsigned int dimensionality() const override
dimensionality of the problem
This class is used for returning status codes from appropriate routines.
Numerical derivative (using GSL adaptive numerical differentiation)
virtual Out operator()(const vector_of_const_< In > &inputs) const =0
double result() const
the result of the last call