The algorithm for this random engine was taken from "F.Gutbrod, Comp. Phys. Comm. 87 (1995) 291-306".
The algorithm can be imagined as a physical system as follows: Imagine 512 "black balls" each with their own unique spin, and positions characterized by disrete angles, where the spin is a 32-bit unsigned integer. A "red ball" collides based upon the angle determined by the last 8 bits of its spin, and the spin of the colliding ball is taken as the output random number. The spin of the colliding ball is replaced then with the left circular shift of the black ball's spin XOR'd with the red ball's spin. The black ball's old spin becomes the red ball's.
To avoid the traps presented, two measures are taken: first, the red ball will oscillate between hitting the lower half of the buffer on one turn and the upper half on another; second, the red ball's spin is incremented by a counter of the number of random numbers produced.
The result is scaled to a double precision floating point number to which is added another random double further scaled 2^(53-32) places to the right in order to ensure that the remaining bits of the result are not left empty due to the mere 32 bits representation used internally.
Engines: HepRandomEngine, DRand48Engine , DualRand, HepJamesRandom, Hurd160Engine, Hurd288Engine, MTwistEngine, RandEngine, RanecuEngine, RanluxEngine, Ranlux64Engine, TripleRand
Distributions: HepRandom, RandBinomial, RandBit, RandBreitWigner, RandChiSquare, RandExponential, RandFlat, RandGamma, RandGauss, RandGaussQ, RandGaussT, RandGeneral, RandLandau, RandPoisson, RandPoissonQ, RandPoissonT, RandStudentT
#include "CLHEP/Random/RanshiEngine.h" class RanshiEngine: public HepRandomEngine