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-9 of 9 results.

A124890 G.f.: A(x) = (1/x)*series_reversion(x^2/G124344(x)), where G124344(x) is the g.f. of A124344 and satisfies: A(x)^2 = (1/x)*G124344(x*A(x)).

Original entry on oeis.org

1, 1, 3, 11, 47, 216, 1047, 5263, 27191, 143484, 770047, 4190031, 23062044, 128170182, 718257014, 4054089110, 23026890216, 131517480529, 754865316100, 4351785130675, 25187530716367, 146305151254984, 852604651815745
Offset: 0

Views

Author

Paul D. Hanna, Nov 12 2006

Keywords

Comments

A124344(n) is the number of ordered rooted trees on n nodes with thinning limbs.

Crossrefs

Formula

a(n) = A124889(n)/(n+1). a(n) = A124328(2n+1,n+1)/(n+1).

A090344 Number of Motzkin paths of length n with no level steps at odd level.

Original entry on oeis.org

1, 1, 2, 3, 6, 11, 23, 47, 102, 221, 493, 1105, 2516, 5763, 13328, 30995, 72556, 170655, 403351, 957135, 2279948, 5449013, 13063596, 31406517, 75701508, 182902337, 442885683, 1074604289, 2612341856, 6361782007, 15518343597, 37912613631, 92758314874
Offset: 0

Views

Author

Emeric Deutsch, Jan 28 2004

Keywords

Comments

a(n) = number of Motzkin paths of length n that avoid UF. Example: a(3) counts FFF, UDF, FUD but not UFD. - David Callan, Jul 15 2004
Also, number of 1-2 trees with n edges and with thinning limbs. A 1-2 tree is an ordered tree with vertices of outdegree at most 2. A rooted tree with thinning limbs is such that if a node has k children, all its children have at most k children. - Emeric Deutsch and Louis Shapiro, Nov 04 2006

Examples

			a(3)=3 because we have HHH, HUD and UDH, where U=(1,1), D=(1,-1) and H=(1,0).
		

Crossrefs

