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.
%I A385336 #11 Jul 08 2025 16:41:52 %S A385336 1,4498,4375,10832,7069,4286,13683,4460,1817,2954,5071,5368,1045,3302, %T A385336 9339,2356,7553,8130,1287,12224,10141,6238,11715,9772,11609,426,1423, %U A385336 11800,757,7494,1211,7108,8385,2242,13879,12496,9293,1470,227,2764,6281,7978,5055 %N A385336 Consecutive states of the linear congruential pseudo-random number generator (1541*s + 2957) mod 14000 when started at s=1. %C A385336 Periodic with period 14000. %C A385336 Described in Numerical Recipes as a "quick and dirty" generator. %D A385336 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). %H A385336 Sean A. Irvine, <a href="/A385336/b385336.txt">Table of n, a(n) for n = 1..14000</a> %H A385336 <a href="/index/Ps#PRN">Index entries for sequences related to pseudo-random numbers.</a> %H A385336 <a href="/index/Rec#order_14000">Index entries for linear recurrences with constant coefficients</a>, order 14000. %F A385336 a(n) = (1541 * a(n-1) + 2957) mod 14000. %p A385336 a:= proc(n) option remember; `if`(n<2, n, %p A385336 irem(1541*a(n-1)+2957, 14000)) %p A385336 end: %p A385336 seq(a(n), n=1..44); # after _Alois P. Heinz_ %t A385336 NestList[Mod[1541*# + 2957, 14000] &, 1, 50] (* after _Paolo Xausa_ *) %Y A385336 Cf. A385279, A385335. %K A385336 nonn,look,easy %O A385336 1,2 %A A385336 _Sean A. Irvine_, Jun 25 2025