Expand description
RANDU is Pseudo random multiplicative congruential generator MCG65539 used during 1960’s and 1970’s in the IBM Scientific Subroutine Library for IBM System/360 computers. Oesis A096555.
RANDU uses following MCG coeficients:
- multiplier a = 65539 ( 2^16 + 3 )
- modulus m = 2147483648 ( 2^31 )
RANDU generates non negative 31-bit integers with 2^29 period. Generated values fails the spectral test for dimensions greater than 2 and have low randomness in lower bits.
This is free and unencumbered software released into the public domain.
Structs§
- RANDU
- Structure holding current state of RANDU generator.
Constants§
- A
- multiplier A coeficient 2^16 + 3
- C
- C = 0 in MCG generators
- M
- modulus M coeficient 2^31
- MAX
- Maximum generated number
- MIN
- Minimum generated number
- PERIOD
- Generator period 2^29
- SEED
- RANDU start value
Functions§
- clamp_
seed - clamps seed into valid range for generator.
- validate_
seed - Validate if supplied integer is in valid range of seeds for generator.