3 #ifndef GAUDIMATH_NUMERICALDEFINITEINTEGRAL_H
4 #define GAUDIMATH_NUMERICALDEFINITEINTEGRAL_H 1
14 #include "GaudiKernel/StatusCode.h"
18 #include "GaudiMath/Integration.h"
22 #include "CLHEP/GenericFunctions/AbsFunction.hh"
27 namespace GaudiMathImplementation
72 class GAUDI_API NumericalDefiniteIntegral :
public AbsFunction
80 typedef std::vector<double> Points ;
85 FUNCTION_OBJECT_DEF( NumericalDefiniteIntegral )
140 NumericalDefiniteIntegral
141 ( const AbsFunction& function ,
149 const
double epsabs = 1.e-10 ,
150 const
double epsrel = 1.e-7 ,
151 const
size_t size = 1000 );
182 NumericalDefiniteIntegral
183 ( const AbsFunction& function ,
187 const Points& points ,
188 const
double epsabs = 1e-9 ,
189 const
double epsrel = 1.e-6 ,
190 const
size_t size = 1000 ) ;
218 NumericalDefiniteIntegral
219 ( const AbsFunction& function ,
224 const
double epsabs = 1e-9 ,
225 const
double epsrel = 1.e-6 ,
226 const
size_t size = 1000 ) ;
253 NumericalDefiniteIntegral
254 ( const AbsFunction& function ,
258 const
double epsabs = 1e-9 ,
259 const
double epsrel = 1.e-6 ,
260 const
size_t size = 1000 ) ;
285 NumericalDefiniteIntegral
286 ( const AbsFunction& function ,
291 const
float epsabs = 1e-9 ,
292 const
float epsrel = 1.e-6 ,
293 const
size_t size = 1000 ) ;
296 NumericalDefiniteIntegral ( const NumericalDefiniteIntegral& ) ;
299 virtual ~NumericalDefiniteIntegral() ;
304 virtual
unsigned int dimensionality()
const {
return m_DIM ; }
307 virtual double operator() (
double argument )
const ;
309 virtual double operator() (
const Argument& argument )
const ;
312 virtual bool hasAnalyticDerivative()
const {
return true ;}
320 const AbsFunction&
function ()
const {
return *m_function ; }
322 double a ()
const {
return m_a ; }
323 double b ()
const {
return m_b ; }
325 const Points& points ()
const {
return m_points ; }
327 double epsabs ()
const {
return m_epsabs ; }
329 double epsrel ()
const {
return m_epsrel ; }
332 double result ()
const {
return m_result ; }
334 double error ()
const {
return m_error ; }
337 size_t size ()
const {
return m_size ; }
341 type ()
const {
return m_type ; }
344 category ()
const {
return m_category ; }
347 rule ()
const {
return m_rule ; }
352 double QAGI ( _Function*
fun )
const ;
354 double QAGP ( _Function*
fun )
const ;
356 double QNG ( _Function*
fun )
const ;
358 double QAG ( _Function*
fun )
const ;
360 double QAGS ( _Function*
fun )
const ;
363 _Workspace* allocate ()
const ;
365 _Workspace* ws ()
const
370 (
const std::string& message ,
376 NumericalDefiniteIntegral();
378 NumericalDefiniteIntegral& operator=(
const NumericalDefiniteIntegral& );
382 const AbsFunction* m_function ;
401 mutable double m_result ;
402 mutable double m_error ;
405 mutable _Workspace* m_ws ;
407 mutable Argument m_argument ;
408 mutable Argument m_argF ;
418 #endif // GAUDIMATH_NUMERICALDEFINITEINTEGRAL_H
Category
integration category
Genfun::GaudiMathImplementation::NumericalDerivative Derivative
This class is used for returning status codes from appropriate routines.
Type
type of integration (for finite limits)
double fun(const std::vector< double > &x)
GaudiMath.h GaudiMath/GaudiMath.h.
KronrodRule
integration rule
Type
the list of available types for ntuples
collection of common types for classes NumericalIndefiniteIntegral and NumericalDefiniteIntegral ...