CMS 3D CMS Logo

Public Member Functions | Private Member Functions

LandauFluctuationGenerator Class Reference

#include <LandauFluctuationGenerator.h>

Inheritance diagram for LandauFluctuationGenerator:
BaseNumericalRandomGenerator

List of all members.

Public Member Functions

virtual double function (double x)
 The probability density function implementation.
double landau () const
 Random generator of the dE/dX spread (Landau function)
 LandauFluctuationGenerator (const RandomEngine *engine)
 Constructor : initialization of the Random Generator.
virtual ~LandauFluctuationGenerator ()
 Default destructor.

Private Member Functions

double ersatzt (double x)
 Ersatzt for Landau Fluctuations (very good approximation)

Detailed Description

Definition at line 20 of file LandauFluctuationGenerator.h.


Constructor & Destructor Documentation

LandauFluctuationGenerator::LandauFluctuationGenerator ( const RandomEngine engine) [inline]

Constructor : initialization of the Random Generator.

Definition at line 25 of file LandauFluctuationGenerator.h.

References BaseNumericalRandomGenerator::initialize().

                                                         : 
    BaseNumericalRandomGenerator(engine,-3.5,25.) {
    initialize();
  }
virtual LandauFluctuationGenerator::~LandauFluctuationGenerator ( ) [inline, virtual]

Default destructor.

Definition at line 31 of file LandauFluctuationGenerator.h.

{}

Member Function Documentation

double LandauFluctuationGenerator::ersatzt ( double  x) [inline, private]

Ersatzt for Landau Fluctuations (very good approximation)

Definition at line 42 of file LandauFluctuationGenerator.h.

References funct::exp(), M_PI, and mathSSE::sqrt().

Referenced by function().

                           { 
    return  std::exp(-0.5 * ( x + std::exp(-x) )) / std::sqrt (2. *M_PI); 
  }
virtual double LandauFluctuationGenerator::function ( double  x) [inline, virtual]

The probability density function implementation.

Implements BaseNumericalRandomGenerator.

Definition at line 37 of file LandauFluctuationGenerator.h.

References ersatzt().

{ return ersatzt(x); }
double LandauFluctuationGenerator::landau ( ) const [inline]

Random generator of the dE/dX spread (Landau function)

Definition at line 34 of file LandauFluctuationGenerator.h.

References BaseNumericalRandomGenerator::generate().

Referenced by PreshowerHitMaker::addHit(), and EnergyLossSimulator::compute().

{ return generate(); }