| # Gaudi Framework, version v20r4
Generated: 8 Jan 2009

# Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError Class Reference

`#include <GSLFunAdapters.h>`

List of all members.

## Detailed Description

Definition at line 105 of file GSLFunAdapters.h.

## Public Types
typedef int(* | Function )(double, gsl_mode_t, gsl_sf_result *)
| the actual type of the function
## Public Member Functions
| FUNCTION_OBJECT_DEF (GSLFunctionWithModeAndError)
| mandatory macro from CLHEP/GenericFunctions
| GSLFunctionWithModeAndError (Function fun, const gsl_mode_t &mode)
| constructor with pointer to function
| GSLFunctionWithModeAndError (const GSLFunctionWithModeAndError &)
| copy constructor
virtual | ~GSLFunctionWithModeAndError ()
| destructor
virtual double | operator() (double x) const
| the main method
virtual double | operator() (const Argument &x) const
virtual bool | hasAnalyticDerivative () const
virtual unsigned int | dimensionality () const
Genfun::Derivative | partial (unsigned int i) const
Function | function () const
| get the function itself
const gsl_mode_t & | mode () const
| get the current mode
const gsl_sf_result & | result () const
| get the last evaluated result
double | error () const
| get the error in the last estimate of the result
## Private Member Functions
| GSLFunctionWithModeAndError ()
GSLFunctionWithModeAndError & | operator= (const GSLFunctionWithModeAndError &)
## Private Attributes
Function | m_function
gsl_mode_t * | m_mode
gsl_sf_result * | m_result

## Member Typedef Documentation

typedef int(* Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::Function)(double, gsl_mode_t, gsl_sf_result *)

the actual type of the function

## Constructor & Destructor Documentation

Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::GSLFunctionWithModeAndError | ( | Function | fun,
|  | const gsl_mode_t & | mode |
| ) |  |  |

constructor with pointer to function

Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::GSLFunctionWithModeAndError | ( | const GSLFunctionWithModeAndError & | func | ) |

copy constructor

Definition at line 156 of file GSLFunAdapters.cpp.

    00157       : AbsFunction()
    00158       , m_function ( func.m_function     )
    00159       , m_mode     ( new gsl_mode_t ()   )
    00160       , m_result   ( new gsl_sf_result() )
    00161     {
    00162       *m_mode         = *(func.m_mode)         ;
    00163       m_result -> val =   func.m_result -> val ;
    00164       m_result -> err =   func.m_result -> err ;
    00165     };

Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::~GSLFunctionWithModeAndError | ( |  | ) | `[virtual]`

destructor

Definition at line 167 of file GSLFunAdapters.cpp.

    00168     {
    00169       if ( 0 != m_mode   ) { delete m_mode    ; }
    00170       if ( 0 != m_result ) { delete m_result  ; }
    00171     }

Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::GSLFunctionWithModeAndError | ( |  | ) | `[private]`

## Member Function Documentation

Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::FUNCTION_OBJECT_DEF | ( | GSLFunctionWithModeAndError |  | ) |

mandatory macro from CLHEP/GenericFunctions

double Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::operator() | ( | double | x | ) | const`[virtual]`

the main method

Definition at line 174 of file GSLFunAdapters.cpp.

    00175     {
    00176       (*m_function)( x , *m_mode , m_result ) ;
    00177       return m_result -> val ;
    00178     };

virtual double Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::operator() | ( | const Argument & | x | ) | const`[virtual]`

virtual bool Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::hasAnalyticDerivative | ( |  | ) | const`[inline, virtual]`

Definition at line 126 of file GSLFunAdapters.h.

    00126 { return true ; }

virtual unsigned int Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::dimensionality | ( |  | ) | const`[inline, virtual]`

Definition at line 127 of file GSLFunAdapters.h.

    00127 { return    1 ; }

Genfun::Derivative Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::partial | ( | unsigned int | i | ) | const

Definition at line 188 of file GSLFunAdapters.cpp.

    00189     {
    00190       if( i >= 1 )
    00191       {
    00192         const AbsFunction& aux = GaudiMath::Constant( 0 , 1 ) ;
    00193         return Genfun::FunctionNoop( &aux ) ;
    00194       };
    00195       const AbsFunction& aux = GaudiMath::Derivative( *this , i) ;
    00196       return Genfun::FunctionNoop( &aux ) ;
    00197     };

GSLFunctionWithModeAndError::Function Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::function | ( |  | ) | const

get the function itself

Definition at line 200 of file GSLFunAdapters.cpp.

    00201     { return  m_function      ; }

const gsl_mode_t & Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::mode | ( |  | ) | const

get the current mode

Definition at line 204 of file GSLFunAdapters.cpp.

    00205     { return *m_mode          ; }

const gsl_sf_result & Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::result | ( |  | ) | const

get the last evaluated result

Definition at line 208 of file GSLFunAdapters.cpp.

    00209     { return *m_result        ; }

double Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::error | ( |  | ) | const

get the error in the last estimate of the result

Definition at line 212 of file GSLFunAdapters.cpp.

    00213     { return  m_result -> err ; }

GSLFunctionWithModeAndError& Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::operator= | ( | const GSLFunctionWithModeAndError & |  | ) | `[private]`

## Member Data Documentation

Function Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::m_function`[private]`

Definition at line 144 of file GSLFunAdapters.h.

gsl_mode_t* Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::m_mode`[private]`

Definition at line 145 of file GSLFunAdapters.h.

gsl_sf_result* Genfun::GaudiMathImplementation::GSLFunctionWithModeAndError::m_result`[private]`

Definition at line 146 of file GSLFunAdapters.h.

The documentation for this class was generated from the following files:

- /afs/cern.ch/sw/Gaudi/releases/GAUDI/GAUDI_v20r4/GaudiGSL/GaudiMath/GSLFunAdapters.h
- /afs/cern.ch/sw/Gaudi/releases/GAUDI/GAUDI_v20r4/GaudiGSL/src/Lib/GSLFunAdapters.cpp