| # Gaudi Framework, version v21r9 |

Home |  | Generated: 3 May 2010

# Genfun::GaudiMathImplementation Namespace Reference

## Classes
class | Constant
| Fixed constant function. More...
class | AdapterIFunction
| constructor from the IFunction ( see AIDA/IFunction.h) More...
class | Adapter2DoubleFunction
| constructor from the trivial function with two argument More...
class | Adapter3DoubleFunction
| constructor from the trivial function with two argument More...
class | SimpleFunction
class | GSLFunctionWithError
class | GSLFunctionWithMode
class | GSLFunctionWithModeAndError
class | NumericalDefiniteIntegral
| This class allows the numerical evaluation of the following functions:. More...
class | NumericalDerivative
| Numerical derivative (using GSL adaptive numerical differentiation). More...
class | NumericalIndefiniteIntegral
| The simple class for numerical integrations. More...
class | SplineBase
class | GSLSpline
class | GSLSplineDeriv
class | GSLSplineDeriv2
class | GSLSplineInteg
class | GSL_Helper
| the simple structure to be used for adaption interface `Genfun::AbsFunction` to `gsl_function` structure More...
## Typedefs
typedef Genfun::GaudiMathImplementation::SimpleFunction | GSLFunction
| the actual type for primitive adaptor
## Functions
double | GSL_Adaptor (double x, void *params)

## Typedef Documentation

typedef Genfun::GaudiMathImplementation::SimpleFunction Genfun::GaudiMathImplementation::GSLFunction

the actual type for primitive adaptor

Definition at line 30 of file GSLFunAdapters.h.

## Function Documentation

double Genfun::GaudiMathImplementation::GSL_Adaptor | ( | double | x,
|  | void * | params |
| ) |  |  |

Definition at line 35 of file Helpers.cpp.

    00036     {
    00037       // get parameters
    00038       GSL_Helper* aux = (GSL_Helper*) params ;
    00039       // decode parameters
    00040       const Genfun::AbsFunction& function = aux -> m_function  ;
    00041       const size_t               index    = aux -> m_index     ;
    00042       Genfun::Argument&          argument = aux -> m_argument  ;
    00043       // save the current value of argument
    00044       const double x_prev = argument[index] ;
    00045       // modify the argument
    00046       argument[index]= x       ;
    00047       // evaluate the function
    00048       const double fun = function( argument ) ;
    00049       // restore the argument
    00050       argument[index] = x_prev  ;
    00051       return fun ;
    00052     }