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

A320160 Number of series-reduced balanced rooted trees whose leaves form an integer partition of n.

Original entry on oeis.org

1, 2, 3, 6, 9, 19, 31, 63, 110, 215, 391, 773, 1451, 2879, 5594, 11173, 22041, 44136, 87631, 175155, 348186, 694013, 1378911, 2743955, 5452833, 10853541, 21610732, 43122952, 86192274, 172753293, 347114772, 699602332, 1414033078, 2866580670, 5826842877, 11874508385
Offset: 1

Views

Author

Gus Wiseman, Oct 06 2018

Keywords

Comments

A rooted tree is series-reduced if every non-leaf node has at least two branches, and balanced if all leaves are the same distance from the root.
Also the number of balanced unlabeled phylogenetic rooted trees with n leaves.

Examples

			The a(1) = 1 through a(6) = 19 rooted trees:
  1  2     3      4           5            6
     (11)  (12)   (13)        (14)         (15)
           (111)  (22)        (23)         (24)
                  (112)       (113)        (33)
                  (1111)      (122)        (114)
                  ((11)(11))  (1112)       (123)
                              (11111)      (222)
                              ((11)(12))   (1113)
                              ((11)(111))  (1122)
                                           (11112)
                                           (111111)
                                           ((11)(13))
                                           ((11)(22))
                                           ((12)(12))
                                           ((11)(112))
                                           ((12)(111))
                                           ((11)(1111))
                                           ((111)(111))
                                           ((11)(11)(11))
		

Crossrefs

