Ran055: Knuth's shift and add random generator. Returns integer random numbers uniformly distributed within [0,2147483647] DON'T USE THIS GENERATOR IN SERIOUS APPLICATIONS BECAUSE IT HAS SERIOUS CORRELATIONS.
- The period is 2^55 = 36 028 797 018 963 968 > 3.6*10^16.
- At least 32 bit long int is required, but works with any larger
word lengths
- This is a lagged Fibonacci generator:
x(n) = ( x(n-55) - x(n-24) ) mod 2^31
- Reference:
A version of this pseudrandom number generator is described in
J. Bentley's column, "The Software Exploratorium", Unix Review 1991.
It is based on Algorithm A in D. E. Knuth, The Art of Computer-
Programming, Vol 2, Section 3.2.2, pp. 172
| Constructor | Description |
Full Usage:
Ran055()
|
|
Full Usage:
Ran055(the_seed)
Parameters:
uint32
|
|
| Instance member | Description |
Full Usage:
this.Long
Returns: uint32
Modifiers: abstract |
|