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 A128172 #45 Dec 24 2016 21:47:33 %S A128172 4700063497,41459,6821,15853,121129,535,36196439,3827,15084115509707, %T A128172 8153,20395,5805311,93929,3736136819,1343851,7099195,319,559, %U A128172 96641237093,5053,1535,280517,148731221,869,2062919,17473,803,39259 %N A128172 Least k such that n^k mod k = n + 1. %C A128172 a(n)=k must be odd since n and n+1 are of opposite parity. The only way this can occur is if k is odd. - _Robert G. Wilson v_, Aug 12 2009 [Comment corrected by _Fausto A. C. Cariboni_, Nov 20 2016.] %H A128172 Max Alekseyev, <a href="/A128172/b128172.txt">Table of n, a(n) for n = 2..43</a> %H A128172 Fausto A. C. Cariboni, <a href="/A128172/a128172_4.txt">Table of n, a(n) for n = 2..10000 with -1 for large entries where a(n) has not yet been found</a>, Dec 24 2016 [With 1772 new terms, this supersedes the earlier table from Robert G. Wilson v et al.] %H A128172 Robert G. Wilson v et al., <a href="/A128172/a128172_3.txt">Table of n, a(n) for n = 2..10000 with -1 for large entries where a(n) has not yet been found</a> %e A128172 a(2) = A036236(3) = 4700063497. %t A128172 t = Table[0, {10000}]; f[n_] := Block[{k = 1}, While[k < 2097153 && PowerMod[n, k, k] != n + 1, If[ Mod[k, 6] == 1, k += 4, k += 2]]; k]; Do[ If[ t[[n]] == 0, a = f@n; If[a < 2097153, t[[n]] = a; Print[{n, a}]]], {n, 10000}]; t (* _Robert G. Wilson v_, Aug 12 2009 *) %Y A128172 Cf. A036236, A078457, A119678, A119679, A127816, A119715, A119714, A127817, A127818, A127819, A127820, A127821, A128154, A128155, A128156, A128157, A128158, A128159, A128160. %Y A128172 Cf. A128149 = Least k such that n^k mod k = n - 1. %K A128172 nonn %O A128172 2,1 %A A128172 _Alexander Adamchuk_, Feb 17 2007 %E A128172 a(15) = A128155(16) = 3736136819 and a(16) = A128156(17) = 1343851 found by _Ryan Propper_, Feb 27-28 2007 %E A128172 a(10), a(17), a(20), a(23)-a(24), a(26), a(30)-a(31), a(33)-a(35) determined by Tyler Cadigan (tylercadigan(AT)gmail.com), Feb 21 2009 %E A128172 Terms corrected by _Hagen von Eitzen_ and _R. J. Mathar_, Aug 05 2009 %E A128172 Obsolete link to a-file duplicate removed by _R. J. Mathar_, Aug 24 2009 %E A128172 Edited and a(36), a(38), a(41), a(48), a(49) added by _Max Alekseyev_, Feb 04, Mar 25, May 07 2012