OFFSET
0,2
COMMENTS
Triggered by a comment from Michael Kleber, Dec 08 2009, who said: The algorithm in my paper with Cook lets you compute the equivalent sequence where the children of a node labeled (k) are labeled with all the integers in the interval [p(k), q(k)] where p,q are any polynomials you like (in the paper, p(k)=k+1 and q(k)=2k). For a bunch of p,q the resulting sequence is well known, e.g., p(k)=1, q(k)=k+1 is the Catalan numbers.
LINKS
M. Cook and M. Kleber, Tournament sequences and Meeussen sequences, Electronic J. Comb. 7 (2000), #R44.
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 t2 to (t2+1)^2 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)];
# See the reference for a better way to compute this!
p := proc(n, k) option remember; local j ; if n = 1 then k^2+k+2; # (k+1)^2-(k-1) else sum( procname(n-1, j), j=k..(k+1)^2) ; fi; expand(%) ; end proc:
A058311 := proc(n) if n = 0 then 1 ; else subs(k=1, p(n, k)) ; fi; end proc:
for n from 0 do printf("%d, \n", A058311(n)) ; od: # R. J. Mathar, May 04 2009
MATHEMATICA
p[n_, k_] := p[n, k] = If[n == 1, k^2+k+2, Sum[p[n-1, j], {j, k, (k+1)^2}]];
a[n_] := If[n == 0, 1, p[n, 1]];
Table[Print[n, " ", a[n]]; a[n], {n, 0, 7}] (* Jean-François Alcover, Jun 26 2023, after R. J. Mathar *)
CROSSREFS
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Dec 09 2000
EXTENSIONS
Corrected, with Maple program, by N. J. A. Sloane, May 03 2009. Thanks to Max Alekseyev for pointing out that something was wrong.
Replaced a(4), added three more terms - R. J. Mathar, May 04 2009
STATUS
approved