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.

User: Emily Anible

Emily Anible's wiki page.

Emily Anible has authored 6 sequences.

A316861 a(n) = Sum_{p in P} y(1)*y(2), where P is the set of partitions of n, and y(k) is the number of parts with multiplicity at least k in p.

Original entry on oeis.org

0, 0, 1, 1, 4, 7, 13, 22, 38, 58, 93, 139, 208, 302, 438, 616, 869, 1200, 1650, 2239, 3026, 4038, 5374, 7081, 9292, 12103, 15704, 20236, 25992, 33191, 42237, 53490, 67524, 84860, 106341, 132736, 165212, 204928, 253518, 312629, 384585, 471734, 577276, 704584, 858078
Offset: 0

Author

Emily Anible, Jul 15 2018

Keywords

Comments

Also (1/2)*Sum_{p in P} H(1)*H(2), where P is the set of partitions of n, and H(k) is the number of k-hooks in p.

Examples

			For n=6, we sum over the partitions of 6. For each partition, we count the parts with multiplicity at least one, and those of at least two.
6............y(1)*y(2) = 1*0 = 0
5,1..........y(1)*y(2) = 2*0 = 0
4,2..........y(1)*y(2) = 2*0 = 0
4,1,1........y(1)*y(2) = 2*1 = 2
3,3..........y(1)*y(2) = 1*1 = 1
3,2,1........y(1)*y(2) = 3*0 = 0
3,1,1,1......y(1)*y(2) = 2*1 = 2
2,2,2........y(1)*y(2) = 1*1 = 1
2,2,1,1......y(1)*y(2) = 2*2 = 4
2,1,1,1,1....y(1)*y(2) = 2*1 = 2
1,1,1,1,1,1..y(1)*y(2) = 1*1 = 1
--------------------------------
Total.........................13
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, x, y) option remember;
         `if`(n=0, x*y, `if`(i<1, 0, add(b(n-i*j, i-1,
         `if`(j>0, 1, 0)+x, `if`(j>1, 1, 0)+y), j=0..n/i)))
        end:
    a:= n-> b(n$2, 0$2):
    seq(a(n), n=0..55);  # Alois P. Heinz, Jul 30 2018
  • Mathematica
    Array[Total[
       Count[Split@#, (_?(Length@# >= 1 &))] Count[
           Split@#, (_?(Length@# >= 2 &))] & /@
        IntegerPartitions[#]] &, 50]
    (* Second program: *)
    b[n_, i_, x_, y_] := b[n, i, x, y] = If[n == 0, x*y, If[i < 1, 0, Sum[b[n - i*j, i - 1, If[j > 0, 1, 0] + x, If[j > 1, 1, 0] + y], {j, 0, n/i}]]];
    a[n_] := b[n, n, 0, 0];
    a /@ Range[0, 55] (* Jean-François Alcover, Sep 16 2019, after Alois P. Heinz *)
  • PARI
    seq(n)={Vec(x*(1 + x^2 + x^3)/((1 - x)^2*(1 + x)*(1 + x + x^2)*prod(i=1, n-1, 1 - x^i + O(x^n))) + O(x^n), -n)} \\ Andrew Howroyd, Jul 15 2018

Formula

G.f.: (q^3/((1-q)(1-q^2)) + q^2/(1-q^2) - q^3/(1-q^3))*Product_{j>=1} 1/(1-q^j).
a(n) = A000097(n+3) + A116646(n).
In general, Sum_{n>=0} q^n Sum_{p in P} y(s)*y(t) for s < t is given by (q^(s+t)/((1-q^s)(1-q^t)) + q^t/(1-q^t) - q^(s+t)/(1-q^(s+t))) * Product_{j>=1} 1/(1-q^j).

A304825 Sum of binomial(Y(2,p), 2) over the partitions p of n, where Y(2,p) is the number of part sizes with multiplicity 2 or greater in p.

Original entry on oeis.org

1, 1, 3, 4, 9, 12, 22, 30, 50, 68, 105, 142, 210, 281, 400, 531, 736, 967, 1311, 1707, 2274, 2935, 3851, 4930, 6389, 8116, 10402, 13121, 16658, 20872, 26275, 32719, 40880, 50613, 62807, 77343, 95389, 116874, 143331, 174789, 213251, 258903, 314367, 380079, 459462
Offset: 6

Author

Emily Anible, May 19 2018

Keywords

Examples

			For a(8), we sum over the partitions of eight. For each partition p, we take binomial(Y(2,p),2): that is, the number of parts with multiplicity at least two choose 2.
8................B(0,2) = 0
7,1..............B(0,2) = 0
6,2..............B(0,2) = 0
6,1,1............B(1,2) = 0
5,3..............B(0,2) = 0
5,2,1............B(0,2) = 0
5,1,1,1..........B(1,2) = 0
4,4..............B(1,2) = 0
4,3,1............B(0,2) = 0
4,2,2............B(1,2) = 0
4,2,1,1..........B(1,2) = 0
4,1,1,1,1........B(1,2) = 0
3,3,2............B(1,2) = 0
3,3,1,1..........B(2,2) = 1
3,2,2,1..........B(1,2) = 0
3,2,1,1,1........B(1,2) = 0
3,1,1,1,1,1......B(1,2) = 0
2,2,2,2..........B(1,2) = 0
2,2,2,1,1........B(2,2) = 1
2,2,1,1,1,1......B(2,2) = 1
2,1,1,1,1,1,1....B(1,2) = 0
1,1,1,1,1,1,1,1..B(1,2) = 0
---------------------------
Total.....................3
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, p) option remember; `if`(n=0 or i=1,
          binomial(`if`(n>1, 1, 0)+p, 2), add(
          b(n-i*j, i-1, `if`(j>1, 1, 0)+p), j=0..n/i))
        end:
    a:= n-> b(n$2, 0):
    seq(a(n), n=6..60);  # Alois P. Heinz, May 19 2018
  • Mathematica
    Array[Total[Binomial[Count[Split@#, _?(Length@# >= 2 &)], 2] & /@IntegerPartitions[#]] &, 50]
    (* Second program: *)
    b[n_, i_, p_] := b[n, i, p] = If[n == 0 || i == 1,
         Binomial[If[n > 1, 1, 0] + p, 2], Sum[
         b[n-i*j, i-1, If[j>1, 1, 0]+p], {j, 0, n/i}]];
    a[n_] := b[n, n, 0];
    a /@ Range[6, 60] (* Jean-François Alcover, May 30 2021, after Alois P. Heinz *)

Formula

a(n) = (A301313(n) - A024788(n))/4.
G.f.: q^6 /((1-q^2)*(1-q^4))*Product_{j>=1} 1/(1-q^j).

A302300 a(n) = Sum_{p in P} (Sum_{k_j = 1} 1)^2, where P is the set of partitions of n, and the k_j are the frequencies in p.

Original entry on oeis.org

0, 1, 1, 5, 6, 12, 21, 33, 50, 79, 116, 169, 246, 346, 487, 675, 927, 1254, 1702, 2263, 3014, 3966, 5210, 6766, 8795, 11303, 14531, 18521, 23583, 29803, 37654, 47231, 59206, 73792, 91867, 113778, 140788, 173377, 213289, 261318, 319764, 389846, 474745, 576164
Offset: 0

Author

Emily Anible, Apr 04 2018

Keywords

Comments

This sequence is part of the contribution to the b^2 term of C_{1-b,2}(q) for(1-b,2)-colored partitions - partitions in which we can label parts any of an indeterminate 1-b colors, but are restricted to using only 2 of the colors per part size. This formula is known to match the Han/Nekrasov-Okounkov hooklength formula truncated at hooks of size two up to the linear term in b.
It is of interest to enumerate and determine specific characteristics of partitions of n, considering each partition individually.

Examples

			For a(6), we sum over partitions of six. For each partition, we count 1 for each part which appears once, then square the total in each partition.
   6............1^2 = 1
   5,1..........2^2 = 4
   4,2..........2^2 = 4
   4,1,1........1^2 = 1
   3,3..........0^2 = 0
   3,2,1........3^2 = 9
   3,1,1,1......1^2 = 1
   2,2,2........0^2 = 0
   2,2,1,1......0^2 = 0
   2,1,1,1,1....1^2 = 1
   1,1,1,1,1,1..0^2 = 0
   --------------------
   Total.............21
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, p) option remember; `if`(n=0 or i=1, (
          `if`(n=1, 1, 0)+p)^2, add(b(n-i*j, i-1,
          `if`(j=1, 1, 0)+p), j=0..n/i))
        end:
    a:= n-> b(n$2, 0):
    seq(a(n), n=0..60);  # Alois P. Heinz, Apr 05 2018
  • Mathematica
    Array[Total@ Map[Count[Split@ #, ?(Length@ # == 1 &)]^2 &, IntegerPartitions[#]] &, 43] (* _Michael De Vlieger, Apr 05 2018 *)
    b[n_, i_, p_] := b[n, i, p] = If[n == 0 || i == 1, (
         If[n == 1, 1, 0] + p)^2, Sum[b[n - i*j, i - 1,
         If[j == 1, 1, 0] + p], {j, 0, n/i}]];
    a[n_] := b[n, n, 0];
    a /@ Range[0, 60] (* Jean-François Alcover, Jun 06 2021, after Alois P. Heinz *)
  • Python
    def frequencies(partition, n):
        tot = 0
        freq_list = []
        i = 0
        for p in partition:
            freq = [0 for i in range(n+1)]
            for i in p:
                freq[i] += 1
            for f in freq:
                if f == 0:
                    tot += 1
            freq_list.append(freq)
        return freq_list
    def sum_square_freqs_of_one(freq_part):
        tot = 0
        for f in freq_part:
            count = 0
            for i in f:
                if i == 1:
                    count += 1
            tot += count*count
        return tot
    import sympy.combinatorics
    def A302300(n): # rewritten by R. J. _Mathar, 2023-03-24
        a =0
        if n ==0 :
            return 0
        part = sympy.combinatorics.IntegerPartition([n])
        partlist = []
        while True:
            part = part.next_lex()
            partlist.append(part.partition)
            if len(part.partition) <=1 :
                break
        freq_part = frequencies(partlist, n)
        return sum_square_freqs_of_one(freq_part)
    for n in range(20): print(A302300(n))

Formula

a(n) = Sum_{p in P} (Sum_{k_j = 1} 1)^2, where P is the set of partitions of n, and k_j are the frequencies in p.

A302347 a(n) = Sum of (Y(2,p)^2) over the partitions p of n, Y(2,p) = number of part sizes with multiplicity 2 or greater in p.

Original entry on oeis.org

0, 0, 1, 1, 3, 4, 10, 13, 25, 34, 59, 80, 127, 172, 260, 349, 505, 673, 946, 1248, 1711, 2238, 3010, 3902, 5162, 6637, 8663, 11051, 14253, 18051, 23047, 28988, 36677, 45840, 57538, 71485, 89082, 110062, 136269, 167487, 206138, 252132, 308640, 375777, 457698
Offset: 0

Author

Emily Anible, Apr 05 2018

Keywords

Comments

This sequence is part of the contribution to the b^2 term of C_{1-b,2}(q) for(1-b,2)-colored partitions - partitions in which we can label parts any of an indeterminate 1-b colors, but are restricted to using only 2 of the colors per part size. This formula is known to match the Han/Nekrasov-Okounkov hooklength formula truncated at hooks of size two up to the linear term in b.
It is of interest to enumerate and determine specific characteristics of partitions of n, considering each partition individually.

Examples

			For a(6), we sum over partitions of six. For each partition, we count 1 for each part which appears more than once, then square the total in each partition.
6............0^2 = 0
5,1..........0^2 = 0
4,2..........0^2 = 0
4,1,1........1^2 = 1
3,3..........1^2 = 1
3,2,1........0^2 = 0
3,1,1,1......1^2 = 1
2,2,2........1^2 = 1
2,2,1,1......2^2 = 4
2,1,1,1,1....1^2 = 1
1,1,1,1,1,1..1^2 = 1
--------------------
Total.............10
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, p) option remember; `if`(n=0 or i=1, (
          `if`(n>1, 1, 0)+p)^2, add(b(n-i*j, i-1,
          `if`(j>1, 1, 0)+p), j=0..n/i))
        end:
    a:= n-> b(n$2, 0):
    seq(a(n), n=0..60);  # Alois P. Heinz, Apr 05 2018
  • Mathematica
    Array[Total[Count[Split@ #, ?(Length@ # > 1 &)]^2 & /@ IntegerPartitions[#]] &, 44] (* _Michael De Vlieger, Apr 07 2018 *)
    b[n_, i_, p_] := b[n, i, p] = If[n == 0 || i == 1, (
         If[n > 1, 1, 0] + p)^2, Sum[b[n - i*j, i - 1,
         If[j > 1, 1, 0] + p], {j, 0, n/i}]];
    a[n_] := b[n, n, 0];
    a /@ Range[0, 60] (* Jean-François Alcover, Jun 06 2021, after Alois P. Heinz *)
  • Python
    def sum_square_freqs_greater_one(freq_list):
        tot = 0
        for f in freq_list:
            count = 0
            for i in f:
                if i > 1:
                    count += 1
            tot += count*count
        return tot
    def frequencies(partition, n):
        tot = 0
        freq_list = []
        i = 0
        for p in partition:
            freq = [0 for i in range(n+1)]
            for i in p:
                freq[i] += 1
            for f in freq:
                if f == 0:
                    tot += 1
            freq_list.append(freq)
        return freq_list

Formula

a(n) = Sum_{p in P(n)} (H(2,p)^2 + 2*A024786 - 2*A024788), where P(n) is the set of partitions of n, and H(2,p) is the hooks of length 2 in partition p.
G.f: (q^2*(1+q^4))/((1-q^2)*(1-q^4))*Product_{j>=1} 1/(1-q^j).
a(n) ~ sqrt(3) * exp(Pi*sqrt(2*n/3)) / (8*Pi^2). - Vaclav Kotesovec, May 22 2018

A302348 a(n) = Sum_{p in P} (H(2,p)^2)/2, where P is the set of partitions of n, and H(2,p) is the number of hooks of length 2 in p.

Original entry on oeis.org

0, 0, 1, 1, 4, 5, 14, 18, 37, 50, 90, 122, 199, 270, 415, 559, 820, 1096, 1556, 2060, 2847, 3736, 5057, 6576, 8747, 11279, 14788, 18916, 24493, 31097, 39838, 50225, 63737, 79833, 100471, 125076, 156237, 193394, 239956, 295443, 364334, 446349, 547360, 667440
Offset: 0

Author

Emily Anible, Apr 05 2018

Keywords

Comments

This sequence is part of the contribution to the b^2 term of the Han/Nekrasov-Okounkov hooklength formula truncated at hooks of size two.
It is of interest to enumerate and determine specific characteristics of partitions of n, considering each partition individually.

Examples

			For a(6), we sum over partitions of six. For each partition, we count 1 for each hook of length 2, then square the total in each partition. We divide the final result in half to get a(6).
6............1^2 = 1
5,1..........1^2 = 1
4,2..........2^2 = 4
4,1,1........2^2 = 4
3,3..........2^2 = 4
3,2,1........0^2 = 0
3,1,1,1......2^2 = 4
2,2,2........2^2 = 4
2,2,1,1......2^2 = 4
2,1,1,1,1....1^2 = 1
1,1,1,1,1,1..1^2 = 1
--------------------
Total.............28/2=14
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, p, l) option remember; `if`(n=0, p^2,
          `if`(i>n, 0, b(n, i+1, p, 1)+add(b(n-i*j, i+1, p+
          `if`(j>1, 1, 0)+l, 0), j=1..n/i)))
        end:
    a:= n-> b(n, 1, 0$2)/2:
    seq(a(n), n=0..50);  # Alois P. Heinz, Apr 06 2018
  • Mathematica
    b[n_, i_, p_, l_] := b[n, i, p, l] = If[n == 0, p^2, If[i > n, 0, b[n, i + 1, p, 1] + Sum[b[n - i*j, i+1, p + If[j > 1, 1, 0]+l, 0], {j, 1, n/i}]]];
    a[n_] := b[n, 1, 0, 0]/2;
    Table[a[n], {n, 0, 50}] (* Jean-François Alcover, May 18 2018, after Alois P. Heinz *)

Formula

G.f: (q^2*(1+q^2+2*q^4))/((1-q^2)*(1-q^4)*Product_{i>0} (1-q^i)).

A301313 a(n) = Sum_{p in P} binomial(H(2,p),2), where P is the set of partitions of n, and H(2,p) = number of hooks of size 2 in p.

Original entry on oeis.org

0, 0, 0, 0, 1, 1, 6, 7, 18, 24, 49, 66, 116, 158, 255, 346, 525, 707, 1030, 1374, 1936, 2560, 3519, 4608, 6207, 8056, 10673, 13735, 17942, 22906, 29569, 37469, 47864, 60235, 76249, 95335, 119705, 148770, 185447, 229182, 283810, 348903, 429498, 525411, 643244
Offset: 0

Author

Emily Anible, Apr 03 2018

Keywords

Comments

This sequence is part of the contribution to the quadratic b^2 term of a 2-truncation of the Han/Nekrasov-Okounkov hooklength formula (2-truncation here being the limiting of hook sizes counted by the formula to only those of size 1 or 2). Exploring this sequence may lead to more general formulas regarding the hooklength formula for larger hooks, or the entire contribution to the quadratic term of the formula.

Examples

			For n=6, we sum over the partitions of 6. For each partition, we calculate binomial(number of hooks of size 2 in partition, 2):
6............binomial(1,2) = 0
5,1..........binomial(1,2) = 0
4,2..........binomial(2,2) = 1
4,1,1........binomial(2,2) = 1
3,3..........binomial(2,2) = 1
3,2,1........binomial(0,2) = 0
3,1,1,1......binomial(2,2) = 1
2,2,2........binomial(2,2) = 1
2,2,1,1......binomial(2,2) = 1
2,1,1,1,1....binomial(1,2) = 0
1,1,1,1,1,1..binomial(1,2) = 0
------------------------------
Total........................6
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, p, l) option remember; `if`(n=0, p*(p-1)/2,
          `if`(i>n, 0, b(n, i+1, p, 1)+add(b(n-i*j, i+1, p+
          `if`(j>1, 1, 0)+l, 0), j=1..n/i)))
        end:
    a:= n-> b(n, 1, 0$2):
    seq(a(n), n=0..50);  # Alois P. Heinz, Apr 05 2018
  • Mathematica
    b[n_, i_, p_, l_] := b[n, i, p, l] = If[n == 0, p*(p-1)/2, If[i > n, 0, b[n, i+1, p, 1] + Sum[b[n-i*j, i+1, p+If[j>1, 1, 0]+l, 0], {j, 1, n/i}]] ];
    a[n_] := b[n, 1, 0, 0];
    Table[a[n], {n, 0, 50}] (* Jean-François Alcover, Apr 28 2018, after Alois P. Heinz *)
    Table[Sum[(2*k - 5 - (-1)^(k/2))*(1 + (-1)^k)/4 * PartitionsP[n-k], {k, 1, n}], {n, 0, 60}] (* Vaclav Kotesovec, Oct 06 2018 *)

Formula

G.f.: (q^4+3*q^6)/((1-q^2)*(1-q^4))*Product_{j>=1} 1/(1-q^j). - Emily Anible, May 18 2018
a(n) ~ sqrt(3) * exp(Pi*sqrt((2*n)/3)) / (4*Pi^2). - Vaclav Kotesovec, Oct 06 2018

Extensions

a(10)-a(44) from Alois P. Heinz, Apr 03 2018