| The Gaudi Framework v29r0 (ff2e7097)

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

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

Public Types | Public Member Functions | Private Attributes | List of all members
Genfun::GaudiMathImplementation::Adapter2DoubleFunction Class Reference

mandatory macro from CLHEP/GenericFunctions More...

`#include <GaudiMath/Adapters.h>`

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

## Public Types
typedef double(* | Function) (const double, const double)
| the actual type of the function "to be adapted" More...

## Public Member Functions
| Adapter2DoubleFunction (Function func)
| mandatory macro from CLHEP/GenericFunctions More...
| Adapter2DoubleFunction (const Adapter2DoubleFunction &)=default
| copy constructor More...
double | operator() (double x) const override
double | operator() (const Argument &x) const override
unsigned int | dimensionality () const override
bool | hasAnalyticDerivative () const override
| Does this function have an analytic derivative? More...
Genfun::Derivative | partial (unsigned int i) const override
| Derivatives. More...
double | operator() (const double x, const double y) const
Adapter2DoubleFunction & | operator= (const Adapter2DoubleFunction &)=delete

## Private Attributes
Function | m_func = nullptr

## Detailed Description

mandatory macro from CLHEP/GenericFunctions

constructor from the trivial function with two argument

double func( const double , const double ) ;
const AbsFuction& fun = Adapter2DoubleFunction( fun ) ;
// evaluate the function in point (1,2):
Argument arg(2) ;
arg[0] = 1 ;
arg[1] = 2 ;
double value = fun( arg ) ;

Parameters

  func | pointer to trivial function

Author
  Kirill Miklyaev kiril.nosp@m.lm@i.nosp@m.ris1..nosp@m.itep.nosp@m..ru
  Vanya BELYAEV Ivan..nosp@m.Bely.nosp@m.aev@i.nosp@m.tep..nosp@m.ru

Date
  2003-08-03

Definition at line 159 of file FunAdapters.h.

## Member Typedef Documentation

typedef double( * Genfun::GaudiMathImplementation::Adapter2DoubleFunction::Function) (const double, const double)

the actual type of the function "to be adapted"

Definition at line 163 of file FunAdapters.h.

## Constructor & Destructor Documentation

Genfun::GaudiMathImplementation::Adapter2DoubleFunction::Adapter2DoubleFunction | ( | Adapter2DoubleFunction::Function | func | ) |

mandatory macro from CLHEP/GenericFunctions

constructor

Definition at line 47 of file Adapter.cpp.

48 : AbsFunction(), m_func( func )
49 {
50 }
Genfun::GaudiMathImplementation::Adapter2DoubleFunction::m_func
Function m_func
Definition: FunAdapters.h:191
GaudiPluginService.cpluginsvc.func
func
Definition: cpluginsvc.py:229

Genfun::GaudiMathImplementation::Adapter2DoubleFunction::Adapter2DoubleFunction | ( | const Adapter2DoubleFunction & |  | ) |
| default

copy constructor

## Member Function Documentation

unsigned int Genfun::GaudiMathImplementation::Adapter2DoubleFunction::dimensionality | ( |  | ) | const
| inline override

Definition at line 178 of file FunAdapters.h.

178 { return 2; }

bool Genfun::GaudiMathImplementation::Adapter2DoubleFunction::hasAnalyticDerivative | ( |  | ) | const
| inline override

Does this function have an analytic derivative?

Definition at line 180 of file FunAdapters.h.

180 { return true; }

double Genfun::GaudiMathImplementation::Adapter2DoubleFunction::operator() | ( | double | x | ) | const
| override

Definition at line 52 of file Adapter.cpp.

52 { return m_func( x, 0 ); }
Genfun::GaudiMathImplementation::Adapter2DoubleFunction::m_func
Function m_func
Definition: FunAdapters.h:191

double Genfun::GaudiMathImplementation::Adapter2DoubleFunction::operator() | ( | const Argument & | x | ) | const
| override

double Genfun::GaudiMathImplementation::Adapter2DoubleFunction::operator() | ( | const double | x,
|  | const double | y
| ) |  | const

Definition at line 56 of file Adapter.cpp.

56 { return m_func( x, y ); }
Genfun::GaudiMathImplementation::Adapter2DoubleFunction::m_func
Function m_func
Definition: FunAdapters.h:191

Adapter2DoubleFunction& Genfun::GaudiMathImplementation::Adapter2DoubleFunction::operator= | ( | const Adapter2DoubleFunction & |  | ) |
| delete

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

Derivatives.

Definition at line 59 of file Adapter.cpp.

60 {
61 if ( i >= 2 ) {
62 GaudiMath::Constant aux{0, 2};
63 return Genfun::FunctionNoop( &aux );
64 }
65 GaudiMath::Derivative aux{*this, i};
66 return Genfun::FunctionNoop( &aux );
67 }
Genfun::GaudiMathImplementation::Constant
Fixed constant function.
Definition: Constant.h:31
Genfun::GaudiMathImplementation::NumericalDerivative
Numerical derivative (using GSL adaptive numerical differentiation)
Definition: NumericalDerivative.h:42

## Member Data Documentation

Function Genfun::GaudiMathImplementation::Adapter2DoubleFunction::m_func = nullptr
| private

Definition at line 191 of file FunAdapters.h.

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

- GaudiGSL/GaudiMath/FunAdapters.h
- GaudiGSL/src/Lib/Adapter.cpp