cp's OEIS Frontend

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.

Showing 1-5 of 5 results.

A095133 Triangle of numbers of forests on n nodes containing k trees.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 3, 3, 2, 1, 1, 6, 6, 4, 2, 1, 1, 11, 11, 7, 4, 2, 1, 1, 23, 23, 14, 8, 4, 2, 1, 1, 47, 46, 29, 15, 8, 4, 2, 1, 1, 106, 99, 60, 32, 16, 8, 4, 2, 1, 1, 235, 216, 128, 66, 33, 16, 8, 4, 2, 1, 1, 551, 488, 284, 143, 69, 34, 16, 8, 4, 2, 1, 1, 1301, 1121, 636, 315, 149, 70, 34, 16, 8, 4, 2, 1, 1
Offset: 1

Views

Author

Eric W. Weisstein, May 29 2004

Keywords

Comments

Row sums are A005195.
For k > n/2, T(n,k) = T(n-1,k-1). - Geoffrey Critzer, Oct 13 2012

Examples

			Triangle begins:
    1;
    1,  1;
    1,  1,  1;
    2,  2,  1,  1;
    3,  3,  2,  1,  1;
    6,  6,  4,  2,  1, 1;
   11, 11,  7,  4,  2, 1, 1;
   23, 23, 14,  8,  4, 2, 1, 1;
   47, 46, 29, 15,  8, 4, 2, 1, 1;
  106, 99, 60, 32, 16, 8, 4, 2, 1, 1;
  ...
		

Crossrefs

Cf. A005195 (row sums), A005196, A106240, A000055 (first column), A274937 (2nd column), A105821.
Limiting sequence of reversed rows gives A215930.
Reflected table is A136605. - Alois P. Heinz, Apr 11 2014

Programs

  • Maple
    with(numtheory):
    b:= proc(n) option remember; local d, j; `if` (n<=1, n,
          (add(add(d*b(d), d=divisors(j)) *b(n-j), j=1..n-1))/(n-1))
        end:
    t:= proc(n) option remember; local k; `if` (n=0, 1,
          b(n)-(add(b(k)*b(n-k), k=0..n)-`if`(irem(n, 2)=0, b(n/2), 0))/2)
        end:
    g:= proc(n, i, p) option remember; `if`(p>n, 0, `if`(n=0, 1,
          `if`(min(i, p)<1, 0, add(g(n-i*j, i-1, p-j) *
           binomial(t(i)+j-1, j), j=0..min(n/i, p)))))
        end:
    a:= (n, k)-> g(n, n, k):
    seq(seq(a(n, k), k=1..n), n=1..14);  # Alois P. Heinz, Aug 20 2012
  • Mathematica
    nn=30;s[n_,k_]:=s[n,k]=a[n+1-k]+If[n<2k,0,s[n-k,k]];a[1]=1;a[n_]:=a[n]=Sum[a[i]s[n-1,i]i,{i,1,n-1}]/(n-1);ft=Table[a[i]-Sum[a[j]a[i-j],{j,1,i/2}]+If[OddQ[i],0,a[i/2](a[i/2]+1)/2],{i,1,nn}];CoefficientList[Series[Product[1/(1-y x^i)^ft[[i]],{i,1,nn}],{x,0,20}],{x,y}]//Grid (* Geoffrey Critzer, Oct 13 2012, after code given by Robert A. Russell in A000055 *)

Formula

T(n, k) = sum over the partitions of n, 1M1 + 2M2 + ... + nMn, with exactly k parts, of Product_{i=1..n} binomial(A000055(i) + Mi - 1, Mi). - Washington Bomfim, May 12 2005

Extensions

More terms from Vladeta Jovovic, Jun 03 2004

A005197 a(n) = Sum_t t*F(n,t), where F(n,t) (see A033185) is the number of rooted forests with n (unlabeled) nodes and exactly t rooted trees.

Original entry on oeis.org

1, 3, 7, 17, 39, 96, 232, 583, 1474, 3797, 9864, 25947, 68738, 183612, 493471, 1334143, 3624800, 9893860, 27113492, 74577187, 205806860, 569678759, 1581243203, 4400193551, 12273287277, 34307646762, 96093291818, 269654004899, 758014312091, 2134300171031
Offset: 1

Views

Author

N. J. A. Sloane. Definition clarified by N. J. A. Sloane, May 29 2012

