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.

Previous Showing 31-36 of 36 results.

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

A320176 Number of series-reduced rooted trees whose leaves are strict integer partitions whose multiset union is a strict integer partition of n.

Original entry on oeis.org

1, 1, 3, 3, 5, 13, 15, 23, 33, 99, 109, 183, 251, 383, 1071, 1261, 2007, 2875, 4291, 5829, 16297, 18563, 30313, 42243, 63707, 85351, 125465, 297843, 356657, 556729, 783637, 1151803, 1564173, 2249885, 2988729, 6803577, 8026109, 12465665, 17124495, 25272841, 33657209
Offset: 1

Views

Author

Gus Wiseman, Oct 07 2018

Keywords

Comments

Also the number of orderless tree-factorizations of Heinz numbers of strict integer partitions of n.
Also the number of phylogenetic trees on a set of distinct labels summing to n.

Examples

			The a(1) = 1 through a(7) = 15 rooted trees:
  (1)  (2)  (3)       (4)       (5)       (6)            (7)
            (21)      (31)      (32)      (42)           (43)
            ((1)(2))  ((1)(3))  (41)      (51)           (52)
                                ((1)(4))  (321)          (61)
                                ((2)(3))  ((1)(5))       (421)
                                          ((2)(4))       ((1)(6))
                                          ((1)(23))      ((2)(5))
                                          ((2)(13))      ((3)(4))
                                          ((3)(12))      ((1)(24))
                                          ((1)(2)(3))    ((2)(14))
                                          ((1)((2)(3)))  ((4)(12))
                                          ((2)((1)(3)))  ((1)(2)(4))
                                          ((3)((1)(2)))  ((1)((2)(4)))
                                                         ((2)((1)(4)))
                                                         ((4)((1)(2)))
		

Crossrefs

