Geant4.10
|
Data Structures | |
class | SeedVector |
Functions | |
void | setGenerator (G4INCL::IRandomGenerator *aGenerator) |
void | setSeeds (const SeedVector &sv) |
SeedVector | getSeeds () |
G4double | shoot () |
G4double | shoot0 () |
G4double | shoot1 () |
template<typename T > | |
T | shootInteger (T n) |
G4double | gauss (G4double sigma=1.) |
ThreeVector | normVector (G4double norm=1.) |
ThreeVector | sphereVector (G4double rmax=1.) |
ThreeVector | gaussVector (G4double sigma=1.) |
Generate Gaussianly-distributed ThreeVectors. More... | |
std::pair< G4double, G4double > | correlatedGaussian (const G4double corrCoeff, const G4double x0=0., const G4double sigma=1.) |
Generate pairs of correlated Gaussian random numbers. More... | |
std::pair< G4double, G4double > | correlatedUniform (const G4double corrCoeff) |
Generate pairs of correlated uniform random numbers. More... | |
void | deleteGenerator () |
G4bool | isInitialized () |
std::ostream & | operator<< (std::ostream &out, SeedVector const &sv) |
std::pair< G4double, G4double > G4INCL::Random::correlatedGaussian | ( | const G4double | corrCoeff, |
const G4double | x0 = 0. , |
||
const G4double | sigma = 1. |
||
) |
Generate pairs of correlated Gaussian random numbers.
Definition at line 138 of file G4INCLRandom.cc.
References gauss(), and test::x.
Referenced by correlatedUniform().
Generate pairs of correlated uniform random numbers.
Definition at line 148 of file G4INCLRandom.cc.
References correlatedGaussian(), and G4INCL::Math::gaussianCDF().
void G4INCL::Random::deleteGenerator | ( | ) |
Delete the generator
Definition at line 153 of file G4INCLRandom.cc.
References theGenerator.
Referenced by G4INCL::INCL::~INCL().
Generate random numbers using gaussian distribution.
Definition at line 97 of file G4INCLRandom.cc.
References G4ThreadLocal, shoot(), shoot0(), G4INCL::Math::twoPi, and test::v.
Referenced by correlatedGaussian(), and gaussVector().
ThreeVector G4INCL::Random::gaussVector | ( | G4double | sigma = 1. | ) |
Generate Gaussianly-distributed ThreeVectors.
Generate ThreeVectors that are distributed as a three-dimensional Gaussian of the given sigma.
Definition at line 133 of file G4INCLRandom.cc.
References gauss(), and G4INCL::Math::oneOverSqrtThree.
Referenced by G4INCL::DeJongSpin::shoot().
SeedVector G4INCL::Random::getSeeds | ( | ) |
Get the seeds of the current generator.
Definition at line 70 of file G4INCLRandom.cc.
References theGenerator.
Referenced by G4INCL::IAvatar::getFinalState(), and G4INCL::InteractionAvatar::postInteraction().
G4bool G4INCL::Random::isInitialized | ( | ) |
Check if the generator is initialized.
Definition at line 158 of file G4INCLRandom.cc.
References theGenerator.
Referenced by setGenerator().
ThreeVector G4INCL::Random::normVector | ( | G4double | norm = 1. | ) |
Generate isotropically-distributed ThreeVectors of given norm.
Definition at line 117 of file G4INCLRandom.cc.
References shoot(), and G4INCL::Math::twoPi.
Referenced by G4INCL::PhaseSpaceDecay::decay(), G4INCL::RecombinationChannel::getFinalState(), and sphereVector().
std::ostream& G4INCL::Random::operator<< | ( | std::ostream & | out, |
SeedVector const & | sv | ||
) |
Definition at line 55 of file G4INCLRandomSeedVector.cc.
References G4INCL::Random::SeedVector::at(), and G4INCL::Random::SeedVector::size().
void G4INCL::Random::setGenerator | ( | G4INCL::IRandomGenerator * | aGenerator | ) |
Set the random number generator implementation to be used globally by INCL.
Definition at line 58 of file G4INCLRandom.cc.
References INCL_ERROR, isInitialized(), and theGenerator.
Referenced by G4INCL::INCL::INCL().
void G4INCL::Random::setSeeds | ( | const SeedVector & | sv | ) |
Set the seeds of the current generator.
Definition at line 66 of file G4INCLRandom.cc.
References theGenerator.
G4double G4INCL::Random::shoot | ( | ) |
Generate flat distribution of random numbers.
Definition at line 74 of file G4INCLRandom.cc.
References theGenerator.
Referenced by G4INCL::DeltaDecayChannel::computeDecayTime(), G4INCL::IsotopicDistribution::drawRandomIsotope(), G4AblaRandom::flat(), gauss(), G4INCL::BinaryCollisionAvatar::getChannel(), G4INCL::SurfaceAvatar::getChannel(), G4INCL::DeltaProductionChannel::getFinalState(), G4INCL::DeltaDecayChannel::getFinalState(), G4INCL::ElasticChannel::getFinalState(), G4INCL::PauliGlobal::isBlocked(), G4INCL::PauliStandard::isBlocked(), normVector(), shoot0(), and shoot1().
G4double G4INCL::Random::shoot0 | ( | ) |
Return a random number in the ]0,1] interval
Definition at line 78 of file G4INCLRandom.cc.
References shoot().
Referenced by gauss(), and sphereVector().
G4double G4INCL::Random::shoot1 | ( | ) |
Return a random number in the [0,1[ interval
Definition at line 85 of file G4INCLRandom.cc.
References shoot().
Referenced by shootInteger(), and G4INCL::shuffleComponentsHelper().
T G4INCL::Random::shootInteger | ( | T | n | ) |
ThreeVector G4INCL::Random::sphereVector | ( | G4double | rmax = 1. | ) |
Generate ThreeVectors that are uniformly distributed in a sphere of radius rmax.
Definition at line 129 of file G4INCLRandom.cc.
References normVector(), G4INCL::Math::pow13(), and shoot0().