|
|
A128172
|
|
Least k such that n^k mod k = n + 1.
|
|
19
|
|
|
4700063497, 41459, 6821, 15853, 121129, 535, 36196439, 3827, 15084115509707, 8153, 20395, 5805311, 93929, 3736136819, 1343851, 7099195, 319, 559, 96641237093, 5053, 1535, 280517, 148731221, 869, 2062919, 17473, 803, 39259
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
2,1
|
|
COMMENTS
|
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.]
|
|
LINKS
|
|
|
EXAMPLE
|
|
|
MATHEMATICA
|
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 *)
|
|
CROSSREFS
|
Cf. A036236, A078457, A119678, A119679, A127816, A119715, A119714, A127817, A127818, A127819, A127820, A127821, A128154, A128155, A128156, A128157, A128158, A128159, A128160.
Cf. A128149 = Least k such that n^k mod k = n - 1.
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
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
Obsolete link to a-file duplicate removed by R. J. Mathar, Aug 24 2009
Edited and a(36), a(38), a(41), a(48), a(49) added by Max Alekseyev, Feb 04, Mar 25, May 07 2012
|
|
STATUS
|
approved
|
|
|
|