Keywords

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Maple
    with(numtheory):
    t:= proc(n) option remember; local d, j; `if`(n<=1, n,
          (add(add(d*t(d), d=divisors(j))*t(n-j), j=1..n-1))/(n-1))
        end:
    b:= proc(n, i, p) option remember; `if`(p>n, 0, `if`(n=0, 1,
          `if`(min(i, p)<1, 0, add(b(n-i*j, i-1, p-j) *
           binomial(t(i)+j-1, j), j=0..min(n/i, p)))))
        end:
    a:= a-> add(k*b(n, n, k), k=1..n):
    seq(a(n), n=1..40);  # Alois P. Heinz, Aug 20 2012
  • Mathematica
    t[1] = 1; t[n_] := t[n] = Module[{d, j}, Sum[Sum[d*t[d], {d, Divisors[j]}]*t[n-j], {j, 1, n-1}]/(n-1)]; b[1, 1, 1] = 1; b[n_, i_, p_] := b[n, i, p] = If[p>n, 0, If[n == 0, 1, If[Min[i, p]<1, 0, Sum[b[n-i*j, i-1, p-j]*Binomial[t[i]+j-1, j], {j, 0, Min[n/i, p]}]]]]; a[n_] := Sum[k*b[n, n, k], {k, 1, n}]; Table[a[n] // FullSimplify, {n, 1, 30}] (* Jean-François Alcover, Mar 13 2014, after Alois P. Heinz *)

Formula

To get a(n), take row n of the triangle in A033185, multiply successive terms by 1, 2, 3, ... and sum. E.g. a(4) = 1*4+2*3+3*1+4*1 = 17.
a(n) ~ c * d^n / n^(3/2), where d = A051491 = 2.955765285..., c = 2.85007275... . - Vaclav Kotesovec, Sep 10 2014

Extensions

More terms from Alois P. Heinz, Aug 20 2012

A005199 a(n) = Sum_t t*F(n,t), where F(n,t) is the number of forests with n (unlabeled) nodes and exactly t trees, all of which are planted (that is, rooted trees in which the root has degree 1).

Original entry on oeis.org

0, 1, 1, 4, 6, 18, 35, 93, 214, 549, 1362, 3534, 9102, 23951, 63192, 168561, 451764, 1219290, 3305783, 9008027, 24643538, 67681372, 186504925, 515566016, 1429246490, 3972598378, 11068477743, 30908170493, 86488245455, 242481159915, 681048784377, 1916051725977, 5399062619966
Offset: 1

Views

Author

Keywords

Comments

The triangular array F(n,t) (analogous to A095133 for A005196 and A033185 for A005197) is A336087.

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • PARI
    g(m) = {my(f); if(m==0, return(1)); f = vector(m+1); f[1]=1;
    for(j=1, m, f[j+1]=1/j * sum(k=1, j, sumdiv(k,d, d * f[d]) * f[j-k+1])); f[m+1] };
    global(max_n = 130); A000081 = vector(max_n, n, g(n-1));
    F(n,t)={my(s=0, D, c, P_1); forpart(P_1 = n, D = Set(P_1); c = vector(#D);
    for(k=1, #D, c[k] = #select(x->x == D[k], Vec(P_1)));
    s += prod(k=1, #D, binomial( A000081[D[k]-1] + c[k] - 1, c[k]) )
    ,[2,n],[t,t]); s};
    seq(n) = sum(t=1,n\2, t*F(n,t) ); \\   Washington Bomfim, Jul 08 2020

Formula

a(n) = Sum_{t=1, floor(n/2)}( t*F(n,t) ), where F(n,t) = Sum_{P_1(n,t)} (Product_{k=2..n} binomial(A000081(k-1) + c_k - 1, c_k)), where P_1(n, t) is the set of the partitions of n with t parts greater than one: 2*c_2 + ... + n*c_n = n; c_2, ..., c_n >= 0. - Washington Bomfim, Jul 08 2020

Extensions

Definition clarified by N. J. A. Sloane, May 29 2012

A095131 Numerators of average numbers of trees in a forest on n nodes.

Original entry on oeis.org

1, 3, 2, 13, 12, 49, 93, 5, 127, 803, 1703, 3755, 271, 19338, 45275, 108229, 262604, 647083, 1613941, 2036099, 576341, 13331695, 264583, 90049334, 236302157, 38973748, 330784573, 8814122981, 7861906901, 63359160443, 42703885427
Offset: 1

Views

Author

Eric W. Weisstein, May 29 2004

Keywords

Examples

			1, 3/2, 2, 13/6, 12/5, 49/20, 93/37, 5/2, 127/51, ...
		

Crossrefs

Formula

Numerators of A005196/A005195.

Extensions

More terms from Vladeta Jovovic, Jun 03 2004

A095132 Denominators of average numbers of trees in a forest on n nodes.

Original entry on oeis.org

1, 2, 1, 6, 5, 20, 37, 2, 51, 329, 710, 1601, 118, 8599, 20514, 49905, 122963, 307199, 775529, 988939, 282591, 6592078, 131812, 45164337, 119237493, 19774239, 168670563, 4514955632, 4044075790, 32717113805, 22129966762, 240235675303
Offset: 1

Views

Author

Eric W. Weisstein, May 29 2004

Keywords

Examples

			1, 3/2, 2, 13/6, 12/5, 49/20, 93/37, 5/2, 127/51, ...
		

Crossrefs

Formula

Denominators of A005196/A005195.

Extensions

More terms from Vladeta Jovovic, Jun 03 2004
Showing 1-5 of 5 results.