Wichmann–Hill is a pseudorandom number generator proposed in 1982 by Brian Wichmann and David Hill.
[1] It consists of three linear congruential generators with different prime moduli, each of which is used to produce a uniformly distributed number between 0 and 1.
These are summed, modulo 1, to produce the result.
[2] Summing three generators produces a pseudorandom sequence with cycle exceeding 6.95×1012.
[4][5] The following pseudocode is for implementation on machines capable of integer arithmetic up to 5,212,632: For machines limited to 16-bit signed integers, the following equivalent code only uses numbers up to 30,323: The seed values s1, s2 and s3 must be initialized to non-zero values.