1,6

Altug Alkan, Table of n, a(n) for n = 1..10000

Altug Alkan, Plot of first differences

a[1] = a[2] = a[4] = 1; a[3] = 0; a[n_] := a[n] = a[n - a[n - 1] - 1] + a[n - a[n - 2] - 4]; Array[a, 78] (* Michael De Vlieger, May 15 2017 *)

(PARI) q=vector(10000); q[1]=q[2]=q[4]=1; q[3]=0; for(n=5, #q, q[n]=q[n-1-q[n-1]]+q[n-4-q[n-2]]); vector(10000, n, q[n])

Cf. A005185.

Sequence in context: A120203 A029280 A060971 * A091946 A094996 A120194

Adjacent sequences: A283419 A283420 A283421 * A283423 A283424 A283425

nonn,look

Altug Alkan, May 14 2017

approved