EeToeeVRandom Class Reference

#include <EeToeeVRandom.h>

List of all members.

Static Public Member Functions

static double Flat (double min, double max)
static double Flat (double max)
static double Flat ()
static void FlatArray (double *vect, const int size)
static double random ()
static void setRandomEngine (CLHEP::HepRandomEngine *randomEngine)

Static Private Attributes

static CLHEP::HepRandomEngine * _randomEngine = 0


Detailed Description

Definition at line 19 of file EeToeeVRandom.h.


Member Function Documentation

double EeToeeVRandom::Flat (  )  [static]

Definition at line 55 of file EeToeeVRandom.cxx.

References random().

00055                           {
00056 
00057   return EeToeeVRandom::random();
00058 
00059  } 

double EeToeeVRandom::Flat ( double  max  )  [static]

Definition at line 49 of file EeToeeVRandom.cxx.

References random().

00049                                     {
00050 
00051   return max*EeToeeVRandom::random();
00052 
00053 } 

double EeToeeVRandom::Flat ( double  min,
double  max 
) [static]

Definition at line 39 of file EeToeeVRandom.cxx.

References random().

00039                                                  {
00040 
00041   if ( min > max ) {
00042     cerr<< "min>max in EeToeeVRandom::Flat(" << min << "," << max << ")" <<endl;
00043   }
00044 
00045   return EeToeeVRandom::random()*( max - min )+min;
00046 
00047 } 

void EeToeeVRandom::FlatArray ( double *  vect,
const int  size 
) [static]

Definition at line 61 of file EeToeeVRandom.cxx.

References _randomEngine.

00061                                                          {
00062   if(_randomEngine == 0) cout<<"Can not get randomEngine pointer in EeToeeVRandom::FlatArray"<<endl;
00063   else _randomEngine->flatArray(size,vect);
00064 }

double EeToeeVRandom::random (  )  [static]

Definition at line 28 of file EeToeeVRandom.cxx.

References _randomEngine.

Referenced by Flat().

00028                             {
00029 
00030   if (_randomEngine==0){
00031     cerr <<"No random engine available in "
00032                            <<"EeToeeVRandom::random()."<<endl;
00033   }
00034     return _randomEngine->flat();
00035   }

void EeToeeVRandom::setRandomEngine ( CLHEP::HepRandomEngine *  randomEngine  )  [static]

Definition at line 23 of file EeToeeVRandom.cxx.

References _randomEngine.

Referenced by EeToeeV::initialize().

00023                                                                      {
00024   _randomEngine=randomEngine;
00025 }


Member Data Documentation

HepRandomEngine * EeToeeVRandom::_randomEngine = 0 [static, private]

Definition at line 37 of file EeToeeVRandom.h.

Referenced by FlatArray(), random(), and setRandomEngine().


Generated on Tue Nov 29 23:18:36 2016 for BOSS_7.0.2 by  doxygen 1.4.7