#include <EvtItgFunction.hh>
Inheritance diagram for EvtItgFunction:
Public Member Functions | |
EvtItgFunction (double(*theFunction)(double), double lowerRange, double upperRange) | |
virtual double | getCoeff (int, int) |
void | getRange (double &lower, double &upper) const |
double | lowerRange () const |
virtual double | operator() (double x) const |
virtual void | setCoeff (int, int, double) |
double | upperRange () const |
virtual double | value (double x) const |
virtual | ~EvtItgFunction () |
Protected Member Functions | |
virtual double | myFunction (double x) const |
void | setRange (double x1, double x2) |
Private Member Functions | |
EvtItgFunction (const EvtItgFunction &) | |
EvtItgFunction & | operator= (const EvtItgFunction &) |
Private Attributes | |
double(* | _myFunction )(double x) |
Generic function where the pointer to the function is available.
The function is taken as type pointer to function returning double and taking a double (the abscissa) and a const RWTValVector<double> reference (the parameter values of the function) as arguments.
|
00036 : 00037 EvtItgAbsFunction(lowerRange, upperRange), 00038 _myFunction(theFunction) 00039 {}
|
|
00047 {}
|
|
|
|
Implements EvtItgAbsFunction. 00046 {return 0.0;};
|
|
00053 { lower = _lowerRange; upper = _upperRange; }
|
|
00052 {return _lowerRange;}
|
|
Implements EvtItgAbsFunction. 00051 { 00052 return _myFunction(x); 00053 }
|
|
00054 { 00055 return myFunction(x); 00056 }
|
|
|
|
Implements EvtItgAbsFunction. 00045 {};
|
|
00060 { _lowerRange=x1; _upperRange=x2; };
|
|
00051 {return _upperRange;}
|
|
00045 { 00046 if (x >= _lowerRange && x <= _upperRange) return myFunction(x); 00047 report(ERROR,"EvtGen") << "Error in EvtItgAbsFunction::value. Given co-ordinate " << x 00048 << " is outside of allowed range [" << _lowerRange << ", " 00049 << _upperRange << "]. Returning 0.0" << endl; 00050 return 0.0; // Never get here 00051 }
|
|
|