The linear congruential generator consists of the following four numbers :
These numbers should be chosen in such a way, that the random number stream provides a long cycle time and has good statistical properties. The library combines three generators :
The random number then comes from the formula :
The implementation in the library (the generator::random method) rewrites these formulas to ensure compatibility of this method. This generator has a period of , which means that you won't get a cycle. Furthermore, it has passed several statistical tests.