cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A385279 Consecutive states of the linear congruential pseudo-random number generator (625*s + 6571) mod 31104 when started at s=1.

Original entry on oeis.org

1, 7196, 25095, 14530, 5453, 24360, 21715, 17102, 26649, 21556, 11039, 858, 14053, 18368, 9195, 30310, 7985, 20556, 8119, 10994, 3837, 9688, 27395, 21246, 3913, 26084, 10575, 21898, 7061, 2928, 1435, 1430, 29409, 4732, 9191, 27810, 685, 30344, 29235, 20398
Offset: 1

Views

Author

Sean A. Irvine, Jun 23 2025

Keywords

Comments

Periodic with period 31104.
Described in Numerical Recipes as a "quick and dirty" generator.

References

  • William H. Press, Saul A. Teukolsky, William T. Vetterling, and Brian P. Flannery, Numerical Recipes in C (2nd ed), Cambridge University Press, 1999 (see p. 285).

Crossrefs

Programs

  • Maple
    a:= proc(n) option remember; `if`(n<2, n,
          irem(625*a(n-1)+6571, 31104))
        end:
    seq(a(n), n=1..44);  # after Alois P. Heinz
  • Mathematica
    NestList[Mod[625*# + 6571, 31104] &, 1, 50] (* after Paolo Xausa *)

Formula

a(n) = (625 * a(n-1) + 6571) mod 31104.