1 #ifndef GAUDIMATH_NUMERICALDERIVATIVE_H
2 #define GAUDIMATH_NUMERICALDERIVATIVE_H 1
8 #include "GaudiKernel/StatusCode.h"
12 #include "CLHEP/GenericFunctions/AbsFunction.hh"
17 namespace GaudiMathImplementation
34 class GAUDI_API NumericalDerivative :
public AbsFunction
44 FUNCTION_OBJECT_DEF( NumericalDerivative )
84 ( const AbsFunction& function ,
90 ( const NumericalDerivative& right ) ;
93 virtual ~NumericalDerivative () =
default;
96 virtual
unsigned int dimensionality()
const {
return m_DIM ; }
99 virtual double operator() (
double argument )
const ;
101 virtual double operator() (
const Argument& argument )
const ;
104 virtual bool hasAnalyticDerivative()
const {
return true ;}
107 virtual Derivative partial (
unsigned int index )
const;
112 const AbsFunction&
function ()
const {
return *m_function ; }
114 size_t index ()
const {
return m_index ; }
116 const Type&
type ()
const {
return m_type ; }
122 double result ()
const {
return m_result ; }
124 double error ()
const {
return m_error ; }
129 (
const std::string& message ,
135 NumericalDerivative ();
137 NumericalDerivative& operator=(
const NumericalDerivative& ) ;
140 std::unique_ptr<const AbsFunction> m_function ;
145 mutable Argument m_argument ;
146 mutable double m_result ;
147 mutable double m_error ;
156 #endif // GAUDIMATH_NUMERICALDERIVATIVE_H
Genfun::GaudiMathImplementation::NumericalDerivative Derivative
This class is used for returning status codes from appropriate routines.
Type
the list of available types for ntuples