login
A087846
a(n) = a(a(a(abs(n - a(n-1))))) + a(abs(n - a(n-4))).
0
1, 1, 1, 1, 2, 3, 4, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 10, 9, 10, 10, 10, 10, 10, 10, 10, 10, 12, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 14, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 17, 15, 17, 17, 16, 17, 17, 17, 17, 17, 17, 17
OFFSET
1,5
MATHEMATICA
a[n_] := a[n] = a[a[a[Abs[n - a[n - 1]]]]] + a[Abs[n - a[n - 4]]]; a[1] = a[2] = a[3] = a[4] = 1; Table[a[n], {n, 81}] (* Corrected by L. Edson Jeffery, Dec 02 2014 *)
CROSSREFS
Cf. A081831.
Sequence in context: A194259 A246264 A102676 * A067854 A194214 A251416
KEYWORD
nonn
AUTHOR
Roger L. Bagula, Oct 07 2003
STATUS
approved