The Ziggurat algorithm is an algorithm for pseudo-random number sampling from the Normal distribution. This is considerably faster than the two more commonly used methods to generate normally distributed random numbers, the Marsaglia polar method or the Box-Muller transform, which require at least a logarithm and a square root. Empirically, however, the Marsaglia polar method and the
BoxMullertransform seem to have better distributional properties. There are implementation problems in the original uniform random number generator proposed in the paper. To improve the quality, we use
MWC8222for the uniform random number generation.
- See Also:
- "George Marsaglia, Wai Wan Tsang, "The Ziggurat Method for Generating Random Variables," Journal of Statistical Software 5 (8), 2000"
- Wikipedia: Ziggurat algorithm
- a C implementation of the Ziggurat algorithm
- another C implementation of the Ziggurat algorithm
- Boaz Nadler. "Design Flaws in the Implementation of the Ziggurat and Monty Python methods (and some remarks on Matlab randn)," The Journal of Business. arXiv:math/0603058v1. 2 March 2006.
(RandomLongGenerator uniform)Construct a Ziggurat random normal generator.
uniform- a uniform random number generator
Ziggurat2000public Ziggurat2000()Construct a Ziggurat random normal generator.
seedpublic void seed
(long... seeds)Description copied from interface:
SeedableSeed the random number/vector/scenario generator to produce repeatable experiments.
nextDoublepublic double nextDouble()Description copied from interface:
RandomNumberGeneratorGet the next random