Programs

  • Mathematica
    sps[{}]:={{}};sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
    mps[set_]:=Union[Sort[Sort/@(#/.x_Integer:>set[[x]])]&/@sps[Range[Length[set]]]];
    phy2[labs_]:=If[Length[labs]==1,labs,Union@@Table[Sort/@Tuples[phy2/@ptn],{ptn,Select[mps[Sort[labs]],Length[#1]>1&]}]];
    Table[Sum[Length[Select[phy2[ptn],SameQ@@Length/@Position[#,_Integer]&]],{ptn,IntegerPartitions[n]}],{n,8}]
  • PARI
    EulerT(v)={Vec(exp(x*Ser(dirmul(v,vector(#v,n,1/n))))-1, -#v)}
    seq(n)={my(u=vector(n, n, 1), v=vector(n)); while(u, v+=u; u=EulerT(u)-u); v} \\ Andrew Howroyd, Oct 25 2018

Extensions

Terms a(14) and beyond from Andrew Howroyd, Oct 25 2018

A320154 Number of series-reduced balanced rooted trees whose leaves form a set partition of {1,...,n}.

Original entry on oeis.org

1, 2, 5, 18, 92, 588, 4328, 35920, 338437, 3654751, 45105744, 625582147, 9539374171, 157031052142, 2757275781918, 51293875591794, 1007329489077804, 20840741773898303, 453654220906310222, 10380640686263467204, 249559854371799622350, 6301679967177242849680
Offset: 1

Views

Author

Gus Wiseman, Oct 06 2018

Keywords

Comments

A rooted tree is series-reduced if every non-leaf node has at least two branches, and balanced if all leaves are the same distance from the root.
Also the number of balanced phylogenetic rooted trees on n distinct labels.

Examples

			The a(1) = 1 through a(4) = 18 rooted trees:
  (1)  (12)      (123)        (1234)
       ((1)(2))  ((1)(23))    ((1)(234))
                 ((2)(13))    ((12)(34))
                 ((3)(12))    ((13)(24))
                 ((1)(2)(3))  ((14)(23))
                              ((2)(134))
                              ((3)(124))
                              ((4)(123))
                              ((1)(2)(34))
                              ((1)(3)(24))
                              ((1)(4)(23))
                              ((2)(3)(14))
                              ((2)(4)(13))
                              ((3)(4)(12))
                              ((1)(2)(3)(4))
                              (((1)(2))((3)(4)))
                              (((1)(3))((2)(4)))
                              (((1)(4))((2)(3)))
		

Crossrefs

Programs

  • Mathematica
    sps[{}]:={{}};sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
    gug[m_]:=Prepend[Join@@Table[Union[Sort/@Tuples[gug/@mtn]],{mtn,Select[sps[m],Length[#]>1&]}],m];
    Table[Length[Select[gug[Range[n]],SameQ@@Length/@Position[#,_Integer]&]],{n,9}]
  • PARI
    EulerT(v)={Vec(exp(x*Ser(dirmul(v,vector(#v,n,1/n))))-1, -#v)}
    b(n,k)={my(u=vector(n), v=vector(n)); u[1]=k; u=EulerT(u); while(u, v+=u; u=EulerT(u)-u); v}
    seq(n)={my(M=Mat(vectorv(n,k,b(n,k)))); vector(n, k, sum(i=1, k, binomial(k,i)*(-1)^(k-i)*M[i,k]))} \\ Andrew Howroyd, Oct 26 2018

Extensions

Terms a(9) and beyond from Andrew Howroyd, Oct 26 2018

A320169 Number of balanced enriched p-trees of weight n.

Original entry on oeis.org

1, 2, 3, 6, 9, 20, 31, 70, 114, 243, 415, 961, 1603, 3564, 6559, 14913, 26630, 60037, 110160, 248859, 458445, 1001190, 1882350, 4220358, 7765303, 16822107, 32307240, 70081784, 133716083, 291788153, 561823990, 1230204229, 2396185727, 5176454708, 10220127290
Offset: 1

Views

Author

Gus Wiseman, Oct 07 2018

Keywords

Comments

An enriched p-tree of weight n is either the number n itself or a finite sequence of enriched p-trees whose weights are weakly decreasing and sum to n.
A tree is balanced if all leaves have the same height.

Examples

			The a(1) = 1 through a(6) = 20 balanced enriched p-trees:
  1  2     3      4           5            6
     (11)  (21)   (22)        (32)         (33)
           (111)  (31)        (41)         (42)
                  (211)       (221)        (51)
                  (1111)      (311)        (222)
                  ((11)(11))  (2111)       (321)
                              (11111)      (411)
                              ((21)(11))   (2211)
                              ((111)(11))  (3111)
                                           (21111)
                                           (111111)
                                           ((21)(21))
                                           ((22)(11))
                                           ((31)(11))
                                           ((111)(21))
                                           ((21)(111))
                                           ((211)(11))
                                           ((111)(111))
                                           ((1111)(11))
                                           ((11)(11)(11))
		

Crossrefs

Programs

  • Mathematica
    eptrs[n_]:=Prepend[Join@@Table[Tuples[eptrs/@p],{p,Rest[IntegerPartitions[n]]}],n];
    Table[Length[Select[eptrs[n],SameQ@@Length/@Position[#,_Integer]&]],{n,12}]
  • PARI
    seq(n)={my(p=x/(1-x) + O(x*x^n), q=0); while(p, q+=p; p = 1/prod(k=1, n, 1 - polcoef(p,k)*x^k + O(x*x^n)) - 1 - p); Vec(q)} \\ Andrew Howroyd, Oct 26 2018

Extensions

Terms a(16) and beyond from Andrew Howroyd, Oct 26 2018

A320179 Regular triangle where T(n,k) is the number of unlabeled series-reduced rooted trees with n leaves in which every leaf is at height k.

Original entry on oeis.org

1, 0, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 1, 0, 0, 0, 1, 3, 0, 0, 0, 0, 1, 3, 0, 0, 0, 0, 0, 1, 6, 1, 0, 0, 0, 0, 0, 1, 7, 1, 0, 0, 0, 0, 0, 0, 1, 11, 4, 0, 0, 0, 0, 0, 0, 0, 1, 13, 6, 0, 0, 0, 0, 0, 0, 0, 0, 1, 20, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 23, 23, 0, 0, 0
Offset: 1

Views

Author

Gus Wiseman, Oct 07 2018

Keywords

Examples

			Triangle begins:
  1
  0  1
  0  1  0
  0  1  1  0
  0  1  1  0  0
  0  1  3  0  0  0
  0  1  3  0  0  0  0
  0  1  6  1  0  0  0  0
  0  1  7  1  0  0  0  0  0
  0  1 11  4  0  0  0  0  0  0
  0  1 13  6  0  0  0  0  0  0  0
  0  1 20 16  0  0  0  0  0  0  0  0
  0  1 23 23  0  0  0  0  0  0  0  0  0
  0  1 33 46  0  0  0  0  0  0  0  0  0  0
The T(10,3) = 4 rooted trees:
   (((oo)(oo))((oo)(oooo)))
   (((oo)(oo))((ooo)(ooo)))
   (((oo)(ooo))((oo)(ooo)))
  (((oo)(oo))((oo)(oo)(oo)))
		

Crossrefs

Row sums are A120803. Third column is A083751. An irregular version is A320221.

Programs

  • Mathematica
    qurt[n_]:=If[n==1,{{}},Join@@Table[Union[Sort/@Tuples[qurt/@ptn]],{ptn,Select[IntegerPartitions[n],Length[#]>1&]}]];
    Table[Length[Select[qurt[n],SameQ[##,k]&@@Length/@Position[#,{}]&]],{n,14},{k,0,n-1}]
  • PARI
    EulerT(v)={Vec(exp(x*Ser(dirmul(v, vector(#v, n, 1/n))))-1, -#v)}
    T(n)={my(u=vector(n), v=vector(n), h=1); u[1]=1; while(u, v+=u*h; h*=x; u=EulerT(u)-u); vector(n, n, Vecrev(v[n], n))}
    { my(A=T(15)); for(n=1, #A, print(A[n])) } \\ Andrew Howroyd, Dec 09 2020

A320173 Number of inequivalent colorings of series-reduced balanced rooted trees with n leaves.

Original entry on oeis.org

1, 2, 3, 12, 23, 84, 204, 830, 2940, 13397, 58794, 283132, 1377302, 7087164, 37654377, 209943842, 1226495407, 7579549767, 49541194089, 341964495985, 2476907459261, 18703210872343, 146284738788714, 1179199861398539, 9760466433602510, 82758834102114911, 717807201648148643
Offset: 1

Views

Author

Gus Wiseman, Oct 07 2018

Keywords

Comments

A rooted tree is series-reduced if every non-leaf node has at least two branches, and balanced if all leaves are the same distance from the root.

Examples

			Inequivalent representatives of the a(1) = 1 through a(5) = 23 colorings:
  1  (11)  (111)    (1111)      (11111)
     (12)  (112)    (1112)      (11112)
           (123)    (1122)      (11122)
                    (1123)      (11123)
                    (1234)      (11223)
                  ((11)(11))    (11234)
                  ((11)(12))    (12345)
                  ((11)(22))  ((11)(111))
                  ((11)(23))  ((11)(112))
                  ((12)(12))  ((11)(122))
                  ((12)(13))  ((11)(123))
                  ((12)(34))  ((11)(223))
                              ((11)(234))
                              ((12)(111))
                              ((12)(112))
                              ((12)(113))
                              ((12)(123))
                              ((12)(134))
                              ((12)(345))
                              ((13)(122))
                              ((22)(111))
                              ((23)(111))
                              ((23)(114))
		

Crossrefs

Programs

  • PARI
    \\ See links in A339645 for combinatorial species functions.
    cycleIndexSeries(n)={my(p=x*sv(1) + O(x*x^n), q=0); while(p, q+=p; p=sEulerT(p)-1-p); q}
    InequivalentColoringsSeq(cycleIndexSeries(15)) \\ Andrew Howroyd, Dec 11 2020

Extensions

Terms a(8) and beyond from Andrew Howroyd, Dec 11 2020

A320172 Number of series-reduced balanced rooted identity trees whose leaves are integer partitions whose multiset union is an integer partition of n.

Original entry on oeis.org

1, 2, 5, 9, 19, 38, 79, 163, 352, 750, 1633, 3558, 7783, 17020, 37338, 81920, 180399, 398600, 885101, 1975638, 4435741, 10013855, 22726109, 51807432, 118545425, 272024659, 625488420, 1440067761, 3317675261, 7644488052, 17610215982, 40547552277, 93298838972, 214516498359, 492844378878
Offset: 1

Views

Author

Gus Wiseman, Oct 07 2018

Keywords

Comments

A rooted tree is series-reduced if every non-leaf node has at least two branches, and balanced if all leaves are the same distance from the root. In an identity tree, all branches directly under any given node are different.

Examples

			The a(1) = 1 through a(5) = 19 rooted identity trees:
  (1)  (2)   (3)        (4)         (5)
       (11)  (21)       (22)        (32)
             (111)      (31)        (41)
             ((1)(2))   (211)       (221)
             ((1)(11))  (1111)      (311)
                        ((1)(3))    (2111)
                        ((1)(21))   (11111)
                        ((2)(11))   ((1)(4))
                        ((1)(111))  ((2)(3))
                                    ((1)(31))
                                    ((1)(22))
                                    ((2)(21))
                                    ((3)(11))
                                    ((1)(211))
                                    ((11)(21))
                                    ((2)(111))
                                    ((1)(1111))
                                    ((11)(111))
                                    ((1)(2)(11))
		

Crossrefs

Programs

  • Mathematica
    sps[{}]:={{}};sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
    mps[set_]:=Union[Sort[Sort/@(#/.x_Integer:>set[[x]])]&/@sps[Range[Length[set]]]];
    gig[m_]:=Prepend[Join@@Table[Union[Sort/@Select[Sort/@Tuples[gig/@mtn],UnsameQ@@#&]],{mtn,Select[mps[m],Length[#]>1&]}],m];
    Table[Sum[Length[Select[gig[y],SameQ@@Length/@Position[#,_Integer]&]],{y,Sort /@IntegerPartitions[n]}],{n,8}]
  • PARI
    WeighT(v)={Vec(exp(x*Ser(dirmul(v, vector(#v,n,(-1)^(n-1)/n))))-1,-#v)}
    seq(n)={my(u=vector(n, n, numbpart(n)), v=vector(n)); while(u, v+=u; u=WeighT(u)-u); v} \\ Andrew Howroyd, Oct 25 2018

Extensions

Terms a(13) and beyond from Andrew Howroyd, Oct 25 2018

A320221 Irregular triangle where T(n,k) is the number of unlabeled series-reduced rooted trees with n leaves in which every leaf is at height k, (n>=1, min(1,n-1) <= k <= log_2(n)).

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 3, 1, 3, 1, 6, 1, 1, 7, 1, 1, 11, 4, 1, 13, 6, 1, 20, 16, 1, 23, 23, 1, 33, 46, 1, 40, 70, 1, 54, 127, 1, 1, 65, 189, 1, 1, 87, 320, 5, 1, 104, 476, 10, 1, 136, 771, 32, 1, 164, 1145, 63, 1, 209, 1795, 154, 1, 252, 2657, 304, 1, 319, 4091, 656
Offset: 1

Views

Author

Gus Wiseman, Oct 07 2018

Keywords

Examples

			Triangle begins:
  1
  1
  1
  1  1
  1  1
  1  3
  1  3
  1  6  1
  1  7  1
  1 11  4
  1 13  6
  1 20 16
  1 23 23
  1 33 46
  1 40 70
The T(11,3) = 6 rooted trees:
   (((oo)(oo))((oo)(ooooo)))
   (((oo)(oo))((ooo)(oooo)))
   (((oo)(ooo))((oo)(oooo)))
   (((oo)(ooo))((ooo)(ooo)))
  (((oo)(oo))((oo)(oo)(ooo)))
  (((oo)(ooo))((oo)(oo)(oo)))
		

Crossrefs

Row sums are A120803. Second column is A083751. A regular version is A320179.

Programs

  • Mathematica
    qurt[n_]:=If[n==1,{{}},Join@@Table[Union[Sort/@Tuples[qurt/@ptn]],{ptn,Select[IntegerPartitions[n],Length[#]>1&]}]];
    DeleteCases[Table[Length[Select[qurt[n],SameQ[##,k]&@@Length/@Position[#,{}]&]],{n,10},{k,0,n-1}],0,{2}]
  • PARI
    EulerT(v)={Vec(exp(x*Ser(dirmul(v, vector(#v, n, 1/n))))-1, -#v)}
    T(n)={my(u=vector(n), v=vector(n), h=1); u[1]=1; while(u, v+=u*h; h*=x; u=EulerT(u)-u); v[1]=x; [Vecrev(p/x) | p<-v]}
    { my(A=T(15)); for(n=1, #A, print(A[n])) } \\ Andrew Howroyd, Dec 09 2020

Extensions

Terms a(36) and beyond from Andrew Howroyd, Dec 09 2020
Name clarified by Andrew Howroyd, Dec 09 2020
Showing 1-7 of 7 results.