CLHEP 2.4.6.4
C++ Class Library for High Energy Physics
Loading...
Searching...
No Matches
Genfun::Exponential Class Reference

#include <Exponential.hh>

+ Inheritance diagram for Genfun::Exponential:

Public Member Functions

 Exponential ()
 
 Exponential (const Exponential &right)
 
virtual ~Exponential ()
 
virtual double operator() (double argument) const override
 
virtual double operator() (const Argument &a) const override
 
ParameterdecayConstant ()
 
const ParameterdecayConstant () const
 
Derivative partial (unsigned int) const override
 
virtual bool hasAnalyticDerivative () const override
 
- Public Member Functions inherited from Genfun::AbsFunction
 AbsFunction ()
 
 AbsFunction (const AbsFunction &right)
 
virtual ~AbsFunction ()
 
virtual unsigned int dimensionality () const
 
virtual double operator() (double argument) const =0
 
virtual double operator() (const Argument &argument) const =0
 
virtual AbsFunctionclone () const =0
 
virtual FunctionComposition operator() (const AbsFunction &f) const
 
virtual ParameterComposition operator() (const AbsParameter &p) const
 
Derivative derivative (const Variable &v) const
 
Derivative prime () const
 
virtual bool hasAnalyticDerivative () const
 
virtual Derivative partial (unsigned int) const
 

Detailed Description

Author

Definition at line 20 of file Exponential.hh.

Constructor & Destructor Documentation

◆ Exponential() [1/2]

Genfun::Exponential::Exponential ( )

Definition at line 11 of file Exponential.cc.

11 :
12 _decayConstant("Decay Constant", 1.0, 0,10)
13{}

◆ Exponential() [2/2]

Genfun::Exponential::Exponential ( const Exponential right)

Definition at line 15 of file Exponential.cc.

15 :
16 AbsFunction(right),
17 _decayConstant(right._decayConstant)
18{
19}

◆ ~Exponential()

Genfun::Exponential::~Exponential ( )
virtual

Definition at line 21 of file Exponential.cc.

21 {
22}

Member Function Documentation

◆ decayConstant() [1/2]

Parameter & Genfun::Exponential::decayConstant ( )

Definition at line 29 of file Exponential.cc.

29 {
30 return _decayConstant;
31}

◆ decayConstant() [2/2]

const Parameter & Genfun::Exponential::decayConstant ( ) const

Definition at line 33 of file Exponential.cc.

33 {
34 return _decayConstant;
35}

◆ hasAnalyticDerivative()

virtual bool Genfun::Exponential::hasAnalyticDerivative ( ) const
inlineoverridevirtual

Reimplemented from Genfun::AbsFunction.

Definition at line 47 of file Exponential.hh.

47{return true;}

◆ operator()() [1/2]

virtual double Genfun::Exponential::operator() ( const Argument a) const
inlineoverridevirtual

Implements Genfun::AbsFunction.

Definition at line 37 of file Exponential.hh.

37{return operator() (a[0]);}
virtual double operator()(double argument) const override
Definition: Exponential.cc:24

◆ operator()() [2/2]

double Genfun::Exponential::operator() ( double  argument) const
overridevirtual

Implements Genfun::AbsFunction.

Definition at line 24 of file Exponential.cc.

24 {
25 if (x<0) return 0;
26 return exp(-x/_decayConstant.getValue())/_decayConstant.getValue();
27}
virtual double getValue() const
Definition: Parameter.cc:29

Referenced by operator()().

◆ partial()

Derivative Genfun::Exponential::partial ( unsigned int  index) const
overridevirtual

Reimplemented from Genfun::AbsFunction.

Definition at line 48 of file Exponential.cc.

48 {
49 assert(index==0);
50 const AbsFunction & fPrime = -_decayConstant*(*this);
51 return Derivative(&fPrime);
52}
FunctionNoop Derivative
Definition: AbsFunction.hh:42

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