Programs

  • Mathematica
    sps[{}]:={{}};sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
    got[m_]:=Prepend[Join@@Table[Union[Sort/@Tuples[got/@p]],{p,Select[sps[m],Length[#]>1&]}],m];
    Table[Length[Join@@Table[got[m],{m,Select[IntegerPartitions[n],UnsameQ@@#&]}]],{n,20}]
  • PARI
    \\ here S(n) is first n terms of A005804.
    EulerT(v)={Vec(exp(x*Ser(dirmul(v,vector(#v,n,1/n))))-1, -#v)}
    b(n,k)={my(v=vector(n)); for(n=1, n, v[n]=binomial(n+k-1, n) + EulerT(v[1..n])[n]); v}
    S(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]))}
    seq(n)={my(u=S((sqrtint(8*n+1)-1)\2)); [sum(i=1, poldegree(p), polcoef(p,i)*u[i]) | p <- Vec(prod(k=1, n, 1 + x^k*y + O(x*x^n))-1)]} \\ Andrew Howroyd, Oct 26 2018

Formula

a(n) = Sum_{k>0} A008289(n, k)*A005804(k). - Andrew Howroyd, Oct 26 2018

Extensions

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

A320293 Number of series-reduced rooted trees whose leaves are integer partitions whose multiset union is an integer partition of n with no 1's.

Original entry on oeis.org

0, 1, 1, 3, 3, 9, 11, 30, 45, 112, 195, 475, 901, 2136, 4349, 10156, 21565, 50003, 109325, 252761, 563785, 1303296, 2948555, 6826494, 15604053, 36210591, 83415487, 194094257, 449813607, 1049555795, 2444027917, 5718195984, 13367881473, 31357008065, 73546933115
Offset: 1

Views

Author

Gus Wiseman, Oct 09 2018

Keywords

Comments

Also phylogenetic trees on integer partitions of n with no 1's.

Examples

			The a(2) = 1 through a(7) = 11 trees:
  (2)  (3)  (4)       (5)       (6)            (7)
            (22)      (32)      (33)           (43)
            ((2)(2))  ((2)(3))  (42)           (52)
                                (222)          (322)
                                ((2)(4))       ((2)(5))
                                ((3)(3))       ((3)(4))
                                ((2)(22))      ((2)(23))
                                ((2)(2)(2))    ((3)(22))
                                ((2)((2)(2)))  ((2)(2)(3))
                                               ((2)((2)(3)))
                                               ((3)((2)(2)))
		

Crossrefs

Programs

  • PARI
    EulerT(v)={Vec(exp(x*Ser(dirmul(v,vector(#v,n,1/n))))-1, -#v)}
    seq(n)={my(p=1/prod(k=2, n, 1 - x^k + O(x*x^n)), v=vector(n)); for(n=1, n, v[n]=polcoef(p, n) + EulerT(v[1..n])[n]); v} \\ Andrew Howroyd, Oct 25 2018

Extensions

Terms a(23) 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

A320266 Number of balanced orderless tree-factorizations of n.

Original entry on oeis.org

1, 1, 1, 2, 1, 2, 1, 3, 2, 2, 1, 4, 1, 2, 2, 6, 1, 4, 1, 4, 2, 2, 1, 8, 2, 2, 3, 4, 1, 5, 1, 9, 2, 2, 2, 11, 1, 2, 2, 8, 1, 5, 1, 4, 4, 2, 1, 17, 2, 4, 2, 4, 1, 8, 2, 8, 2, 2, 1, 13, 1, 2, 4, 19, 2, 5, 1, 4, 2, 5, 1, 24, 1, 2, 4, 4, 2, 5, 1, 17, 6, 2, 1, 13, 2
Offset: 1

Views

Author

Gus Wiseman, Oct 08 2018

Keywords

Comments

A rooted tree is balanced if all leaves are the same distance from the root.
An orderless tree-factorization of n is either (case 1) the number n itself or (case 2) a finite multiset of two or more orderless tree-factorizations, one of each factor in a factorization of n.
a(n) depends only on the prime signature of n. - Andrew Howroyd, Nov 18 2018

Examples

			The a(36) = 11 balanced orderless tree-factorizations:
  36,
  (2*18), (3*12), (4*9), (6*6),
  (2*2*9), (2*3*6), (3*3*4),
  (2*2*3*3), ((2*2)*(3*3)), ((2*3)*(2*3)).
		

Crossrefs

Programs

  • Mathematica
    facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]];
    oltfacs[n_]:=If[n<=1,{{}},Prepend[Union@@Function[q,Sort/@Tuples[oltfacs/@q]]/@DeleteCases[facs[n],{n}],n]];
    Table[Length[Select[oltfacs[n],SameQ@@Length/@Position[#,_Integer]&]],{n,100}]
  • PARI
    MultEulerT(u)={my(v=vector(#u)); v[1]=1; for(k=2, #u, forstep(j=#v\k*k, k, -k, my(i=j, e=0); while(i%k==0, i/=k; e++; v[j]+=binomial(e+u[k]-1, e)*v[i]))); v}
    seq(n)={my(u=vector(n, i, 1), v=vector(n)); while(u, v+=u; u[1]=1; u=MultEulerT(u)-u); v} \\ Andrew Howroyd, Nov 18 2018

Formula

a(p^n) = A320160(n) for prime p. - Andrew Howroyd, Nov 18 2018

A331685 Number of tree-factorizations of Heinz numbers of integer partitions of n.

Original entry on oeis.org

1, 3, 7, 23, 69, 261, 943, 3815, 15107, 63219, 262791, 1130953, 4838813, 21185125, 92593943, 411160627, 1823656199, 8186105099, 36728532951, 166310761655
Offset: 1

Views

Author

Gus Wiseman, Jan 31 2020

Keywords

Comments

A tree-factorization of n > 1 is either (case 1) the number n itself, or (case 2) a sequence of two or more tree-factorizations, one of each part of a weakly increasing factorization of n into factors > 1.
The Heinz number of an integer partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k).

Examples

			The a(1) = 1 through a(4) = 23 tree-factorizations:
  2  3      5          7
     4      6          9
     (2*2)  8          10
            (2*3)      12
            (2*4)      16
            (2*2*2)    (2*5)
            (2*(2*2))  (2*6)
                       (2*8)
                       (3*3)
                       (3*4)
                       (4*4)
                       (2*2*3)
                       (2*2*4)
                       (2*2*2*2)
                       (2*(2*3))
                       ((2*2)*4)
                       (2*(2*4))
                       (3*(2*2))
                       (4*(2*2))
                       (2*(2*2*2))
                       (2*2*(2*2))
                       ((2*2)*(2*2))
                       (2*(2*(2*2)))
		

Crossrefs

The orderless version is A319312.
Factorizations are A001055.
P-trees are A196545.
Twice-factorizations are A281113.
Tree-factorizations are A281118.
Enriched p-trees are A289501.

Programs

  • Mathematica
    facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]];
    physemi[n_]:=Prepend[Join@@Table[Tuples[physemi/@f],{f,Select[facs[n],Length[#]>1&]}],n];
    Table[Sum[Length[physemi[Times@@Prime/@m]],{m,IntegerPartitions[n]}],{n,8}]
  • PARI
    \\ here TF(n) is n terms of A281118 as vector.
    TF(n)={my(v=vector(n), w=vector(n)); w[1]=v[1]=1; for(k=2, n, w[k]=v[k]+1; forstep(j=n\k*k, k, -k, my(i=j, e=0); while(i%k==0, i/=k; e++; v[j] += w[k]^e*v[i]))); w}
    a(n)={my(v=[prod(i=1, #p, prime(p[i])) | p<-partitions(n)], tf=TF(vecmax(v))); sum(i=1, #v, tf[v[i]])} \\ Andrew Howroyd, Dec 09 2020

Formula

a(n) = Sum_i A281118(A215366(n,i)).

Extensions

a(13)-a(20) from Andrew Howroyd, Dec 09 2020
Previous Showing 31-36 of 36 results.