login
A384082
Consecutive states of the linear congruential pseudo-random number generator (61*s+323) mod 500 when started at s=1.
2
1, 384, 247, 390, 113, 216, 499, 262, 305, 428, 431, 114, 277, 220, 243, 146, 229, 292, 135, 58, 361, 344, 307, 50, 373, 76, 459, 322, 465, 188, 291, 74, 337, 380, 3, 6, 189, 352, 295, 318, 221, 304, 367, 210, 133, 436, 419, 382, 125, 448, 151, 34, 397, 40
OFFSET
1,2
COMMENTS
Periodic with period length 500.
Originally defined by Lamie in the form (61*s+2323) mod 500, even though 2323 > 500.
REFERENCES
Edward L. Lamie, Pascal Programming, John Wiley and Sons, 1987 (see p. 150).
FORMULA
a(n) = (61*a(n-1) + 323) mod 500.
MAPLE
a:= proc(n) option remember; `if`(n<2, n,
irem(61*a(n-1)+323, 500))
end:
seq(a(n), n=1..54); # Alois P. Heinz, May 21 2025
MATHEMATICA
NestList[Mod[61*# + 323, 500] &, 1, 100] (* Paolo Xausa, May 19 2025 *)
CROSSREFS
Cf. A096550-A096561 other pseudo-random number generators.
Sequence in context: A342065 A046491 A046492 * A110296 A179664 A212430
KEYWORD
nonn,easy
AUTHOR
Sean A. Irvine, May 18 2025
STATUS
approved