| # Gaudi Framework, version v25r0 |

Home |  | Generated: Mon Feb 17 2014

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
Genfun::GaudiMathImplementation::GSLFunctionWithError Class Reference

`#include <GSLFunAdapters.h>`

Inheritance diagram for Genfun::GaudiMathImplementation::GSLFunctionWithError:
[legend]
Collaboration diagram for Genfun::GaudiMathImplementation::GSLFunctionWithError:
[legend]

## Public Types
typedef int(* | Function )(double, gsl_sf_result *)
| the actual type of the function

## Public Member Functions
| GSLFunctionWithError (Function function)
| mandatory macro from CLHEP/GenericFunctions
| GSLFunctionWithError (const GSLFunctionWithError &)
| copy constructor
virtual | ~GSLFunctionWithError ()
| 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_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
| GSLFunctionWithError ()
GSLFunctionWithError & | operator= (const GSLFunctionWithError &)

## Private Attributes
Function | m_function
gsl_sf_result * | m_result

## Detailed Description

Definition at line 32 of file GSLFunAdapters.h.

## Member Typedef Documentation

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

the actual type of the function

Definition at line 36 of file GSLFunAdapters.h.

## Constructor & Destructor Documentation

Genfun::GaudiMathImplementation::GSLFunctionWithError::GSLFunctionWithError | ( | GSLFunctionWithError::Function | function | ) |

mandatory macro from CLHEP/GenericFunctions

constructor with pointer to function

Definition at line 31 of file GSLFunAdapters.cpp.

: AbsFunction()
, m_function ( function )
, m_result ( new gsl_sf_result() )
{
m_result -> val = -1.e+10 ;
m_result -> err = -1.e+10 ;
}

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

copy constructor

Definition at line 41 of file GSLFunAdapters.cpp.

: AbsFunction()
, m_function ( func.m_function )
, m_result ( new gsl_sf_result() )
{
m_result -> val = func.m_result -> val ;
m_result -> err = func.m_result -> err ;
}

Genfun::GaudiMathImplementation::GSLFunctionWithError::~GSLFunctionWithError | ( |  | ) |
| virtual

destructor

Definition at line 50 of file GSLFunAdapters.cpp.

{ if ( 0 != m_result ) { delete m_result ; } }

Genfun::GaudiMathImplementation::GSLFunctionWithError::GSLFunctionWithError | ( |  | ) |
| private

## Member Function Documentation

virtual unsigned int Genfun::GaudiMathImplementation::GSLFunctionWithError::dimensionality | ( |  | ) | const
| inline virtual

Definition at line 51 of file GSLFunAdapters.h.

{ return 1 ; }

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

get the error in the last estimate of the result

Definition at line 85 of file GSLFunAdapters.cpp.

{ return m_result -> err ; }

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

get the function itself

Definition at line 79 of file GSLFunAdapters.cpp.

{ return m_function ; }

virtual bool Genfun::GaudiMathImplementation::GSLFunctionWithError::hasAnalyticDerivative | ( |  | ) | const
| inline virtual

Definition at line 50 of file GSLFunAdapters.h.

{ return true ; }

double Genfun::GaudiMathImplementation::GSLFunctionWithError::operator() | ( | double | x | ) | const
| virtual

the main method

Definition at line 54 of file GSLFunAdapters.cpp.

{
(*m_function)( x , m_result ) ;
return m_result -> val ;
}

virtual double Genfun::GaudiMathImplementation::GSLFunctionWithError::operator() | ( | const Argument & | x | ) | const
| virtual

GSLFunctionWithError& Genfun::GaudiMathImplementation::GSLFunctionWithError::operator= | ( | const GSLFunctionWithError & |  | ) |
| private

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

Definition at line 68 of file GSLFunAdapters.cpp.

{
if( i >= 1 )
{
const AbsFunction& aux = GaudiMath::Constant( 0 , 1 ) ;
return Genfun::FunctionNoop( &aux ) ;
};
const AbsFunction& aux = GaudiMath::Derivative( *this , i) ;
return Genfun::FunctionNoop( &aux ) ;
}

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

get the last evaluated result

Definition at line 82 of file GSLFunAdapters.cpp.

{ return *m_result ; }

## Member Data Documentation

Function Genfun::GaudiMathImplementation::GSLFunctionWithError::m_function
| private

Definition at line 66 of file GSLFunAdapters.h.

gsl_sf_result* Genfun::GaudiMathImplementation::GSLFunctionWithError::m_result
| private

Definition at line 67 of file GSLFunAdapters.h.

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

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