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.

Showing 1-4 of 4 results.

A383940 Consecutive states of the linear congruential pseudo-random number generator (25173*s+13849) mod 2^16 when started at s=1.

Original entry on oeis.org

1, 39022, 61087, 20196, 45005, 3882, 21259, 65216, 19417, 30502, 20919, 26076, 16421, 44130, 63139, 32824, 14513, 51934, 36303, 35284, 8573, 11930, 41787, 65200, 9865, 29590, 743, 39628, 46037, 30162, 47315, 23080, 30049, 20814, 4351, 30916, 22317, 25098
Offset: 1

Views

Author

Sean A. Irvine, May 21 2025

Keywords

Comments

Periodic with period 2^16.
This was a popular generator in the 1980's due to Grogono's book, but the period was too short for serious scientific use.

References

  • Peter Grogono, Programming in Pascal (2nd ed.), Addison-Wesley, 1984 (see pp. 136-137).

Crossrefs

Cf. A096550-A096561 (other pseudo-random number generators).
Cf. A384082, A384085, A384150, A384194 (other early generators for Pascal).
Cf. A384220 (similar generator for Smalltalk-80).

Programs

  • Mathematica
    NestList[Mod[25173*# + 13849, 2^16] &, 1, 100] (* Paolo Xausa, May 22 2025 *)

Formula

a(n) = (25173 * a(n-1) + 13849) mod 2^16.

A384404 Consecutive states of the linear congruential pseudo-random number generator for Turbo Pascal when started at 1.

Original entry on oeis.org

1, 134775814, 3698175007, 870078620, 1172187917, 2884733762, 1368768587, 694906232, 1598751577, 1828254910, 352239543, 2039224980, 303092965, 3611442298, 256513635, 1259699184, 3939707825, 1580146294, 3327160399, 1408429452, 2996491197, 3625686706, 3083712891
Offset: 1

Views

Author

Sean A. Irvine, May 30 2025

Keywords

Comments

Periodic with period 2^32.
Also used by Borland Delphi and Virtual Pascal.

Crossrefs

Programs

  • Maple
    a:= proc(n) option remember; `if`(n=1, 1,
          irem(134775813*a(n-1)+1, 2^32))
        end:
    seq(a(n), n=1..23);  # Alois P. Heinz, May 30 2025
  • Mathematica
    NestList[Mod[134775813*# + 1, 2^32] &, 1, 50] (* Paolo Xausa, Jun 04 2025 *)

Formula

a(n) = (134775813 * a(n-1) + 1) mod 2^32.

A384339 Consecutive states of the linear congruential pseudo-random number generator for Berkeley Pascal 3.1 when started at 1.

Original entry on oeis.org

1, 113280614, 518180871, 401789364, 123511293, 522841650, 132082531, 254284640, 306822585, 36791486, 267986559, 195744204, 63672117, 39581194, 434609499, 223082744, 48501361, 535916054, 463875063, 53294308, 487523181, 390617314, 240119379, 401404304, 176021033
Offset: 1

Views

Author

Sean A. Irvine, May 26 2025

Keywords

Comments

Periodic with period 2^29.
The default initial seed is 7774755, but 1 is used here for consistency with other OEIS sequences.

Crossrefs

Cf. A383940, A384150, A384194, A384236 (other Pascal generators).

Programs

  • Mathematica
    NestList[Mod[62605*# + 113218009, 2^29] &, 1, 50] (* Paolo Xausa, May 27 2025 *)

Formula

a(n) = (62605 * a(n-1) + 113218009) mod 2^29.

A384973 Consecutive states of the linear congruential pseudo-random number generator (101*s+1) mod 2^13 when started at s=1.

Original entry on oeis.org

1, 102, 2111, 220, 5837, 7906, 3883, 7160, 2265, 7582, 3927, 3412, 549, 6298, 5315, 4336, 3761, 3030, 2927, 716, 6781, 4946, 8027, 7912, 4489, 2830, 7303, 324, 8149, 3850, 3827, 1504, 4449, 6982, 671, 2236, 4653, 3010, 907, 1496, 3641, 7294, 7607, 6452, 4485
Offset: 1

Views

Author

Sean A. Irvine, Jun 13 2025

Keywords

Comments

Periodic with period 2^13.

Crossrefs

Programs

  • Mathematica
    NestList[Mod[101*# + 1, 2^13] &, 1, 50] (* Paolo Xausa, Jun 18 2025 *)

Formula

a(n) = (101*a(n-1) + 1) mod 2^13.
Showing 1-4 of 4 results.