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-10 of 26 results. Next

A047966 a(n) = Sum_{ d divides n } q(d), where q(d) = A000009 = number of partitions of d into distinct parts.

Original entry on oeis.org

1, 2, 3, 4, 4, 8, 6, 10, 11, 15, 13, 25, 19, 29, 33, 42, 39, 62, 55, 81, 84, 103, 105, 153, 146, 185, 203, 253, 257, 344, 341, 432, 463, 552, 594, 747, 761, 920, 1003, 1200, 1261, 1537, 1611, 1921, 2089, 2410, 2591, 3095, 3270, 3815, 4138, 4769, 5121, 5972, 6394, 7367, 7974, 9066, 9793, 11305, 12077, 13736, 14940
Offset: 1

Views

Author

Keywords

Comments

Number of partitions of n such that every part occurs with the same multiplicity. - Vladeta Jovovic, Oct 22 2004
Christopher and Christober call such partitions uniform. - Gus Wiseman, Apr 16 2018
Equals inverse Mobius transform (A051731) * A000009, where the latter begins (1, 1, 2, 2, 3, 4, 5, 6, 8, ...). - Gary W. Adamson, Jun 08 2009

Examples

			The a(6) = 8 uniform partitions are (6), (51), (42), (33), (321), (222), (2211), (111111). - _Gus Wiseman_, Apr 16 2018
		

Crossrefs

