OFFSET
1,2
COMMENTS
a(n+1) = a(n) + a(k(n)), where k(n) is the number of elements of {a} which are <= n.
LINKS
Michael De Vlieger, Table of n, a(n) for n = 1..10000
MATHEMATICA
f[n_] := Block[{t = Table[0, {n}]}, t[[1]] = 1; For[i = 1, i < n, i++, t[[i + 1]] = t[[i]] + t[[Count[t, x_ /; 0 < x <= i]]]]; t]; f@ 54 (* Michael De Vlieger, Mar 23 2015 *)
PROG
(PARI) flargest(va, n) = {vsa = vecsort(va, , 12); for (k=1, #vsa, if (vsa[k] < n, return (vsa[k])); ); }
lista(nn) = {va = [1]; print1(va[1], ", "); for (n=2, nn, newa = flargest(va, n) + va[n-1]; print1(newa, ", "); va = concat(va, newa); ); } \\ Michel Marcus, Mar 23 2015
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Leroy Quet, Jun 07 2004
EXTENSIONS
More terms from Vladeta Jovovic, Jun 13 2004
STATUS
approved