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

A118376 Number of all trees of weight n, where nodes have positive integer weights and the sum of the weights of the children of a node is equal to the weight of the node.

Original entry on oeis.org

1, 2, 6, 24, 112, 568, 3032, 16768, 95200, 551616, 3248704, 19389824, 117021824, 712934784, 4378663296, 27081760768, 168530142720, 1054464293888, 6629484729344, 41860283723776, 265346078982144, 1687918305128448, 10771600724946944, 68941213290561536
Offset: 1

Views

Author

Jeremy Johnson (jjohnson(AT)cs.drexel.edu), May 15 2006

Keywords

Comments

The number of trees with leaf nodes equal to 1 is counted by the sequence A001003 of super-Catalan numbers. The number of binary trees is counted by the sequence A007317 and the number of binary trees with leaf nodes equal to 1 is counted by the sequence A000108 of Catalan numbers.
Also the number of series-reduced enriched plane trees of weight n. A series-reduced enriched plane tree of weight n is either the number n itself or a finite sequence of at least two series-reduced enriched plane trees, one of each part of an integer composition of n. For example, the a(3) = 6 trees are: 3, (21), (12), (111), ((11)1), (1(11)). - Gus Wiseman, Sep 11 2018
Conjectured to be the number of permutations of length n avoiding the partially ordered pattern (POP) {1>2, 1>3, 3>4, 3>5} of length 5. That is, conjectured to be the number of length n permutations having no subsequences of length 5 in which the first element is the largest, and the third element is larger than the fourth and fifth elements. - Sergey Kitaev, Dec 13 2020
This conjecture has been proven. It can be restated as the number of size n permutations avoiding 51423, 51432, 52413, 52431, 53412, 53421, 54312, 54321. There are twelve sets of permutations avoiding eight size five permutations that are known to match this sequence. A further four are conjectured to match this sequence. - Christian Bean, Jul 24 2024

Examples

			T(3) = 6 because there are six trees
  3    3      3     3     3       3
      2 1    2 1   1 2   1 2    1 1 1
            1 1           1 1
From _Gus Wiseman_, Sep 11 2018: (Start)
The a(4) = 24 series-reduced enriched plane trees:
  4,
  (31), (13), (22), (211), (121), (112), (1111),
  ((21)1), ((12)1), (1(21)), (1(12)), (2(11)), ((11)2),
  ((111)1), (1(111)), ((11)(11)), ((11)11), (1(11)1), (11(11)),
  (((11)1)1), ((1(11))1), (1((11)1)), (1(1(11))).
(End)
		

Crossrefs