Programs

  • Maple
    with(numtheory):
    b:= proc(n) option remember; `if`(n=0, 1, add(add(
         `if`(d::odd, d, 0), d=divisors(j))*b(n-j), j=1..n)/n)
        end:
    a:= n-> add(b(d), d=divisors(n)):
    seq(a(n), n=1..100);  # Alois P. Heinz, Jul 11 2016
  • Mathematica
    b[n_] := b[n] = If[n==0, 1, Sum[DivisorSum[j, If[OddQ[#], #, 0]&]*b[n-j], {j, 1, n}]/n]; a[n_] := DivisorSum[n, b]; Table[a[n], {n, 1, 100}] (* Jean-François Alcover, Dec 06 2016 after Alois P. Heinz *)
    Table[DivisorSum[n,PartitionsQ],{n,20}] (* Gus Wiseman, Apr 16 2018 *)
  • PARI
    N = 66; q='q+O('q^N);
    D(q)=eta(q^2)/eta(q); \\ A000009
    Vec( sum(e=1,N,D(q^e)-1) ) \\ Joerg Arndt, Mar 27 2014

Formula

G.f.: Sum_{k>0} (-1+Product_{i>0} (1+z^(k*i))). - Vladeta Jovovic, Jun 22 2003
G.f.: Sum_{k>=1} q(k)*x^k/(1 - x^k), where q() = A000009. - Ilya Gutkovskiy, Jun 20 2018
a(n) ~ exp(Pi*sqrt(n/3)) / (4*3^(1/4)*n^(3/4)). - Vaclav Kotesovec, Aug 27 2018

A301467 Number of enriched r-trees of size n with no empty subtrees.

Original entry on oeis.org

1, 2, 4, 8, 20, 48, 136, 360, 1040, 2944, 8704, 25280, 76320, 226720, 692992, 2096640, 6470016, 19799936, 61713152, 190683520, 598033152, 1863995392, 5879859200, 18438913536, 58464724992, 184356152832, 586898946048, 1859875518464, 5941384080384, 18901502482432
Offset: 1

Views

Author

Gus Wiseman, Mar 21 2018

Keywords

Comments

An enriched r-tree of size n > 0 with no empty subtrees is either a single node of size n, or a finite nonempty sequence of enriched r-trees with no empty subtrees and with weakly decreasing sizes summing to n - 1.

Examples

			The a(4) = 8 enriched r-trees with no empty subtrees: 4, (3), (21), ((2)), (111), ((11)), ((1)1), (((1))).
The a(5) = 20 enriched r-trees with no empty subtrees:
  5,
  (4), ((3)), ((21)), (((2))), ((111)), (((11))), (((1)1)), ((((1)))),
  (31), (22), (2(1)), ((2)1), ((1)2), ((11)1), ((1)(1)), (((1))1),
  (211), ((1)11),
  (1111).
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i) option remember; `if`(n=0, 1, `if`(i<1, 0,
          add(b(n-i*j, i-1)* a(i)^j, j=0..n/i)))
        end:
    a:= n-> `if`(n<2, n, 1+b(n-1$2)):
    seq(a(n), n=1..30);  # Alois P. Heinz, Jun 21 2018
  • Mathematica
    pert[n_]:=pert[n]=If[n===1,1,1+Sum[Times@@pert/@y,{y,IntegerPartitions[n-1]}]];
    Array[pert,30]
    (* Second program: *)
    b[n_, i_] := b[n, i] = If[n == 0, 1, If[i < 1, 0,
         Sum[b[n - i*j, i - 1] a[i]^j, {j, 0, n/i}]]];
    a[n_] := a[n] = If[n < 2, n, 1 + b[n-1, n-1]];
    Array[a, 30] (* Jean-François Alcover, May 09 2021, after Alois P. Heinz *)
  • PARI
    seq(n)={my(v=vector(n)); v[1]=1; for(n=2, n, v[n] = 1 + polcoef(1/prod(k=1, n-1, 1 - v[k]*x^k + O(x^n)), n-1)); v} \\ Andrew Howroyd, Aug 26 2018

Formula

O.g.f.: x^2/(1 - x) + x Product_{i > 0} 1/(1 - a(i) x^i).

A301480 Number of rooted twice-partitions of n.

Original entry on oeis.org

1, 1, 2, 4, 8, 15, 30, 54, 103, 186, 345, 606, 1115, 1936, 3466, 6046, 10630, 18257, 31927, 54393, 93894, 159631, 272155, 458891, 779375, 1305801, 2196009, 3667242, 6130066, 10170745, 16923127, 27942148, 46211977, 76039205, 125094369, 204952168, 335924597
Offset: 1

Views

Author

Gus Wiseman, Mar 22 2018

Keywords

Comments

A rooted partition of n is an integer partition of n - 1. A rooted twice-partition of n is a choice of a rooted partition of each part in a rooted partition of n.

Examples

			The a(5) = 8 rooted twice-partitions: ((3)), ((21)), ((111)), ((2)()), ((11)()), ((1)(1)), ((1)()()), (()()()()).
The a(6) = 15 rooted twice-partitions:
(4), (31), (22), (211), (1111),
(3)(), (21)(), (111)(), (2)(1), (11)(1),
(2)()(), (11)()(), (1)(1)(),
(1)()()(),
()()()()().
		

Crossrefs

Programs

  • Mathematica
    nn=30;
    ser=x*Product[1/(1-PartitionsP[n-1]x^n),{n,nn}];
    Table[SeriesCoefficient[ser,{x,0,n}],{n,nn}]
  • PARI
    seq(n)={Vec(1/prod(k=1, n-1, 1 - numbpart(k-1)*x^k + O(x^n)))} \\ Andrew Howroyd, Aug 29 2018

Formula

O.g.f.: x * Product_{n > 0} 1/(1 - P(n-1) x^n) where P = A000041.

A300486 Number of relatively prime or monic partitions of n.

Original entry on oeis.org

1, 2, 3, 4, 7, 8, 15, 18, 28, 35, 56, 64, 101, 120, 168, 210, 297, 348, 490, 583, 776, 946, 1255, 1482, 1952, 2335, 2981, 3581, 4565, 5387, 6842, 8119, 10086, 12013, 14863, 17527, 21637, 25525, 31083, 36695, 44583, 52256, 63261, 74171, 88932, 104303, 124754
Offset: 1

Views

Author

Gus Wiseman, Apr 15 2018

Keywords

Comments

A relatively prime or monic partition of n is an integer partition of n that is either of length 1 (monic) or whose parts have no common divisor other than 1 (relatively prime).

Examples

			The a(6) = 8 relatively prime or monic partitions are (6), (51), (411), (321), (3111), (2211), (21111), (111111). Missing from this list are (42), (33), (222).
		

Crossrefs

Programs

  • Mathematica
    Table[Length[Select[IntegerPartitions[n],Or[Length[#]===1,GCD@@#===1]&]],{n,20}]
  • PARI
    a(n)={(n > 1) + sumdiv(n, d, moebius(d)*numbpart(n/d))} \\ Andrew Howroyd, Aug 29 2018

Formula

a(n > 1) = 1 + A000837(n) = 1 + Sum_{d|n} mu(d) * A000041(n/d).

A301706 Number of rooted thrice-partitions of n.

Original entry on oeis.org

1, 1, 2, 4, 9, 19, 43, 91, 201, 422, 918, 1896, 4089, 8376, 17793, 36445, 76446, 155209, 324481, 655426, 1355220, 2741092, 5617505, 11291037, 23086423, 46227338, 93753196, 187754647, 378675055, 754695631, 1518414812, 3016719277, 6037006608, 11984729983
Offset: 1

Views

Author

Gus Wiseman, Mar 25 2018

Keywords

Comments

A rooted partition of n is an integer partition of n - 1. A rooted twice-partition of n is a choice of a rooted partition of each part in a rooted partition of n. A rooted thrice-partition of n is a choice of a rooted twice-partition of each part in a rooted partition of n.

Examples

			The a(5) = 9 rooted thrice-partitions:
((2)), ((11)), ((1)()), (()()()),
((1))(), (()())(), (())(()),
(())()(),
()()()().
The a(6) = 19 rooted thrice-partitions:
((3)), ((21)), ((111)), ((2)()), ((11)()), ((1)(1)), ((1)()()), (()()()()),
((2))(), ((11))(), ((1)())(), (()()())(), ((1))(()), (()())(()),
((1))()(), (()())()(), (())(())(),
(())()()(),
()()()()().
		

Crossrefs

Programs

  • Mathematica
    twire[n_]:=twire[n]=Sum[Times@@PartitionsP/@(ptn-1),{ptn,IntegerPartitions[n-1]}];
    thrire[n_]:=Sum[Times@@twire/@ptn,{ptn,IntegerPartitions[n-1]}];
    Array[thrire,30]

A301595 Number of thrice-partitions of n.

Original entry on oeis.org

1, 1, 4, 10, 34, 80, 254, 604, 1785, 4370, 11986, 29286, 80355, 193137, 505952, 1239348, 3181970, 7686199, 19520906, 46931241, 117334784, 282021070, 693721166, 1659075192, 4063164983, 9651686516, 23347635094, 55405326513, 133021397071, 313842472333, 749299686508
Offset: 0

Views

Author

Gus Wiseman, Mar 24 2018

Keywords

Comments

A thrice-partition of n is a choice of a twice-partition of each part in a partition of n. Thrice-partitions correspond to intervals in the lattice form of the multiorder of integer partitions.

Examples

			The a(3) = 10 thrice-partitions:
  ((3)), ((21)), ((111)), ((2)(1)), ((11)(1)), ((1)(1)(1)),
  ((2))((1)), ((11))((1)), ((1)(1))((1)),
  ((1))((1))((1)).
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, k) option remember; `if`(n=0 or k=0 or i=1,
          1, b(n, i-1, k)+b(i$2, k-1)*b(n-i, min(n-i, i), k))
        end:
    a:= n-> b(n$2, 3):
    seq(a(n), n=0..35);  # Alois P. Heinz, Jan 25 2019
  • Mathematica
    twie[n_]:=Sum[Times@@PartitionsP/@ptn,{ptn,IntegerPartitions[n]}];
    thrie[n_]:=Sum[Times@@twie/@ptn,{ptn,IntegerPartitions[n]}];
    Array[thrie,30]
    (* Second program: *)
    b[n_, i_, k_] := b[n, i, k] = If[n == 0 || k == 0 || i == 1,
         1, b[n, i - 1, k] + b[i, i, k - 1]*b[n - i, Min[n - i, i], k]];
    a[n_] := b[n, n, 3];
    a /@ Range[0, 35] (* Jean-François Alcover, May 19 2021, after Alois P. Heinz *)

Formula

O.g.f.: Product_{n > 0} 1/(1 - A063834(n) x^n).

Extensions

a(0)=1 prepended by Alois P. Heinz, Jan 25 2019

A301470 Signed recurrence over enriched r-trees: a(n) = (-1)^n + Sum_y Product_{i in y} a(y) where the sum is over all integer partitions of n - 1.

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 2, 3, 5, 9, 15, 27, 47, 87, 155, 288, 524, 983, 1813, 3434, 6396, 12174, 22891, 43810, 82925, 159432, 303559, 585966, 1121446, 2171341, 4172932, 8106485, 15635332, 30445899, 58925280, 115014681, 223210718, 436603718, 849480835, 1664740873
Offset: 0

Views

Author

Gus Wiseman, Mar 21 2018

Keywords

Crossrefs

Programs

  • Maple
    b:= proc(n, i) option remember; `if`(n=0, 1,
         `if`(i<1, 0, b(n, i-1)+a(i)*b(n-i, min(n-i, i))))
        end:
    a:= n-> `if`(n<2, 1-n, b(n-2$2)+b(n-1, n-2)):
    seq(a(n), n=0..45);  # Alois P. Heinz, Jun 23 2018
  • Mathematica
    a[n_]:=a[n]=(-1)^n+Sum[Times@@a/@y,{y,IntegerPartitions[n-1]}];
    Array[a,30]
    (* Second program: *)
    b[n_, i_] := b[n, i] = If[n == 0, 1,
         If[i < 1, 0, b[n, i - 1] + a[i] b[n - i, Min[n - i, i]]]];
    a[n_] := If[n < 2, 1 - n, b[n - 2, n - 2] + b[n - 1, n - 2]];
    a /@ Range[0, 45] (* Jean-François Alcover, May 20 2021, after Alois P. Heinz *)

Formula

O.g.f.: 1/(1 + x) + x Product_{i > 0} 1/(1 - a(i) x^i).
a(n) = Sum_t (-1)^w(t) where the sum is over all enriched r-trees of size n and w(t) is the sum of leaves of t.

A301764 Number of ways to choose a constant rooted partition of each part in a constant rooted partition of n such that the flattened sequence is also constant.

Original entry on oeis.org

1, 1, 2, 3, 4, 4, 6, 5, 6, 7, 8, 5, 10, 7, 8, 10, 10, 6, 12, 7, 12, 13, 10, 5, 14, 12, 11, 11, 14, 7, 18, 9, 12, 13, 11, 12, 20, 10, 10, 13, 18, 9, 20, 9, 14, 20, 12, 5, 20, 15, 19, 14, 17, 7, 18, 16, 20, 17, 12, 5, 26, 13, 12, 21, 18, 17, 24, 9, 15, 13, 22, 9
Offset: 1

Views

Author

Gus Wiseman, Mar 26 2018

Keywords

Comments

A rooted partition of n is an integer partition of n - 1.

Examples

			The a(11) = 8 rooted twice-partitions: (9), (333), (111111111), (4)(4), (22)(22), (1111)(1111), (1)(1)(1)(1)(1), ()()()()()()()()()().
		

Crossrefs

Programs

  • Mathematica
    Table[If[n===1,1,DivisorSum[n-1,If[#===1,1,DivisorSigma[0,#-1]]&]],{n,100}]
  • PARI
    a(n)=if(n==1, 1, sumdiv(n-1, d, if(d==1, 1, numdiv(d-1)))) \\ Andrew Howroyd, Aug 26 2018

A302094 Number of relatively prime or monic twice-partitions of n.

Original entry on oeis.org

1, 3, 6, 10, 27, 35, 113, 170, 396, 641, 1649, 2318, 5905, 9112, 18678, 32529, 69094, 106210, 227480, 363433, 705210, 1196190, 2325023, 3724233, 7192245, 11915884, 21857887, 36597843, 67406158, 109594872, 201747847, 333400746, 591125465, 987069077, 1743223350
Offset: 1

Views

Author

Gus Wiseman, Apr 15 2018

Keywords

Comments

A relatively prime or monic partition of n is an integer partition of n that is either of length 1 (monic) or whose parts have no common divisor other than 1 (relatively prime). Then a relatively prime or monic twice-partition of n is a choice of a relatively prime or monic partition of each part in a relatively prime or monic partition of n.

Examples

			The a(4) = 10 relatively prime or monic twice-partitions:
(4), (31), (211), (1111),
(3)(1), (21)(1), (111)(1),
(2)(1)(1), (11)(1)(1),
(1)(1)(1)(1).
		

Crossrefs

Programs

  • Mathematica
    ip[n_]:=ip[n]=Select[IntegerPartitions[n],Or[Length[#]===1,GCD@@#===1]&];
    Table[Sum[Times@@Length/@ip/@ptn,{ptn,ip[n]}],{n,10}]

A302915 Number of relatively prime enriched p-trees of weight n.

Original entry on oeis.org

1, 2, 4, 8, 28, 56, 256, 656, 2480, 6688, 30736, 73984, 366560, 1006720, 3966976, 12738560, 58427648, 148069632, 764473600, 2133585664, 8939502080, 28705390592, 136987259648, 356634376704, 1780025034240, 5455065263104, 23215437079552, 73123382895616
Offset: 1

Views

Author

Gus Wiseman, Apr 15 2018

Keywords

Comments

A relatively prime enriched p-tree of weight n is either a single node of weight n, or a finite sequence of two or more relatively prime enriched p-trees whose weights are weakly decreasing, relatively prime, and sum to n.

Examples

			The a(4) = 8 relatively prime enriched p-trees are 4, (31), ((21)1), (((11)1)1), ((111)1), (211), ((11)11), (1111). Missing from this list are the enriched p-trees ((11)(11)), ((11)2), (2(11)), (22).
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=a[n]=1+Sum[Times@@a/@y,{y,Rest[Select[IntegerPartitions[n],Or[Length[#]===1,GCD@@#===1]&]]}];
    Array[a,20]
Showing 1-10 of 26 results. Next