OFFSET
0,2
COMMENTS
See the reference in A058311 for a better way to compute this!
MAPLE
M:=4;
L[0]:=[1]; a[0]:=1;
for n from 1 to M do
L[n]:=[];
t1:=L[n-1];
tc:=nops(t1);
for i from 1 to tc do
t2:=t1[i];
for j from 1 to t2*(t2+1) do
L[n]:=[op(L[n]), j]; od:
a[n]:=nops(L[n]);
#lprint(n, L[n], a[n]);
od:
od:
[seq(a[n], n=0..M)];
p := proc(n, k) option remember; local j ; if n = 1 then k*(k+1); else sum( procname(n-1, j), j=1..k*(k+1)) ; fi; expand(%) ; end: A147794 := proc(n) if n = 0 then 1 ; else subs(k=1, p(n, k)) ; fi; end: for n from 0 do printf("%d, \n", A147794(n)) ; od: # R. J. Mathar, May 04 2009
MATHEMATICA
p[n_, k_] := p[n, k] = If[n == 1, k (k + 1), Sum[p[n - 1, j], {j, 1, k (k + 1)}]];
a[n_] := If[n == 0, 1, p[n, 1]];
Table[Print[n, " ", a[n]]; a[n], {n, 0, 7}] (* Jean-François Alcover, Feb 01 2024, after R. J. Mathar *)
CROSSREFS
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, May 03 2009
EXTENSIONS
More terms from R. J. Mathar, May 04 2009
STATUS
approved