This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A058311 #24 Jun 26 2023 08:47:38 %S A058311 1,4,48,7918,463339346,7134188685100826388, %T A058311 13246386641449904934758023373599438217628, %U A058311 643152870463337226096320122089499144560533929707886143570111588898313745804013188842 %N A058311 Number of nodes at n-th level in tree in which top node is 1; each node k has children labeled k, k+1, ..., (k+1)^2 at next level. %C A058311 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. %H A058311 M. Cook and M. Kleber, <a href="https://doi.org/10.37236/1522">Tournament sequences and Meeussen sequences</a>, Electronic J. Comb. 7 (2000), #R44. %p A058311 M:=4; %p A058311 L[0]:=[1]; a[0]:=1; %p A058311 for n from 1 to M do %p A058311 L[n]:=[]; %p A058311 t1:=L[n-1]; %p A058311 tc:=nops(t1); %p A058311 for i from 1 to tc do %p A058311 t2:=t1[i]; %p A058311 for j from t2 to (t2+1)^2 do %p A058311 L[n]:=[op(L[n]),j]; od: %p A058311 a[n]:=nops(L[n]); %p A058311 #lprint(n,L[n],a[n]); %p A058311 od: %p A058311 od: %p A058311 [seq(a[n],n=0..M)]; %p A058311 # See the reference for a better way to compute this! %p A058311 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: %p A058311 A058311 := proc(n) if n = 0 then 1 ; else subs(k=1, p(n,k)) ; fi; end proc: %p A058311 for n from 0 do printf("%d,\n", A058311(n)) ; od: # _R. J. Mathar_, May 04 2009 %t A058311 p[n_, k_] := p[n, k] = If[n == 1, k^2+k+2, Sum[p[n-1, j], {j, k, (k+1)^2}]]; %t A058311 a[n_] := If[n == 0, 1, p[n, 1]]; %t A058311 Table[Print[n, " ", a[n]]; a[n], {n, 0, 7}] (* _Jean-François Alcover_, Jun 26 2023, after _R. J. Mathar_ *) %Y A058311 Cf. A008934, A058222, A147780, A147794. %K A058311 nonn %O A058311 0,2 %A A058311 _N. J. A. Sloane_, Dec 09 2000 %E A058311 Corrected, with Maple program, by _N. J. A. Sloane_, May 03 2009. Thanks to _Max Alekseyev_ for pointing out that something was wrong. %E A058311 Replaced a(4), added three more terms - _R. J. Mathar_, May 04 2009