CLHEP 2.0.4.7 Reference Documentation
   
CLHEP Home Page     CLHEP Documentation     CLHEP Bug Reports

CLHEP::HepRandomEngine Class Reference

#include <RandomEngine.h>

Inheritance diagram for CLHEP::HepRandomEngine:

CLHEP::DRand48Engine CLHEP::DualRand CLHEP::HepJamesRandom CLHEP::Hurd160Engine CLHEP::Hurd288Engine CLHEP::MTwistEngine CLHEP::NonRandomEngine CLHEP::RandEngine CLHEP::RanecuEngine CLHEP::Ranlux64Engine CLHEP::RanluxEngine CLHEP::RanshiEngine CLHEP::TripleRand List of all members.

Public Member Functions

 HepRandomEngine ()
virtual ~HepRandomEngine ()
bool operator== (const HepRandomEngine &engine)
bool operator!= (const HepRandomEngine &engine)
virtual double flat ()=0
virtual void flatArray (const int size, double *vect)=0
virtual void setSeed (long seed, int)=0
virtual void setSeeds (const long *seeds, int)=0
virtual void saveStatus (const char filename[]="Config.conf") const =0
virtual void restoreStatus (const char filename[]="Config.conf")=0
virtual void showStatus () const =0
virtual std::string name () const =0
virtual std::ostream & put (std::ostream &os) const
virtual std::istream & get (std::istream &is)
virtual std::istream & getState (std::istream &is)
virtual std::vector< unsigned
long > 
put () const
virtual bool get (const std::vector< unsigned long > &v)
virtual bool getState (const std::vector< unsigned long > &v)
long getSeed () const
const long * getSeeds () const
virtual operator double ()
virtual operator float ()
virtual operator unsigned int ()

Static Public Member Functions

static std::string beginTag ()
static HepRandomEnginenewEngine (std::istream &is)
static HepRandomEnginenewEngine (const std::vector< unsigned long > &v)

Static Protected Member Functions

static bool checkFile (std::istream &file, const std::string &filename, const std::string &classname, const std::string &methodname)

Protected Attributes

long theSeed
const long * theSeeds
const double exponent_bit_32

Detailed Description

Author:
<Gabriele.Cosmo@cern.ch>

Definition at line 55 of file RandomEngine.h.


Constructor & Destructor Documentation

CLHEP::HepRandomEngine::HepRandomEngine (  ) 

Definition at line 27 of file RandomEngine.cc.

References theSeed.

CLHEP::HepRandomEngine::~HepRandomEngine (  )  [virtual]

Definition at line 34 of file RandomEngine.cc.


Member Function Documentation

std::string CLHEP::HepRandomEngine::beginTag (  )  [static]

Reimplemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::NonRandomEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Definition at line 70 of file RandomEngine.cc.

bool CLHEP::HepRandomEngine::checkFile ( std::istream &  file,
const std::string &  filename,
const std::string &  classname,
const std::string &  methodname 
) [static, protected]

Definition at line 49 of file RandomEngine.cc.

Referenced by CLHEP::TripleRand::restoreStatus(), CLHEP::RanshiEngine::restoreStatus(), CLHEP::RanluxEngine::restoreStatus(), CLHEP::Ranlux64Engine::restoreStatus(), CLHEP::RanecuEngine::restoreStatus(), CLHEP::RandEngine::restoreStatus(), CLHEP::MTwistEngine::restoreStatus(), CLHEP::HepJamesRandom::restoreStatus(), CLHEP::Hurd288Engine::restoreStatus(), CLHEP::Hurd160Engine::restoreStatus(), CLHEP::DualRand::restoreStatus(), and CLHEP::DRand48Engine::restoreStatus().

virtual double CLHEP::HepRandomEngine::flat (  )  [pure virtual]

Implemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::NonRandomEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Referenced by anonymousRestore2(), anonymousRestoreStatics(), CLHEP::RandStudentT::fire(), CLHEP::RandPoisson::fire(), CLHEP::RandBreitWigner::fire(), CLHEP::HepRandom::flat(), CLHEP::RandGauss::normal(), operator double(), operator float(), operator unsigned int(), CLHEP::RandGaussT::operator()(), CLHEP::RandGaussQ::operator()(), CLHEP::RandStudentT::shoot(), CLHEP::RandPoisson::shoot(), CLHEP::RandGauss::shoot(), CLHEP::RandFlat::shoot(), CLHEP::RandBreitWigner::shoot(), and vectorRestore2().

virtual void CLHEP::HepRandomEngine::flatArray ( const int  size,
double *  vect 
) [pure virtual]

Implemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::NonRandomEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Referenced by CLHEP::HepRandom::flatArray(), and CLHEP::RandFlat::shootArray().

bool CLHEP::HepRandomEngine::get ( const std::vector< unsigned long > &  v  )  [virtual]

Reimplemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::NonRandomEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Definition at line 84 of file RandomEngine.cc.

std::istream & CLHEP::HepRandomEngine::get ( std::istream &  is  )  [virtual]

Reimplemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::NonRandomEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Definition at line 65 of file RandomEngine.cc.

Referenced by CLHEP::operator>>().

long CLHEP::HepRandomEngine::getSeed (  )  const [inline]

Definition at line 114 of file RandomEngine.h.

References theSeed.

Referenced by CLHEP::HepRandom::getTheSeed(), CLHEP::HepJamesRandom::HepJamesRandom(), CLHEP::RanluxEngine::operator=(), CLHEP::RanecuEngine::operator=(), CLHEP::HepJamesRandom::operator=(), CLHEP::RanecuEngine::RanecuEngine(), and CLHEP::RanluxEngine::RanluxEngine().

const long* CLHEP::HepRandomEngine::getSeeds (  )  const [inline]

Definition at line 117 of file RandomEngine.h.

References theSeeds.

Referenced by CLHEP::HepRandom::getTheSeeds().

bool CLHEP::HepRandomEngine::getState ( const std::vector< unsigned long > &  v  )  [virtual]

Reimplemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::NonRandomEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Definition at line 88 of file RandomEngine.cc.

std::istream & CLHEP::HepRandomEngine::getState ( std::istream &  is  )  [virtual]

Reimplemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::NonRandomEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Definition at line 74 of file RandomEngine.cc.

virtual std::string CLHEP::HepRandomEngine::name (  )  const [pure virtual]

Implemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::NonRandomEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Referenced by anonymousRestoreStatics(), anonymousRestoreStatics1(), checkRandGeneralDistribution(), CLHEP::StaticRandomStates::restore(), and vectorRestore2().

HepRandomEngine * CLHEP::HepRandomEngine::newEngine ( const std::vector< unsigned long > &  v  )  [static]

Definition at line 98 of file RandomEngine.cc.

References CLHEP::EngineFactory::newEngine().

HepRandomEngine * CLHEP::HepRandomEngine::newEngine ( std::istream &  is  )  [static]

Definition at line 93 of file RandomEngine.cc.

References CLHEP::EngineFactory::newEngine().

Referenced by CLHEP::StaticRandomStates::restore().

CLHEP::HepRandomEngine::operator double (  )  [virtual]

Definition at line 36 of file RandomEngine.cc.

References flat().

CLHEP::HepRandomEngine::operator float (  )  [virtual]

Reimplemented in CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::MTwistEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Definition at line 40 of file RandomEngine.cc.

References flat().

CLHEP::HepRandomEngine::operator unsigned int (  )  [virtual]

Reimplemented in CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Definition at line 44 of file RandomEngine.cc.

References exponent_bit_32, and flat().

bool CLHEP::HepRandomEngine::operator!= ( const HepRandomEngine engine  )  [inline]

bool CLHEP::HepRandomEngine::operator== ( const HepRandomEngine engine  )  [inline]

std::vector< unsigned long > CLHEP::HepRandomEngine::put (  )  const [virtual]

Reimplemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::NonRandomEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Definition at line 79 of file RandomEngine.cc.

std::ostream & CLHEP::HepRandomEngine::put ( std::ostream &  os  )  const [virtual]

Reimplemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::NonRandomEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Definition at line 61 of file RandomEngine.cc.

Referenced by CLHEP::operator<<().

virtual void CLHEP::HepRandomEngine::restoreStatus ( const char  filename[] = "Config.conf"  )  [pure virtual]

Implemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Referenced by CLHEP::HepRandom::restoreEngineStatus(), CLHEP::RandGauss::restoreEngineStatus(), and CLHEP::RandFlat::restoreEngineStatus().

virtual void CLHEP::HepRandomEngine::saveStatus ( const char  filename[] = "Config.conf"  )  const [pure virtual]

Implemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Referenced by CLHEP::HepRandom::saveEngineStatus(), CLHEP::RandGauss::saveEngineStatus(), and CLHEP::RandFlat::saveEngineStatus().

virtual void CLHEP::HepRandomEngine::setSeed ( long  seed,
int   
) [pure virtual]

Implemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Referenced by CLHEP::HepRandom::setTheSeed().

virtual void CLHEP::HepRandomEngine::setSeeds ( const long *  seeds,
int   
) [pure virtual]

Implemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Referenced by CLHEP::HepRandom::setTheSeeds().

virtual void CLHEP::HepRandomEngine::showStatus (  )  const [pure virtual]

Implemented in CLHEP::DRand48Engine, CLHEP::DualRand, CLHEP::Hurd160Engine, CLHEP::Hurd288Engine, CLHEP::HepJamesRandom, CLHEP::MTwistEngine, CLHEP::RandEngine, CLHEP::RanecuEngine, CLHEP::Ranlux64Engine, CLHEP::RanluxEngine, CLHEP::RanshiEngine, and CLHEP::TripleRand.

Referenced by CLHEP::HepRandom::showEngineStatus().


Member Data Documentation

const double CLHEP::HepRandomEngine::exponent_bit_32 [protected]

Definition at line 147 of file RandomEngine.h.

Referenced by CLHEP::RanluxEngine::operator unsigned int(), operator unsigned int(), and CLHEP::HepJamesRandom::operator unsigned int().

long CLHEP::HepRandomEngine::theSeed [protected]

Definition at line 144 of file RandomEngine.h.

