Search: id:a125678
|
|
A125678
|
|
a(0) = 1; for n>0, a(n) = (a(n-1)^2 reduced mod n) + 1.
|
|
+0
1
|
|
|
1, 1, 2, 2, 1, 2, 5, 5, 2, 5, 6, 4, 5, 13, 2, 5, 10, 16, 5, 7, 10, 17, 4, 17, 2, 5, 26, 2, 5, 26, 17, 11, 26, 17, 18, 10, 29, 28, 25, 2, 5, 26, 5, 26, 17, 20, 33, 9, 34, 30, 1, 2, 5, 26, 29, 17, 10, 44, 23, 58, 5, 26, 57, 37, 26, 27, 4, 17, 18, 49, 22, 59, 26, 20, 31, 62, 45, 24, 31, 14, 37
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,3
|
|
LINKS
|
|
|
MAPLE
|
A[0]:= 0:
for n from 1 to 100 do A[n]:= (A[n-1]^2 mod n) + 1 od:
|
|
MATHEMATICA
|
f[l_List] := Append[l, Mod[l[[ -1]]^2, Length[l]] + 1]; Nest[f, {1}, 83] (* Ray Chandler, Feb 08 2007 *)
|
|
KEYWORD
|
easy,nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
Search completed in 0.009 seconds
|