Programs

  • Maple
    T := proc(n) option remember; local C, s, p, tp, k, i; if n = 1 then return 1; else s := 1; for k from 2 to n do C := combinat[composition](n,k); for p in C do tp := map(T,p); s := s + mul(tp[i],i=1..nops(tp)); end do; end do; end if; return s; end;
  • Mathematica
    Rest[CoefficientList[Series[(Sqrt[1-8*x+8*x^2]-1)/(4*x-4), {x, 0, 20}], x]] (* Vaclav Kotesovec, Feb 03 2014 *)
    a[n_] := 1+Sum[Binomial[n-1, k-1]*Hypergeometric2F1[2-k, k+1, 2, -1], {k, 2, n}]; Table[a[n], {n, 1, 20}] (* Jean-François Alcover, Apr 03 2015, after Vladimir Kruchinin *)
    urp[n_]:=Prepend[Join@@Table[Tuples[urp/@ptn],{ptn,Join@@Permutations/@Select[IntegerPartitions[n],Length[#]>1&]}],n];
    Table[Length[urp[n]],{n,7}] (* Gus Wiseman, Sep 11 2018 *)
  • Maxima
    a(n):=sum((-1)^j*2^(n-j-1)*binomial(n,j)*binomial(2*n-2*j-2,n-2*j-1),j,0,(n-1)/2)/n; /* Vladimir Kruchinin, Sep 29 2020 */
  • PARI
    x='x+O('x^25); Vec((sqrt(1-8*x+8*x^2) - 1)/(4*x-4)) \\ G. C. Greubel, Feb 08 2017
    

Formula

Recurrence: T(1) = 1; For n > 1, T(n) = 1 + Sum_{n=n1+...+nt} T(n1)*...*T(nt).
G.f.: (-1+(1-8*z+8*z^2)^(1/2))/(-4+4*z).
From Vladimir Kruchinin, Sep 03 2010: (Start)
O.g.f.: A(x) = A001003(x/(1-x)).
a(n) = Sum_{k=1..n} binomial(n-1,k-1)*A001003(k), n>0. (End)
D-finite with recurrence: n*a(n) + 3*(-3*n+4)*a(n-1) + 4*(4*n-9)*a(n-2) + 8*(-n+3)*a(n-3) = 0. - R. J. Mathar, Sep 27 2013
a(n) ~ sqrt(sqrt(2)-1) * 2^(n-1/2) * (2+sqrt(2))^(n-1) / (sqrt(Pi) * n^(3/2)). - Vaclav Kotesovec, Feb 03 2014
From Peter Bala, Jun 17 2015: (Start)
With offset 0, binomial transform of A001003.
O.g.f. A(x) = series reversion of x*(2*x - 1)/(2*x^2 - 1); 2*(1 - x)*A^2(x) - A(x) + x = 0.
A(x) satisfies the differential equation (x - 9*x^2 + 16*x^3 - 8*x^4)*A'(x) + x*(3 - 4*x)*A(x) + x*(2*x - 1) = 0. Extracting coefficients gives Mathar's recurrence above. (End)
a(n) = Sum_{j=0..(n-1)/2} (-1)^j*2^(n-j-1)*C(n,j)*C(2*n-2*j-2,n-2*j-1)/n. - Vladimir Kruchinin, Sep 29 2020

A055363 Triangle of asymmetric mobiles (circular rooted trees) with n nodes and k leaves.

Original entry on oeis.org

1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 2, 1, 0, 0, 1, 4, 4, 1, 0, 0, 1, 6, 10, 5, 1, 0, 0, 1, 9, 22, 19, 7, 1, 0, 0, 1, 12, 42, 53, 31, 8, 1, 0, 0, 1, 16, 73, 130, 109, 45, 10, 1, 0, 0, 1, 20, 119, 280, 321, 190, 63, 11, 1, 0, 0, 1, 25, 184, 556, 833, 672, 310, 83, 13, 1, 0, 0, 1, 30, 272
Offset: 1

Views

Author

Christian G. Bower, May 15 2000

Keywords

Examples

			G.f. = x*(y + x*y + x^2*y + x^3*(y + y^2) + x^4*(y + 2*y^2 + y^3) + x^5*(y + 4*y^2 + 4*y^3 + y^4) + ...).
n\k 1  2  3  4  5  6  7  8
--:-- -- -- -- -- -- -- --
1:  1
2:  1  0
3:  1  0  0
4:  1  1  0  0
5:  1  2  1  0  0
6:  1  4  4  1  0  0
7:  1  6 10  5  1  0  0
8:  1  9 22 19  7  1  0  0
		

Crossrefs

Row sums give A032171.

Programs

  • Mathematica
    T[n_, k_] := Module[{A}, A[, ] = 0; If[k<1 || k>n, 0, For[j=1, j <= n, j++, A[x_, y_] = x*y-x*Sum[MoebiusMu[i]/i * Log[1 - A[x^i, y^i]] + O[x]^j // Normal, {i, 1, j}]]; Coefficient[Coefficient[A[x, y], x, n], y, k]]];
    Table[T[n, k], {n, 1, 13}, {k, 1, n}] // Flatten (* Jean-François Alcover, Jun 30 2017, after Michael Somos *)
  • PARI
    {T(n, k) = my(A = O(x)); if(k<1 || k>n, 0, for(j=1, n, A = x*y - x*sum(i=1, j, moebius(i)/i * log(1 - subst( subst( A + x * O(x^min(j, n\i)), x, x^i), y, y^i) ) )); polcoeff( polcoeff(A, n), k))}; /* Michael Somos, Aug 24 2015 */

Formula

G.f. satisfies A(x, y) = x*(y - Sum_{i>0} moebius(i)/i * log(1 - A(x^i, y^i))). - Michael Somos, Aug 19 2015
Sum_k T(n, k) = A032171(n). - Michael Somos, Aug 24 2015

A032200 Number of rooted compound windmills (mobiles) of n nodes.

Original entry on oeis.org

1, 1, 2, 4, 9, 20, 51, 128, 345, 940, 2632, 7450, 21434, 62174, 182146, 537369, 1596133, 4767379, 14312919, 43162856, 130695821, 397184252, 1211057426, 3703794849, 11358759346, 34923477315, 107627138308, 332404636811
Offset: 1

Views

Author

Keywords

Comments

Also the number of locally necklace plane trees with n nodes, where a plane tree is locally necklace if the sequence of branches directly under any given node is lexicographically minimal among its cyclic permutations. - Gus Wiseman, Sep 05 2018

Examples

			From _Gus Wiseman_, Sep 05 2018: (Start)
The a(5) = 9 locally necklace plane trees:
  ((((o))))
  (((oo)))
  ((o(o)))
  (o((o)))
  ((o)(o))
  ((ooo))
  (o(oo))
  (oo(o))
  (oooo)
(End)
		

References

  • F. Bergeron, G. Labelle and P. Leroux, Combinatorial Species and Tree-Like Structures, Camb. 1998, p. 241 (3.3.84).

Crossrefs

Programs

  • Mathematica
    neckQ[q_]:=Array[OrderedQ[{q,RotateRight[q,#]}]&,Length[q]-1,1,And];
    neckplane[n_]:=If[n==1,{{}},Join@@Table[Select[Tuples[neckplane/@c],neckQ],{c,Join@@Permutations/@IntegerPartitions[n-1]}]];
    Table[Length[neckplane[n]],{n,10}] (* Gus Wiseman, Sep 05 2018 *)
  • PARI
    CIK(p,n)={sum(d=1, n, eulerphi(d)/d*log(subst(1/(1+O(x*x^(n\d))-p), x, x^d)))}
    seq(n)={my(p=O(1));for(i=1, n, p=1+CIK(x*p, i)); Vec(p)} \\ Andrew Howroyd, Jun 20 2018

Formula

Shifts left under "CIK" (necklace, indistinct, unlabeled) transform.

A108529 Number of asymmetric mobiles (cycle rooted trees) with n generators.

Original entry on oeis.org

1, 1, 2, 5, 16, 51, 177, 621, 2246, 8245, 30783, 116257, 443945, 1710255, 6640939, 25961690, 102105115, 403701135, 1603721999, 6397931901, 25621989760, 102965680728, 415091909292, 1678226164646, 6803121058354, 27645628327636
Offset: 1

Views

Author

Christian G. Bower, Jun 07 2005

Keywords

Comments

A generator is a leaf or a node with just one child.
Here CHK(A(x)) = 1 - Sum_{n>=1} (mu(n)/n)*log(1-A(x^n)), i.e., the constant 1 is included in the definition of the CHK transform. For other sequences that involve the CHK transform, the 1 is sometimes dropped; e.g., see sequence A032171. We have CHK(A(x)) = x + x^2 + 3*x^3 + 8*x^4 + 27*x^5 + 86*x^6 + 303*x^7 + 1065*x^8 + 3871*x^9 + ... - Petros Hadjicostas, Dec 05 2017

Crossrefs

Programs

  • PARI
    CHK(p,n)={sum(d=1, n, moebius(d)/d*log(subst(1/(1+O(x*x^(n\d))-p), x, x^d)))}
    seq(n)={my(p=x); for(n=2, n, p += x^n*polcoef(x*p + CHK(p, n), n)); Vecrev(p/x)} \\ Andrew Howroyd, Aug 31 2018

Formula

G.f. satisfies: (2-x)*A(x) = x - 1 + CHK(A(x)).
From Petros Hadjicostas, Dec 05 2017: (Start)
a(n) = (1/2)*(a(n-1) + (1/n)*Sum_{d|n} mu(d)*c(n/d)) for n>=2, where c(n) = n*a(n) + Sum_{s=1..n-1} c(s)*a(n-s) and a(1) = c(1) = 1.
The g.f. satisfies (2-x)*A(x) = x - Sum_{n>=1} (mu(n)/n)*log(1-A(x^n)). (This is just a rephrasing of C. Bower's equation above.)
The auxiliary sequence (c(n): n>=1} has g.f. C(x) = Sum_{n>=1} c(n)*x^n = x*(dA/dx)/(1-A(x)) = x + 3*x^2 + 10*x^3 + 35*x^4 + 136*x^5 + 528*x^6 + 2122*x^7 + ...
(End)

A317852 Number of plane trees with n nodes where the sequence of branches directly under any given node is aperiodic, meaning its cyclic permutations are all different.

Original entry on oeis.org

1, 1, 1, 3, 8, 26, 76, 247, 783, 2565, 8447, 28256, 95168, 323720, 1108415, 3821144, 13246307, 46158480, 161574043, 567925140, 2003653016, 7092953340, 25186731980, 89690452750, 320221033370, 1146028762599, 4110596336036, 14774346783745, 53203889807764, 191934931634880
Offset: 1

Views

Author

Gus Wiseman, Sep 05 2018

Keywords

Comments

Also the number of plane trees with n nodes where the sequence of branches directly under any given node has relatively prime run-lengths.

Examples

			The a(5) = 8 locally aperiodic plane trees:
  ((((o)))),
  (((o)o)), ((o(o))), (((o))o), (o((o))),
  ((o)oo), (o(o)o), (oo(o)).
The a(6) = 26 locally aperiodic plane trees:
  (((((o)))))  ((((o)o)))  (((o)oo))  ((o)ooo)
               (((o(o))))  ((o(o)o))  (o(o)oo)
               ((((o))o))  ((oo(o)))  (oo(o)o)
               ((o((o))))  (((o)o)o)  (ooo(o))
               ((((o)))o)  ((o(o))o)
               (o(((o))))  (o((o)o))
               (((o))(o))  (o(o(o)))
               ((o)((o)))  (((o))oo)
                           (o((o))o)
                           (oo((o)))
                           ((o)(o)o)
                           ((o)o(o))
                           (o(o)(o))
		

Crossrefs

Programs

  • Mathematica
    aperQ[q_]:=Array[RotateRight[q,#]&,Length[q],1,UnsameQ];
    aperplane[n_]:=If[n==1,{{}},Join@@Table[Select[Tuples[aperplane/@c],aperQ],{c,Join@@Permutations/@IntegerPartitions[n-1]}]];
    Table[Length[aperplane[n]],{n,10}]
  • PARI
    Tfm(p, n)={sum(d=1, n, moebius(d)*(subst(1/(1+O(x*x^(n\d))-p), x, x^d)-1))}
    seq(n)={my(p=O(1)); for(i=1, n, p=1+Tfm(x*p, i)); Vec(p)} \\ Andrew Howroyd, Feb 08 2020

Extensions

a(16)-a(17) from Robert Price, Sep 15 2018
Terms a(18) and beyond from Andrew Howroyd, Feb 08 2020

A108532 Number of asymmetric mobiles (cycle rooted trees) with n nodes and 2-colored internal (non-leaf) nodes.

Original entry on oeis.org

1, 2, 4, 12, 38, 136, 490, 1852, 7108, 27880, 110892, 447060, 1821252, 7489732, 31045350, 129587996, 544228664, 2298008824, 9750218012, 41548438040, 177740526076, 763046178960, 3286318131646, 14195239150556, 61481540391722
Offset: 1

Views

Author

Christian G. Bower, Jun 07 2005

Keywords

Crossrefs

Programs

  • PARI
    CHK(p,n)={sum(d=1, n, moebius(d)/d*log(subst(1/(1+O(x*x^(n\d))-p), x, x^d)))}
    seq(n)={my(p=O(1));for(i=1, n, p=1+2*CHK(x*p, i)); Vec(p)} \\ Andrew Howroyd, Jun 20 2018

Formula

Shifts left and halves under CHK transform.

A032173 Sequence (a(n): n >= 1) that shifts left 2 places under the "CHK" (necklace, identity, unlabeled) transform and has initial terms a(1) = a(2) = 1.

Original entry on oeis.org

1, 1, 1, 1, 2, 3, 7, 12, 28, 55, 122, 258, 574, 1254, 2813, 6283, 14220, 32237, 73631, 168660, 388331, 896790, 2078822, 4832343, 11266422, 26332119, 61694574, 144858260, 340829231, 803427128, 1897269215, 4487725726
Offset: 1

Views

Author

Keywords

Comments

From Petros Hadjicostas, Dec 29 2018: (Start)
a(n+2) = (1/n)*Sum_{d|n} mu(n/d)*c(d), where c(n) = n*a(n) + Sum_{s=1..n-1} c(s)*a(n-s) with a(1) = a(2) = 1, c(1) = 1, and c(2) = 3.
G.f.: If A(x) = Sum_{n>=1} a(n)*x^n, then Sum_{n>=1} a(n+2)*x^n = -Sum_{n>=1} (mu(n)/n)*log(1-A(x^n)).
The g.f. of the auxiliary sequence (c(n): n>=1) is C(x) = Sum_{n>=1} c(n)*x^n = x*(dA(x)/dx)/(1-A(x)) = x + 3*x^2 + 7*x^3 + 15*x^4 + 36*x^5 + 81*x^6 + 197*x^7 + 455*x^8 + 1105*x^9 + 2618*x^10 + ... (The auxiliary sequence is given by sequence A322913.)
(End)
The first two terms of the sequence must be specified. In general, if the sequence (b(n): n >= 1) is such that (b(n+2): n >= 1) = CHK((b(n): n >= 1)), then b(3) = b(1), b(4) = (1/2)*(b(1)^2 + 2*b(2) - b(1)), b(5) = (b(1)/3)*(b(1)^2 + 3*b(2) + 2), and so on. - Petros Hadjicostas, Dec 31 2018

Crossrefs

Programs

  • Mathematica
    a[1] = a[2] = 1; c[1] = 1; c[2] = 3;
    a[n_] := a[n] = 1/(n-2) Sum[MoebiusMu[(n-2)/d] c[d], {d, Divisors[n-2]}];
    c[n_] := c[n] = n a[n] + Sum[c[s] a[n-s], {s, 1, n-1}];
    Array[a, 32] (* Jean-François Alcover, Jan 02 2019 *)
  • PARI
    CHK(p,n)={sum(d=1, n, moebius(d)/d*log(subst(1/(1+O(x*x^(n\d))-p), x, x^d)))}
    seq(n)={my(p=1+O(x));for(i=1, n\2, p=1+x+x*CHK(x*p, 2*i)); Vec(p+O(x^n))} \\ Andrew Howroyd, Jun 20 2018

Extensions

Name modified by Petros Hadjicostas, Jan 01 2019

A322913 Inverse Moebius transform of the sequence (n*A032173(n+2): n >= 1).

Original entry on oeis.org

1, 3, 7, 15, 36, 81, 197, 455, 1105, 2618, 6315, 15141, 36570, 88161, 213342, 516247, 1251728, 3037059, 7378290, 17938430, 43655465, 106317863, 259127707, 631986437, 1542364386, 3766351332, 9202390342, 22496047757, 55020807236, 134631987776, 329579227722, 807142635031
Offset: 1

Views

Author

Petros Hadjicostas, Dec 30 2018

Keywords

Comments

The sequence (A032173(n): n >= 1) shifts two places to the left under Bower's "CHK" (necklace, identity, unlabeled) transform. The current sequence satisfies A032173(n+2) = (1/n)*Sum_{d|n} mu(d)*a(n/d).

Crossrefs

Programs

  • Mathematica
    (* b = A032173 *) b[1] = b[2] = 1; c[1] = 1; c[2] = 3;
    b[n_] := b[n] = 1/(n-2) Sum[MoebiusMu[(n-2)/d] c[d], {d, Divisors[n-2]}];
    c[n_] := c[n] = n b[n] + Sum[c[s] b[n-s], {s, 1, n-1}];
    a[n_] := Sum[d b[d+2], {d, Divisors[n]}];
    Array[a, 26] (* Jean-François Alcover, Jan 02 2019 *)
  • PARI
    CHK(p, n)={sum(d=1, n, moebius(d)/d*log(subst(1/(1+O(x*x^(n\d))-p), x, x^d)))}
    seq(n)={my(p=1+O(x)); for(i=1, n\2, p=1+x+x*CHK(x*p, 2*i)); Vec(deriv(x*p)/(1-x*p)+O(x^n))} \\ Andrew Howroyd, Apr 27 2020

Formula

a(n) = Sum_{d|n} d*A032173(d+2).
a(n) = n*A032173(n) + Sum_{s=1..n-1} a(s)*A032173(n-s).
G.f.: If A(x) = Sum_{n>=1} a(n)*x^n and B(x) = Sum_{n>=1} A032173(n)*x^n, then A(x) = x*(dB(x)/dx)/(1-B(x)), while (B(x) - x - x^2)/x^2 = Sum_{n>=1} A032173(n+2)*x^n = -Sum_{n>=1} (mu(n)/n)*log(1-B(x^n)).

Extensions

Terms a(27) and beyond from Andrew Howroyd, Apr 27 2020
Showing 1-8 of 8 results.