49 double newLower( lower ), newUpper( upper );
57 double& result )
const
60 return 0.5 * ( higher - lower ) *
65 for ( it = 1, j = 1; j < n - 1; j++ )
68 double itDouble( it );
72 double deltaX( ( higher - lower ) / itDouble );
74 double x( lower + 0.5 * deltaX );
76 for ( j = 1; j <= it; j++ ) {
81 result = 0.5 * ( result + ( higher - lower ) * sum / itDouble );
90 <<
"Warning in EvtItgAbsIntegrator::evaluate. Lower bound "
91 << lower <<
" of integral "
92 <<
" is less than lower bound " <<
m_myFunction.lowerRange()
93 <<
" of function. No contribution from this range will be counted."
100 <<
"Warning in EvtItgAbsIntegrator::evaluate. Upper bound "
101 << upper <<
" of integral "
102 <<
" is greater than upper bound " <<
m_myFunction.upperRange()
103 <<
" of function. No contribution from this range will be counted."
std::ostream & EvtGenReport(EvtGenSeverity severity, const char *facility=nullptr)
double trapezoid(double lower, double higher, int n, double &result) const
const EvtItgAbsFunction & m_myFunction
virtual double evaluateIt(double lower, double higher) const =0
double evaluate(double lower, double upper) const
void boundsCheck(double &, double &) const
double normalisation() const