Programs

  • Magma
    [(&+[Binomial(n-k, k)*Catalan(k): k in [0..Floor(n/2)]]): n in [0..40]]; // G. C. Greubel, Jun 15 2022
    
  • Maple
    C:=x->(1-sqrt(1-4*x))/2/x: G:=C(z^2/(1-z))/(1-z): Gser:=series(G,z=0,40): seq(coeff(Gser,z,n),n=0..36);
    # second Maple program:
    a:= proc(n) option remember; `if`(n<3, (n^2-n+2)/2,
         ((2*n+2)*a(n-1) -(4*n-6)*a(n-3) +(3*n-4)*a(n-2))/(n+2))
        end:
    seq(a(n), n=0..40); # Alois P. Heinz, May 17 2013
  • Mathematica
    Table[HypergeometricPFQ[{1/2, (1-n)/2, -n/2}, {2, -n}, -16], {n, 0, 40}] (* Jean-François Alcover, Feb 20 2015, after Paul Barry *)
  • PARI
    {a(n)=local(A=1+x);for(i=1,n,A=1/(1-x+x*O(x^n))+x^2*A^2+x*O(x^n));polcoeff(A,n)} \\ Paul D. Hanna, Jun 24 2012
    
  • SageMath
    [sum(binomial(n-k,k)*catalan_number(k) for k in (0..(n//2))) for n in (0..40)] # G. C. Greubel, Jun 15 2022

Formula

G.f.: (1-x-sqrt(1-2*x-3*x^2+4*x^3))/(2*x^2*(1-x)).
G.f. satisfies: A(x) = 1/(1-x) + x^2*A(x)^2. - Paul D. Hanna, Jun 24 2012
D-finite with recurrence (n+2)*a(n) = 2*(n+1)*a(n-1) + (3*n-4)*a(n-2) - 2*(2*n-3)*a(n-3). - Vladeta Jovovic, Sep 11 2004
a(n) = Sum_{k=0..floor(n/2)} binomial(n-k, k)*binomial(2*k, k)/(k+1). - Paul Barry, Nov 13 2004
a(n) = 1 + Sum_{k=1..n-1} a(k-1)*a(n-k-1). - Henry Bottomley, Feb 22 2005
G.f.: 1/(1-x-x^2/(1-x^2/(1-x-x^2/(1-x^2/(1-x-x^2/(1-x^2/(1-... (continued fraction). - Paul Barry, Apr 08 2009
With M = an infinite tridiagonal matrix with all 1's in the super and subdiagonals and [1,0,1,0,1,0,...] in the main diagonal and V = vector [1,0,0,0,...] with the rest zeros, the sequence starting with offset 1 = leftmost column iterates of M*V. - Gary W. Adamson, Jun 08 2011
Recurrence (an alternative): (n+2)*a(n) = 3*(n+1)*a(n-1) + (n-4)*a(n-2) - (7*n-13)*a(n-3) + 2*(2*n-5)*a(n-4), n>=4. - Fung Lam, Apr 01 2014
Asymptotics: a(n) ~ (8/(sqrt(17)-1))^n*( 1/17^(1/4) + 17^(1/4) )*17 /(16*sqrt(Pi*n^3)). - Fung Lam, Apr 01 2014
a(n) = 2*A026569(n) + A026569(n+1)/2 - A026569(n+2)/2. - Mark van Hoeij, Nov 29 2024

A124343 Number of rooted trees on n nodes with thinning limbs.

Original entry on oeis.org

1, 1, 2, 3, 6, 10, 21, 38, 78, 153, 314, 632, 1313, 2700, 5646, 11786, 24831, 52348, 111027, 235834, 502986, 1074739, 2303146, 4944507, 10639201, 22930493, 49511948, 107065966, 231874164, 502834328, 1091842824, 2373565195, 5165713137, 11254029616, 24542260010
Offset: 1

Views

Author

Christian G. Bower, Oct 30 2006, suggested by Franklin T. Adams-Watters

Keywords

Comments

A rooted tree with thinning limbs is such that if a node has k children, all its children have at most k children.

Examples

			The a(5) = 6 trees are ((((o)))), (o((o))), (o(oo)), ((o)(o)), (oo(o)), (oooo). - _Gus Wiseman_, Jan 25 2018
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, h, v) option remember; `if`(n=0,
          `if`(v=0, 1, 0), `if`(i<1 or v<1 or n A(n$2):
    seq(a(n), n=1..35);  # Alois P. Heinz, Jul 08 2014
  • Mathematica
    b[n_, i_, h_, v_] := b[n, i, h, v] = If[n==0, If[v==0, 1, 0], If[i<1 || v<1 || nJean-François Alcover, Mar 01 2016, after Alois P. Heinz *)

Extensions

More terms from Alois P. Heinz, Jul 04 2014

A124328 Triangle read by rows: T(n,k) is the number of ordered trees with n edges, with thinning limbs and with root of degree k (1<=k<=n). An ordered tree with thinning limbs is such that if a node has k children, all its children have at most k children.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 5, 3, 1, 1, 10, 9, 4, 1, 1, 22, 25, 14, 5, 1, 1, 46, 69, 44, 20, 6, 1, 1, 101, 186, 137, 70, 27, 7, 1, 1, 220, 503, 416, 235, 104, 35, 8, 1, 1, 492, 1356, 1256, 766, 375, 147, 44, 9, 1, 1, 1104, 3663, 3760, 2465, 1296, 567, 200, 54, 10, 1, 1, 2515, 9907
Offset: 1

Views

Author

Emeric Deutsch, Nov 03 2006

Keywords

Comments

Row sums yield A124344. T(n,2) = A124329(n).

Examples

			Triangle starts:
  1;
  1,1;
  1,2,1;
  1,5,3,1;
  1,10,9,4,1;
		

Crossrefs

Programs

  • Mathematica
    t[n_, n_] = 1; t[n_, k_] /; n == k + 1 := t[n, k] = n - 1; t[n_, k_] := t[n, k] = Coefficient[(1 + x*Sum[ x^(r - 1)*Sum[ t[r, c], {c, 1, k }], {r, 1, n - k}] + x^n)^k, x, n - k ]; Table[t[n, k], {n, 1, 12}, {k, 1, n}] // Flatten (* Jean-François Alcover, Jan 21 2013, after Paul D. Hanna *)
  • PARI
    {T(n,k)=if(n==k,1,if(n==k+1,n-1,polcoeff( (1 + x*sum(r=1,n-k,x^(r-1)*sum(c=1,k,T(r,c)))+x*O(x^n))^k,n-k)))} \\ Paul D. Hanna, Nov 12 2006

Formula

The g.f. F[k]=F[k](z) of column k satisfies F[k]=(F[k-1]^(1/(k-1)) + z*F[k])^k; F[1]=z/(1-z).
Central terms are: T(2*n-1,n) = A124889(n-1), T(2*n,n) = A124891(n-1), for n>=1. - Paul D. Hanna, Nov 12 2006

Extensions

More terms from Paul D. Hanna, Nov 12 2006

A124497 Number of 1-2-3 trees with n edges and with thinning limbs.

Original entry on oeis.org

1, 1, 2, 4, 9, 20, 48, 116, 288, 724, 1849, 4768, 12423, 32628, 86342, 229952, 616042, 1659012, 4489101, 12199521, 33284546, 91140797, 250396629, 690043032, 1907022197, 5284167884, 14677681554, 40862469713, 114001697975
Offset: 0

Views

Author

Emeric Deutsch and Louis Shapiro, Nov 04 2006

Keywords

Comments

A 1-2-3 tree is an ordered tree with vertices of outdegree at most 3. A rooted tree with thinning limbs is such that if a node has k children, all its children have at most k children.

Crossrefs

Programs

  • Maple
    C:=x->(1-sqrt(1-4*x))/2/x: T:=x->2/sqrt(3*x)*sin((1/3)*arcsin(sqrt(27*x/4))): M2:=C(z^2/(1-z))/(1-z): G:=M2*T(M2^2*z^3): Gser:=series(G,z=0,40): seq(coeff(Gser,z,n),n=0..33);
  • Mathematica
    Table[(Sum[Binomial[3*m, m] * Sum[(Binomial[2*m + 2*k, k]*Binomial[n - m - k, 2*m + k])/(2*m + k + 1), {k, 0, n - m}], {m, 1, n + 2}]) + Sum[(Binomial[2*k, k]*Binomial[n - k, k])/(k + 1), {k, 0, n/2}], {n, 0, 40}] (* Vaclav Kotesovec, Apr 22 2016, after Vladimir Kruchinin *)
  • Maxima
    a(n):=(sum(binomial(3*m,m)*sum((binomial(2*m+2*k,k)*binomial(n-m-k,2*m+k))/(2*m+k+1),k,0,n-m),m,1,n+2))+sum((binomial(2*k,k)*binomial(n-k,k))/(k+1),k,0,n/2); /* Vladimir Kruchinin, Apr 22 2016 */

Formula

G.f.: H*T(H^2*z^3), where T=2/sqrt(3*x)*sin((1/3)*arcsin(sqrt(27*x/4))) (solution of T=1+zT^3, T(0)=1), H=C(z^2/(1-z))/(1-z) and C(x)=[1-sqrt(1-4x)]/(2x) is the Catalan function.
More generally, if M[k](z) is the g.f. of the 1-2-...-k trees with thinning limbs and C[k](z)=1+z*{C[k](z)}^k is the g.f. of the k-ary trees, then M[k](z)=M[k-1](z)C[k](M[k-1]^(k-1)*z^k).
a(n) = Sum_{m=1..n+2} (binomial(3*m,m)*Sum_{k=0..n-m}((binomial(2*m+2*k,k)* binomial(n-m-k,2*m+k))/(2*m+k+1))) + Sum_{k=0..n/2}((binomial(2*k,k)*binomial(n-k,k))/(k+1)). - Vladimir Kruchinin, Apr 24 2016
a(n) ~ c * d^n / n^(3/2), where d = (116 + (13044347 - 19683*sqrt(419729))^(1/3) + (13044347 + 19683*sqrt(419729))^(1/3)) / 162 = 2.949682448495588889993... and c = sqrt((9801741469 + 2*(101206884976506223911903300479 - 12725091747254383734308121 * sqrt(419729))^(1/3) + 2*(101206884976506223911903300479 + 12725091747254383734308121 * sqrt(419729))^(1/3)) / (773*Pi)) / 2916 = 1.1733468012519971025510728494463... . - Vaclav Kotesovec, Apr 22 2016

A124499 Number of 1-2-3-4 trees with n edges and with thinning limbs. A 1-2-3-4 tree is an ordered tree with vertices of outdegree at most 4. A rooted tree with thinning limbs is such that if a node has k children, all its children have at most k children.

Original entry on oeis.org

1, 1, 2, 4, 10, 24, 62, 160, 425, 1140, 3105, 8528, 23643, 66008, 185526, 524384, 1489810, 4251852, 12184745, 35048405, 101156752, 292865417, 850314803, 2475327088, 7223400899, 21126670372, 61920289652, 181838859665
Offset: 0

Views

Author

Emeric Deutsch and Louis Shapiro, Nov 06 2006

Keywords

Comments

The sequences corresponding to k=2 (A090344), k=3 (A124497), k=4 (this A124499), k=5 (A124500), etc. approach sequence A124344, corresponding to ordered trees with thinning limbs.

Crossrefs

Programs

  • PARI
    {a(n)=local(k=4,M=1+x*O(x^n)); for(i=1,k,M=M*sum(j=0,n,binomial(i*j,j)/((i-1)*j+1)*(x^i*M^(i-1))^j)); polcoeff(M,n)} \\ Paul D. Hanna

Formula

In general, if M[k](z) is the g.f. of the 1-2-...-k trees with thinning limbs and C[k](z)=1+z*{C[k](z)}^k is the g.f. of the k-ary trees, then M[k](z)=M[k-1](z)*C[k](M[k-1]^(k-1)*z^k), M[1](z)=1/(1-z).

A124500 Number of 1-2-3-4-5 trees with n edges and with thinning limbs. A 1-2-3-4-5 tree is an ordered tree with vertices of outdegree at most 5. A rooted tree with thinning limbs is such that if a node has k children, all its children have at most k children.

Original entry on oeis.org

1, 1, 2, 4, 10, 25, 67, 180, 495, 1375, 3871, 10993, 31493, 90843, 263686, 769466, 2256135, 6643082, 19634705, 58232350, 173242381, 516860717, 1546035258, 4635543843, 13929569399, 41943013047, 126532961332, 382396277940
Offset: 0

Views

Author

Emeric Deutsch and Louis Shapiro, Nov 06 2006

Keywords

Comments

The sequences corresponding to k=2 (A090344), k=3 (A124497), k=4 (A124499), k=5 (this A124500), etc. approach sequence A124344, corresponding to ordered trees with thinning limbs.

Crossrefs

Programs

  • PARI
    {a(n)=local(k=5,M=1+x*O(x^n)); for(i=1,k,M=M*sum(j=0,n,binomial(i*j,j)/((i-1)*j+1)*(x^i*M^(i-1))^j)); polcoeff(M,n)} \\ Paul D. Hanna

Formula

In general, if M[k](z) is the g.f. of the 1-2-...-k trees with thinning limbs and C[k](z)=1+z*{C[k](z)}^k is the g.f. of the k-ary trees, then M[k](z)=M[k-1](z)*C[k](M[k-1]^(k-1)*z^k), M[1](z)=1/(1-z).

A124501 Number of 1-2-3-4-5-6 trees with n edges and with thinning limbs. A 1-2-3-4-5-6 tree is an ordered tree with vertices of outdegree at most 6. A rooted tree with thinning limbs is such that if a node has k children, all its children have at most k children.

Original entry on oeis.org

1, 1, 2, 4, 10, 25, 68, 186, 522, 1479, 4246, 12289, 35872, 105411, 311662, 926270, 2765778, 8292296, 24953437, 75338686, 228140842, 692733127, 2108652750, 6433255041, 19668210742, 60247367313, 184879648441, 568281131800
Offset: 0

Views

Author

Emeric Deutsch and Louis Shapiro, Nov 06 2006

Keywords

Comments

The sequences corresponding to k=2 (A090344), k=3 (A124497), k=4 (A124499), k=5 (A124500), k=6 (this A124501), etc. approach sequence A124344, corresponding to ordered trees with thinning limbs.

Crossrefs

Programs

  • PARI
    {a(n)=local(k=6,M=1+x*O(x^n)); for(i=1,k,M=M*sum(j=0,n,binomial(i*j,j)/((i-1)*j+1)*(x^i*M^(i-1))^j)); polcoeff(M,n)} \\ Paul D. Hanna

Formula

In general, if M[k](z) is the g.f. of the 1-2-...-k trees with thinning limbs and C[k](z)=1+z*{C[k](z)}^k is the g.f. of the k-ary trees, then M[k](z)=M[k-1](z)*C[k](M[k-1]^(k-1)*z^k), M[1](z)=1/(1-z).

A124329 Number of ordered trees with n edges, with thinning limbs and with root of degree 2. An ordered tree with thinning limbs is such that if a node has k children, all its children have at most k children.

Original entry on oeis.org

0, 1, 2, 5, 10, 22, 46, 101, 220, 492, 1104, 2515, 5762, 13327, 30994, 72555, 170654, 403350, 957134, 2279947, 5449012, 13063595, 31406516, 75701507, 182902336, 442885682, 1074604288, 2612341855, 6361782006, 15518343596, 37912613630
Offset: 1

Views

Author

Emeric Deutsch, Nov 03 2006

Keywords

Comments

Column 2 of A124328.

Crossrefs

Programs

  • Maple
    G:=(1-z-2*z^2-sqrt(1-2*z-3*z^2+4*z^3))/2/z^2/(1-z): Gser:=series(G,z=0,40): seq(coeff(Gser,z,n),n=1..36);
    # second Maple program:
    a:= proc(n) option remember; `if`(n<4, [0$2, 1, 2][n+1],
          ((3*n+3)*a(n-1) +(n-4)*a(n-2) -(7*n-13)*a(n-3)
           +(4*n-10)*a(n-4)) / (n+2))
        end:
    seq(a(n), n=1..40);  # Alois P. Heinz, Jul 08 2014
  • Mathematica
    Rest[CoefficientList[Series[(1-x-2*x^2-Sqrt[1-2*x-3*x^2+4*x^3])/2/x^2/(1-x), {x, 0, 20}], x]] (* Vaclav Kotesovec, Sep 04 2014 *)
    Table[2*Sum[((Binomial[2*k + 1, k + 1]*Binomial[n - k, k + 1])/(k + 2)), {k, 0, (n - 1)/2}], {n, 0, 20}] (* Vaclav Kotesovec, Apr 22 2016, after Vladimir Kruchinin *)
  • Maxima
    a(n):=2*sum((binomial(2*k+1, k+1)*binomial(n-k, k+1))/(k+2), k, 0, (n-1)/2); /* Vladimir Kruchinin, Apr 21 2016 */

Formula

G.f.: [1-z-2z^2-sqrt(1-2z-3z^2+4z^3)]/[2(1-z)z^2].
a(n) ~ sqrt(493+101*sqrt(17)) * (1+sqrt(17))^n / (sqrt(Pi) * n^(3/2) * 2^(n+7/2)). - Vaclav Kotesovec, Sep 04 2014
a(n) = 2*Sum_{k = 0..(n-1)/2} binomial(2*k+1, k+1)*binomial(n-k, k+1)/(k+2). - Vladimir Kruchinin, Apr 21 2016
D-finite with recurrence (n+2)*a(n) +3*(-n-1)*a(n-1) +(-n+4)*a(n-2) +(7*n-13)*a(n-3) +2*(-2*n+5)*a(n-4)=0. - R. J. Mathar, Jul 26 2022
Showing 1-9 of 9 results.