login
A104647
a(n) = a(n-1) mod n + a(n-2) mod n; a(0) = 0, a(1) = 1.
9
0, 1, 1, 2, 3, 5, 8, 6, 6, 12, 8, 9, 17, 13, 16, 14, 14, 28, 24, 14, 18, 32, 28, 14, 18, 32, 24, 29, 25, 25, 50, 44, 30, 41, 37, 8, 9, 17, 26, 43, 29, 31, 60, 48, 20, 23, 43, 66, 61, 29, 40, 69, 57, 20, 23, 43, 66, 52, 60, 53, 53, 106, 97, 77, 46, 58, 104, 95, 63, 89, 82, 29, 39, 68
OFFSET
0,4
COMMENTS
a(n) <= a(n-1) + a(n-2) < 2*n for n>0, see A105859 for numbers i such that a(i)=a(i-1)+a(i-2) and A105860 for numbers j with a(j)<a(j-1)+a(j-2); - Reinhard Zumkeller, Apr 23 2005
A105855 = (first differences) and A105856 = (partial sums); records occur at A105857: A105858(n) = a(A105857(n)). - Reinhard Zumkeller, Apr 23 2005
LINKS
MATHEMATICA
Fold[Append[#1, Mod[#1[[-1]], #2] + Mod[#1[[-2]], #2]] &, {0, 1}, Range[2, 73]] (* Ivan Neretin, Jun 18 2018 *)
CROSSREFS
Sequence in context: A249188 A284188 A011158 * A065115 A262263 A072987
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Apr 21 2005
STATUS
approved