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.

A358914 Number of twice-partitions of n into distinct strict partitions.

Original entry on oeis.org

1, 1, 1, 3, 4, 7, 13, 20, 32, 51, 83, 130, 206, 320, 496, 759, 1171, 1786, 2714, 4104, 6193, 9286, 13920, 20737, 30865, 45721, 67632, 99683, 146604, 214865, 314782, 459136, 668867, 972425, 1410458, 2040894, 2950839, 4253713, 6123836, 8801349, 12627079
Offset: 0

Views

Author

Gus Wiseman, Dec 11 2022

Keywords

Comments

A twice-partition of n (A063834) is a sequence of integer partitions, one of each part of an integer partition of n.

Examples

			The a(1) = 1 through a(6) = 13 twice-partitions:
  ((1))  ((2))  ((3))     ((4))      ((5))      ((6))
                ((21))    ((31))     ((32))     ((42))
                ((2)(1))  ((3)(1))   ((41))     ((51))
                          ((21)(1))  ((3)(2))   ((321))
                                     ((4)(1))   ((4)(2))
                                     ((21)(2))  ((5)(1))
                                     ((31)(1))  ((21)(3))
                                                ((31)(2))
                                                ((3)(21))
                                                ((32)(1))
                                                ((41)(1))
                                                ((3)(2)(1))
                                                ((21)(2)(1))
		

Crossrefs

The unordered version is A050342, non-strict A261049.
This is the distinct case of A270995.
The case of strictly decreasing sums is A279785.
The case of constant sums is A279791.
For distinct instead of weakly decreasing sums we have A336343.
This is the twice-partition case of A358913.
A001970 counts multiset partitions of integer partitions.
A055887 counts sequences of partitions.
A063834 counts twice-partitions.
A330462 counts set systems by total sum and length.
A358830 counts twice-partitions with distinct lengths.

