cepgen is hosted by Hepforge, IPPP Durham
CepGen 1.2.5
Central exclusive processes event generator
Loading...
Searching...
No Matches
Function1D Class Reference

Wrapper to a 1-dimensional function with optional parameters. More...

#include <CepGen/Utils/FunctionsWrappers.h>

Public Member Functions

 Function1D (const std::function< double(double)> &func)
 
 Function1D (const std::function< double(double, const ParametersList &)> &func)
 
 Function1D (const std::function< double(double, void *)> &func)
 
double operator() (double x, const ParametersList &params=ParametersList()) const
 Call the function with a user collection of parameters.
 
double operator() (double x, void *obj) const
 Call the function with an unspecified object as parameters.
 
template<typename T >
double operator() (double x, const T &obj) const
 Call the function with a templated object as parameters.
 
 operator const std::function< double (double)> &()
 
 operator const std::function< double (double, void *)> &()
 

Detailed Description

Definition at line 29 of file FunctionsWrappers.h.

Constructor & Destructor Documentation

◆ Function1D() [1/3]

Function1D ( const std::function< double(double)> &  func)
explicit

Definition at line 31 of file FunctionsWrappers.h.

◆ Function1D() [2/3]

Function1D ( const std::function< double(double, const ParametersList &)> &  func)
explicit

Definition at line 32 of file FunctionsWrappers.h.

◆ Function1D() [3/3]

Function1D ( const std::function< double(double, void *)> &  func)
explicit

Definition at line 33 of file FunctionsWrappers.h.

Member Function Documentation

◆ operator const std::function< double() [1/2]

operator const std::function< double ( double  ) &

Definition at line 53 of file FunctionsWrappers.h.

◆ operator const std::function< double() [2/2]

operator const std::function< double ( double  ,
void *   
) &

Definition at line 54 of file FunctionsWrappers.h.

◆ operator()() [1/3]

double operator() ( double  x,
const ParametersList params = ParametersList() 
) const

Definition at line 36 of file FunctionsWrappers.h.

◆ operator()() [2/3]

template<typename T >
double operator() ( double  x,
const T &  obj 
) const

Definition at line 49 of file FunctionsWrappers.h.

◆ operator()() [3/3]

double operator() ( double  x,
void *  obj 
) const

Definition at line 42 of file FunctionsWrappers.h.