Referenced by CLHEP::DRand48Engine::DRand48Engine(), CLHEP::DualRand::DualRand(), getSeed(), CLHEP::TripleRand::getState(), CLHEP::RanshiEngine::getState(), CLHEP::RanluxEngine::getState(), CLHEP::Ranlux64Engine::getState(), CLHEP::RanecuEngine::getState(), CLHEP::RandEngine::getState(), CLHEP::MTwistEngine::getState(), CLHEP::HepJamesRandom::getState(), CLHEP::Hurd288Engine::getState(), CLHEP::Hurd160Engine::getState(), CLHEP::DualRand::getState(), CLHEP::DRand48Engine::getState(), CLHEP::HepJamesRandom::HepJamesRandom(), HepRandomEngine(), CLHEP::RanluxEngine::operator=(), CLHEP::Ranlux64Engine::operator=(), CLHEP::RanecuEngine::operator=(), CLHEP::HepJamesRandom::operator=(), CLHEP::TripleRand::put(), CLHEP::RanshiEngine::put(), CLHEP::RanluxEngine::put(), CLHEP::Ranlux64Engine::put(), CLHEP::RanecuEngine::put(), CLHEP::RandEngine::put(), CLHEP::MTwistEngine::put(), CLHEP::HepJamesRandom::put(), CLHEP::Hurd288Engine::put(), CLHEP::Hurd160Engine::put(), CLHEP::DualRand::put(), CLHEP::DRand48Engine::put(), CLHEP::RandEngine::RandEngine(), CLHEP::RanecuEngine::RanecuEngine(), CLHEP::RanluxEngine::RanluxEngine(), CLHEP::RanshiEngine::RanshiEngine(), CLHEP::TripleRand::restoreStatus(), CLHEP::RanshiEngine::restoreStatus(), CLHEP::RanluxEngine::restoreStatus(), CLHEP::Ranlux64Engine::restoreStatus(), CLHEP::RanecuEngine::restoreStatus(), CLHEP::RandEngine::restoreStatus(), CLHEP::MTwistEngine::restoreStatus(), CLHEP::HepJamesRandom::restoreStatus(), CLHEP::Hurd288Engine::restoreStatus(), CLHEP::Hurd160Engine::restoreStatus(), CLHEP::DualRand::restoreStatus(), CLHEP::DRand48Engine::restoreStatus(), CLHEP::TripleRand::saveStatus(), CLHEP::RanshiEngine::saveStatus(), CLHEP::RanluxEngine::saveStatus(), CLHEP::Ranlux64Engine::saveStatus(), CLHEP::RanecuEngine::saveStatus(), CLHEP::RandEngine::saveStatus(), CLHEP::MTwistEngine::saveStatus(), CLHEP::HepJamesRandom::saveStatus(), CLHEP::Hurd288Engine::saveStatus(), CLHEP::Hurd160Engine::saveStatus(), CLHEP::DualRand::saveStatus(), CLHEP::DRand48Engine::saveStatus(), CLHEP::RanecuEngine::setIndex(), CLHEP::TripleRand::setSeed(), CLHEP::RanluxEngine::setSeed(), CLHEP::Ranlux64Engine::setSeed(), CLHEP::RanecuEngine::setSeed(), CLHEP::RandEngine::setSeed(), CLHEP::MTwistEngine::setSeed(), CLHEP::HepJamesRandom::setSeed(), CLHEP::DualRand::setSeed(), CLHEP::DRand48Engine::setSeed(), CLHEP::RanshiEngine::setSeeds(), CLHEP::RanluxEngine::setSeeds(), CLHEP::Ranlux64Engine::setSeeds(), CLHEP::RanecuEngine::setSeeds(), CLHEP::TripleRand::showStatus(), CLHEP::RanshiEngine::showStatus(), CLHEP::RanluxEngine::showStatus(), CLHEP::Ranlux64Engine::showStatus(), CLHEP::RanecuEngine::showStatus(), CLHEP::RandEngine::showStatus(), CLHEP::MTwistEngine::showStatus(), CLHEP::HepJamesRandom::showStatus(), CLHEP::Hurd288Engine::showStatus(), CLHEP::Hurd160Engine::showStatus(), CLHEP::DualRand::showStatus(), CLHEP::DRand48Engine::showStatus(), and CLHEP::TripleRand::TripleRand().

const long* CLHEP::HepRandomEngine::theSeeds [protected]

Definition at line 145 of file RandomEngine.h.

Referenced by getSeeds(), CLHEP::Ranlux64Engine::operator=(), CLHEP::RanecuEngine::operator=(), CLHEP::RanecuEngine::RanecuEngine(), CLHEP::RanecuEngine::setIndex(), CLHEP::RanecuEngine::setSeed(), CLHEP::TripleRand::setSeeds(), CLHEP::RanshiEngine::setSeeds(), CLHEP::RanluxEngine::setSeeds(), CLHEP::Ranlux64Engine::setSeeds(), CLHEP::RanecuEngine::setSeeds(), CLHEP::RandEngine::setSeeds(), CLHEP::MTwistEngine::setSeeds(), CLHEP::HepJamesRandom::setSeeds(), CLHEP::Hurd288Engine::setSeeds(), CLHEP::Hurd160Engine::setSeeds(), CLHEP::DualRand::setSeeds(), and CLHEP::DRand48Engine::setSeeds().


The documentation for this class was generated from the following files:
Generated on Thu Jul 1 22:02:32 2010 for CLHEP by  doxygen 1.4.7