Programs

  • Mathematica
    twiptn[n_]:=Join@@Table[Tuples[IntegerPartitions/@ptn],{ptn,IntegerPartitions[n]}];
    Table[Length[Select[twiptn[n],UnsameQ@@#&&And@@UnsameQ@@@#&]],{n,0,10}]
  • PARI
    seq(n,k)={my(u=Vec(eta(x^2 + O(x*x^n))/eta(x + O(x*x^n))-1)); Vec(prod(k=1, n, my(c=u[k]); sum(j=0, min(c,n\k), x^(j*k)*c!/(c-j)!,  O(x*x^n))))} \\ Andrew Howroyd, Dec 31 2022

Extensions

Terms a(26) and beyond from Andrew Howroyd, Dec 31 2022

A098407 Number of different hierarchical orderings that can be formed from n unlabeled elements with no repetition of subhierarchies.

Original entry on oeis.org

1, 1, 2, 6, 13, 33, 78, 186, 436, 1028, 2394, 5566, 12877, 29689, 68198, 156194, 356599, 811959, 1843956, 4177436, 9442166, 21295934, 47932572, 107677140, 241443980, 540441068, 1207689636, 2694452060, 6002389882, 13351958546, 29659179804, 65794744420, 145768641091
Offset: 0

Views

Author

Thomas Wieder, Sep 07 2004; corrected Sep 09 2004

Keywords

Comments

a(n) is the number of finite sets of compositions with total sum n. The case of constant sums is A358904, cf. A074854. The case of distinct sums is A304961, ordered A336127. The ordered version (sequences of distinct compositions) is A358907. - Gus Wiseman, Dec 12 2022

Examples

			Let a pair of parentheses () indicate a subhierarchy and let square brackets [] denote a set of subhierarchies, that is, a hierarchy (also called a society). Let the ranks be ordered from left to right and separated by a colon; e.g., (2:3) is a subhierarchy with three elements ("individuals") on top and two elements on the bottom rank.
Then the hierarchical ordering for n = 4 is composed of the following sets: [(1:1),(2)]; [(1),(3)]; [(1),(1:1:1)]; [(1),(2:1)]; [(1),(1:2)]; [(4)]; [(2:2)]; [(1:3)]; [(3:1)]; [(1:1:2)]; [(1:2:1)]; [(2:1:1)]; [(1:1:1:1)]; thus a(4) = 13.
For example, the following hierarchy is not allowed: [(1),(1),(1),(1)] because of the repetition of (1).
		

Crossrefs

A034691 counts multisets of compositions, ordered A133494.
A261049 counts sets of partitions, ordered A358906.

Programs

  • Maple
    main := proc(n::integer) local a, ListOfPartitions, NumberOfPartitions, APartition, APart, ASet, MultipliticityOfAPart, ndxprttn, ndxprt, Term, Produkt; with(combinat): with(ListTools): a := 0; ListOfPartitions := partition(n); NumberOfPartitions := nops(ListOfPartitions); for ndxprttn from 1 to NumberOfPartitions do APartition := ListOfPartitions[ndxprttn]; ASet := convert(APartition,set); Produkt := 1; for ndxprt from 1 to nops(ASet) do APart := op(ndxprt,ASet); MultipliticityOfAPart := Occurrences(APart, APartition); Term := 2^(APart-1); Term := binomial(Term,MultipliticityOfAPart); Produkt := Produkt * Term; # End of do-loop *** ndxprt ***. end do; a := a + Produkt; # End of do-loop *** ndxprttn ***. end do; print("n, a(n):",n,a); end proc;
    PartitionList := proc (n, k) # Authors: # Herbert S. Wilf and Joanna Nordlicht, # Source: # Lecture Notes "East Side West Side,..." # University of Pennsylvania, USA, 2002. # Available from http://www.cis.upenn.edu/~wilf/lecnotes.html # Berechnet die Partitionen von n mit k Summanden. local East, West; if n < 1 or k < 1 or n < k then RETURN([]) elif n = 1 then RETURN([[1]]) else if n < 2 or k < 2 or n < k then West := [] else West := map(proc (x) options operator, arrow; [op(x), 1] end proc, PartitionList(n-1, k-1)) end if; if k <= n-k then East := map(proc(y) options operator, arrow; map(proc (x) options operator, arrow; x+1 end proc, y) end proc, PartitionList(n-k, k)) else East := [] end if; RETURN([op(West), op(East)]) end if end proc;
    # second Maple program:
    series(exp(add((-1)^(j-1)/j*z^j/(1-2*z^j), j=1..40)), z, 40); # Cf. A102866; Vladeta Jovovic, Feb 19 2008
    # alternative Maple program:
    b:= proc(n, i) option remember; `if`(n=0 or i=1, `if`(n>1, 0, 1),
          add(b(n-i*j, i-1)*binomial(2^(i-1), j), j=0..n/i))
        end:
    a:= n-> b(n$2):
    seq(a(n), n=0..32);  # Alois P. Heinz, May 22 2018
  • Mathematica
    terms = 32; CoefficientList[Product[(1 + x^k)^(2^(k-1)), {k, 1, terms+1}] + O[x]^(terms+1), x] // Rest (* Jean-François Alcover, Nov 10 2017, after Vladeta Jovovic *)
    nmax = 40; CoefficientList[Series[Exp[Sum[-(-1)^k*x^k/(k*(1 - 2 x^k)), {k, 1, nmax}]], {x, 0, nmax}], x] (* Vaclav Kotesovec, Jun 08 2018 *)

Formula

a(n) = Sum_{ partitions n = s_1 + ... + s_n } Product_{ Set{s_i} } C(2^(s_i - 1), m(s_i)), where the sum runs over all partitions of n, the product runs over the set of parts of a given partition, s_i is the i-th part in the set of parts, C(k, l) denotes the binomial coefficient and m(s_i) is the multiplicity of part s_i in the given partition.
G.f.: Product_{k>=1} (1+x^k)^(2^(k-1)). - Vladeta Jovovic, Feb 19 2008
a(n) ~ 2^n * exp(sqrt(2*n) - 1/4 + c) / (sqrt(2*Pi) * 2^(3/4) * n^(3/4)), where c = Sum_{k>=2} -(-1)^k / (k*(2^k-2)) = -0.207530918644117743551169251314627032059... - Vaclav Kotesovec, Jun 08 2018
Weigh transform of A011782. - Alois P. Heinz, Jun 25 2018

Extensions

More terms from Alois P. Heinz, Apr 21 2012
a(0)=1 prepended by Alois P. Heinz, May 22 2018

A358908 Number of finite sequences of distinct integer partitions with total sum n and weakly decreasing lengths.

Original entry on oeis.org

1, 1, 2, 6, 10, 23, 50, 95, 188, 378, 747, 1414, 2739, 5179, 9811, 18562, 34491, 64131, 118607, 218369, 400196, 731414, 1328069, 2406363, 4346152, 7819549, 14027500, 25090582, 44749372, 79586074, 141214698, 249882141, 441176493, 777107137, 1365801088, 2395427040, 4192702241
Offset: 0

Views

Author

Gus Wiseman, Dec 09 2022

Keywords

Examples

			The a(1) = 1 through a(4) = 10 sequences:
  ((1))  ((2))   ((3))      ((4))
         ((11))  ((21))     ((22))
                 ((111))    ((31))
                 ((1)(2))   ((211))
                 ((2)(1))   ((1111))
                 ((11)(1))  ((1)(3))
                            ((3)(1))
                            ((11)(2))
                            ((21)(1))
                            ((111)(1))
		

Crossrefs

This is the distinct case of A055887 with weakly decreasing lengths.
This is the distinct case is A141199.
The case of distinct lengths also is A358836.
This is the case of A358906 with weakly decreasing lengths.
A000041 counts integer partitions, strict A000009.
A001970 counts multiset partitions of integer partitions.
A063834 counts twice-partitions.
A358830 counts twice-partitions with distinct lengths.
A358901 counts partitions with all distinct Omegas.
A358912 counts sequences of partitions with distinct lengths.
A358914 counts twice-partitions into distinct strict partitions.

Programs

  • Mathematica
    ptnseq[n_]:=Join@@Table[Tuples[IntegerPartitions/@comp],{comp,Join@@Permutations/@IntegerPartitions[n]}];
    Table[Length[Select[ptnseq[n],UnsameQ@@#&&GreaterEqual@@Length/@#&]],{n,0,10}]
  • PARI
    P(n,y) = {1/prod(k=1, n, 1 - y*x^k + O(x*x^n))}
    R(n,v) = {[subst(serlaplace(p), y, 1) | p<-Vec(prod(k=1, #v, (1 + y*x^k + O(x*x^n))^v[k] ))]}
    seq(n) = {my(g=P(n,y)); Vec(prod(k=1, n, Ser(R(n, Vec(polcoef(g, k, y), -n)))  ))} \\ Andrew Howroyd, Dec 31 2022

Extensions

Terms a(16) and beyond from Andrew Howroyd, Dec 31 2022

A358906 Number of finite sequences of distinct integer partitions with total sum n.

Original entry on oeis.org

1, 1, 2, 7, 13, 35, 87, 191, 470, 1080, 2532, 5778, 13569, 30715, 69583, 160386, 360709, 814597, 1824055, 4102430, 9158405, 20378692, 45215496, 100055269, 221388993, 486872610, 1069846372, 2343798452, 5127889666, 11186214519, 24351106180, 52896439646
Offset: 0

Views

Author

Gus Wiseman, Dec 07 2022

Keywords

Examples

			The a(1) = 1 through a(4) = 13 sequences:
  ((1))  ((2))   ((3))      ((4))
         ((11))  ((21))     ((22))
                 ((111))    ((31))
                 ((1)(2))   ((211))
                 ((2)(1))   ((1111))
                 ((1)(11))  ((1)(3))
                 ((11)(1))  ((3)(1))
                            ((11)(2))
                            ((1)(21))
                            ((2)(11))
                            ((21)(1))
                            ((1)(111))
                            ((111)(1))
		

Crossrefs

This is the case of A055887 with distinct partitions.
The unordered version is A261049.
The case of twice-partitions is A296122.
The case of distinct sums is A336342, constant sums A279787.
The version for sequences of compositions is A358907.
The case of weakly decreasing lengths is A358908.
The case of distinct lengths is A358912.
The version for strict partitions is A358913, distinct case of A304969.
A001970 counts multiset partitions of integer partitions.
A063834 counts twice-partitions.
A358830 counts twice-partitions with distinct lengths.
A358901 counts partitions with all distinct Omegas.

Programs

  • Maple
    b:= proc(n, i, p) option remember; `if`(n=0, p!, `if`(i<1, 0, add(
          binomial(combinat[numbpart](i), j)*b(n-i*j, i-1, p+j), j=0..n/i)))
        end:
    a:= n-> b(n$2, 0):
    seq(a(n), n=0..32);  # Alois P. Heinz, Feb 13 2024
  • Mathematica
    ptnseq[n_]:=Join@@Table[Tuples[IntegerPartitions/@comp],{comp,Join@@Permutations/@IntegerPartitions[n]}];
    Table[Length[Select[ptnseq[n],UnsameQ@@#&]],{n,0,10}]

Formula

a(n) = Sum_{k} A330463(n,k) * k!.

A358904 Number of finite sets of compositions with all equal sums and total sum n.

Original entry on oeis.org

1, 1, 2, 4, 9, 16, 38, 64, 156, 260, 632, 1024, 2601, 4096, 10208, 16944, 40966, 65536, 168672, 262144, 656980, 1090240, 2620928, 4194304, 10862100, 16781584, 41940992, 69872384, 168403448, 268435456, 693528552, 1073741824, 2695006177, 4473400320, 10737385472
Offset: 0

Views

Author

Gus Wiseman, Dec 13 2022

Keywords

Examples

			The a(1) = 1 through a(4) = 9 sets:
  {(1)}  {(2)}   {(3)}    {(4)}
         {(11)}  {(12)}   {(13)}
                 {(21)}   {(22)}
                 {(111)}  {(31)}
                          {(112)}
                          {(121)}
                          {(211)}
                          {(1111)}
                          {(2),(11)}
		

Crossrefs

This is the constant-sum case of A098407, ordered A358907.
The version for distinct sums is A304961, ordered A336127.
Allowing repetition gives A305552, ordered A074854.
The case of sets of partitions is A359041.
A001970 counts multisets of partitions.
A034691 counts multisets of compositions, ordered A133494.
A261049 counts sets of partitions, ordered A358906.

Programs

  • Mathematica
    Table[If[n==0,1,Sum[Binomial[2^(d-1),n/d],{d,Divisors[n]}]],{n,0,30}]
  • PARI
    a(n) = if (n, sumdiv(n, d, binomial(2^(d-1), n/d)), 1); \\ Michel Marcus, Dec 14 2022

Formula

a(n>0) = Sum_{d|n} binomial(2^(d-1),n/d).

A358913 Number of finite sequences of distinct sets with total sum n.

Original entry on oeis.org

1, 1, 1, 4, 6, 11, 28, 45, 86, 172, 344, 608, 1135, 2206, 4006, 7689, 13748, 25502, 47406, 86838, 157560, 286642, 522089, 941356, 1718622, 3079218, 5525805, 9902996, 17788396, 31742616, 56694704, 100720516, 178468026, 317019140, 560079704, 991061957
Offset: 0

Views

Author

Gus Wiseman, Dec 11 2022

Keywords

Examples

			The a(1) = 1 through a(5) = 11 sequences of sets:
  ({1})  ({2})  ({3})      ({4})        ({5})
                ({1,2})    ({1,3})      ({1,4})
                ({1},{2})  ({1},{3})    ({2,3})
                ({2},{1})  ({3},{1})    ({1},{4})
                           ({1},{1,2})  ({2},{3})
                           ({1,2},{1})  ({3},{2})
                                        ({4},{1})
                                        ({1},{1,3})
                                        ({1,2},{2})
                                        ({1,3},{1})
                                        ({2},{1,2})
		

Crossrefs

The unordered version is A050342, non-strict A261049.
The case of strictly decreasing sums is A279785.
This is the distinct case of A304969.
The case of distinct sums is A336343, constant sums A279791.
This is the case of A358906 with strict partitions.
The version for compositions instead of strict partitions is A358907.
The case of twice-partitions is A358914.
A001970 counts multiset partitions of integer partitions.
A055887 counts sequences of partitions.
A063834 counts twice-partitions.
A330462 counts set systems by total sum and length.
A358830 counts twice-partitions with distinct lengths.

Programs

  • Maple
    g:= proc(n) option remember; `if`(n=0, 1, add(g(n-j)*add(
         `if`(d::odd, d, 0), d=numtheory[divisors](j)), j=1..n)/n)
        end:
    b:= proc(n, i, p) option remember; `if`(n=0, p!, `if`(i<1, 0,
          add(binomial(g(i), j)*b(n-i*j, i-1, p+j), j=0..n/i)))
        end:
    a:= n-> b(n$2, 0):
    seq(a(n), n=0..35);  # Alois P. Heinz, Feb 13 2024
  • Mathematica
    ptnseq[n_]:=Join@@Table[Tuples[IntegerPartitions/@comp],{comp,Join@@Permutations/@IntegerPartitions[n]}];
    Table[Length[Select[ptnseq[n],UnsameQ@@#&&And@@UnsameQ@@@#&]],{n,0,10}]

Formula

a(n) = Sum_{k} A330462(n,k) * k!.

A359041 Number of finite sets of integer partitions with all equal sums and total sum n.

Original entry on oeis.org

1, 1, 2, 3, 6, 7, 14, 15, 32, 31, 63, 56, 142, 101, 240, 211, 467, 297, 985, 490, 1524, 1247, 2542, 1255, 6371, 1979, 7486, 7070, 14128, 4565, 32953, 6842, 42229, 37863, 56266, 17887, 192914, 21637, 145820, 197835, 371853, 44583, 772740, 63261, 943966, 1124840
Offset: 0

Views

Author

Gus Wiseman, Dec 14 2022

Keywords

Examples

			The a(1) = 1 through a(6) = 14 sets:
  {(1)}  {(2)}   {(3)}    {(4)}       {(5)}      {(6)}
         {(11)}  {(21)}   {(22)}      {(32)}     {(33)}
                 {(111)}  {(31)}      {(41)}     {(42)}
                          {(211)}     {(221)}    {(51)}
                          {(1111)}    {(311)}    {(222)}
                          {(2),(11)}  {(2111)}   {(321)}
                                      {(11111)}  {(411)}
                                                 {(2211)}
                                                 {(3111)}
                                                 {(21111)}
                                                 {(111111)}
                                                 {(3),(21)}
                                                 {(3),(111)}
                                                 {(21),(111)}
		

Crossrefs

This is the constant-sum case of A261049, ordered A358906.
The version for all different sums is A271619, ordered A336342.
Allowing repetition gives A305551, ordered A279787.
The version for compositions instead of partitions is A358904.
A001970 counts multisets of partitions.
A034691 counts multisets of compositions, ordered A133494.
A098407 counts sets of compositions, ordered A358907.

Programs

  • Mathematica
    Table[If[n==0,1,Sum[Binomial[PartitionsP[d],n/d],{d,Divisors[n]}]],{n,0,50}]
  • PARI
    a(n) = if (n, sumdiv(n, d, binomial(numbpart(d), n/d)), 1); \\ Michel Marcus, Dec 14 2022

Formula

a(n) = Sum_{d|n} binomial(A000041(d),n/d).
Showing 1-7 of 7 results.