A060243 Duplicate of A054225.
1, 1, 1, 2, 2, 2, 3, 4, 4, 3, 5, 7, 9, 7, 5, 7, 12, 16, 16, 12, 7, 11, 19, 29, 31, 29, 19, 11
Offset: 0
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.
Table A054225 begins 1 1...1 2...2...2 3...4...4...3 5...7...9...7...5 7..12..16..16..12..7 The diagonals in the new table begin 1..1..2..3..5...7...11...15...22...30..42 A000041 .....2..4..7..12...19...30...45...67..97 A000070 ........9.16..29...47...77..118..181 ..........31..57...97..162..257 .............109..189..323 ..................339
a(5) = 7 because there are seven partitions of 5, namely: {1, 1, 1, 1, 1}, {2, 1, 1, 1}, {2, 2, 1}, {3, 1, 1}, {3, 2}, {4, 1}, {5}. - _Bob Selcoe_, Jul 08 2014 G.f. = 1 + x + 2*x^2 + 3*x^3 + 5*x^4 + 7*x^5 + 11*x^6 + 15*x^7 + 22*x^8 + ... G.f. = 1/q + q^23 + 2*q^47 + 3*q^71 + 5*q^95 + 7*q^119 + 11*q^143 + 15*q^167 + ... From _Gregory L. Simay_, Nov 08 2015: (Start) There are up to a(4)=5 segmented partitions of the partitions of n with exactly 4 parts. They are a(n,4, <4>), a(n,4,<3,1>), a(n,4,<2,2>), a(n,4,<2,1,1>), a(n,4,<1,1,1,1>). The partition 8,8,8,8 is counted in a(32,4,<4>). The partition 9,9,9,5 is counted in a(32,4,<3,1>). The partition 11,11,5,5 is counted in a(32,4,<2,2>). The partition 13,13,5,1 is counted in a(32,4,<2,1,1>). The partition 14,9,6,3 is counted in a(32,4,<1,1,1,1>). a(n odd,4,<2,2>) = 0. a(12, 6, <2,2,2>) = a(6,3,<1,1,1>) = a(6-3,3) = a(3,3) = 1. The lone partition is 3,3,2,2,1,1. (End)
List([1..10],n->Size(OrbitsDomain(SymmetricGroup(IsPermGroup,n),SymmetricGroup(IsPermGroup,n),\^))); # Attila Egri-Nagy, Aug 15 2014
import Data.MemoCombinators (memo2, integral) a000041 n = a000041_list !! n a000041_list = map (p' 1) [0..] where p' = memo2 integral integral p p _ 0 = 1 p k m = if m < k then 0 else p' k (m - k) + p' (k + 1) m -- Reinhard Zumkeller, Nov 03 2015, Nov 04 2013
# DedekindEta is defined in A000594 A000041List(len) = DedekindEta(len, -1) A000041List(50) |> println # Peter Luschny, Mar 09 2018
a:= func< n | NumberOfPartitions(n) >; [ a(n) : n in [0..10]];
A000041 := n -> combinat:-numbpart(n): [seq(A000041(n), n=0..50)]; # Warning: Maple 10 and 11 give incorrect answers in some cases: A110375. spec := [B, {B=Set(Set(Z,card>=1))}, unlabeled ]; [seq(combstruct[count](spec, size=n), n=0..50)]; with(combstruct):ZL0:=[S,{S=Set(Cycle(Z,card>0))}, unlabeled]: seq(count(ZL0,size=n),n=0..45); # Zerinvary Lajos, Sep 24 2007 G:={P=Set(Set(Atom,card>0))}: combstruct[gfsolve](G,labeled,x); seq(combstruct[count]([P,G,unlabeled],size=i),i=0..45); # Zerinvary Lajos, Dec 16 2007 # Using the function EULER from Transforms (see link at the bottom of the page). 1,op(EULER([seq(1,n=1..49)])); # Peter Luschny, Aug 19 2020
Table[ PartitionsP[n], {n, 0, 45}] a[ n_] := SeriesCoefficient[ q^(1/24) / DedekindEta[ Log[q] / (2 Pi I)], {q, 0, n}]; (* Michael Somos, Jul 11 2011 *) a[ n_] := SeriesCoefficient[ 1 / Product[ 1 - x^k, {k, n}], {x, 0, n}]; (* Michael Somos, Jul 11 2011 *) CoefficientList[1/QPochhammer[q] + O[q]^100, q] (* Jean-François Alcover, Nov 25 2015 *) a[0] := 1; a[n_] := a[n] = Block[{k=1, s=0, i=n-1}, While[i >= 0, s=s-(-1)^k (a[i]+a[i-k]); k=k+1; i=i-(3 k-2)]; s]; Map[a, Range[0, 49]] (* Oliver Seipel, Jun 01 2024 after Euler *)
num_partitions(60,list); /* Emanuele Munarini, Feb 24 2014 */
combinat::partitions::count(i) $i=0..54 // Zerinvary Lajos, Apr 16 2007
{a(n) = if( n<0, 0, polcoeff( 1 / eta(x + x * O(x^n)), n))};
/* The Hardy-Ramanujan-Rademacher exact formula in PARI is as follows (this is no longer necessary since it is now built in to the numbpart command): */ Psi(n, q) = local(a, b, c); a=sqrt(2/3)*Pi/q; b=n-1/24; c=sqrt(b); (sqrt(q)/(2*sqrt(2)*b*Pi))*(a*cosh(a*c)-(sinh(a*c)/c)) L(n, q) = if(q==1,1,sum(h=1,q-1,if(gcd(h,q)>1,0,cos((g(h,q)-2*h*n)*Pi/q)))) g(h, q) = if(q<3,0,sum(k=1,q-1,k*(frac(h*k/q)-1/2))) part(n) = round(sum(q=1,max(5,0.5*sqrt(n)),L(n,q)*Psi(n,q))) /* Ralf Stephan, Nov 30 2002, fixed by Vaclav Kotesovec, Apr 09 2018 */
{a(n) = numbpart(n)};
{a(n) = if( n<0, 0, polcoeff( sum( k=1, sqrtint(n), x^k^2 / prod( i=1, k, 1 - x^i, 1 + x * O(x^n))^2, 1), n))};
f(n)= my(v,i,k,s,t);v=vector(n,k,0);v[n]=2;t=0;while(v[1]1,i--;s+=i*(v[i]=(n-s)\i));t++);t \\ Thomas Baruchel, Nov 07 2005
a(n)=if(n<0, 0, polcoeff(exp(sum(k=1, n, x^k/(1-x^k)/k, x*O(x^n))), n)) \\ Joerg Arndt, Apr 16 2010
use ntheory ":all"; my @p = map { partitions($) } 0..100; say "[@p]"; # _Dana Jacobsen, Sep 06 2015
from sympy.functions.combinatorial.numbers import partition print([partition(i) for i in range(101)]) # Joan Ludevid, May 25 2025
#lang racket ; SUM(k,-inf,+inf) (-1)^k p(n-k(3k-1)/2) ; For k outside the range (1-(sqrt(1-24n))/6 to (1+sqrt(1-24n))/6) argument n-k(3k-1)/2 < 0. ; Therefore the loops below are finite. The hash avoids repeated identical computations. (define (p n) ; Nr of partitions of n. (hash-ref h n (λ () (define r (+ (let loop ((k 1) (n (sub1 n)) (s 0)) (if (< n 0) s (loop (add1 k) (- n (* 3 k) 1) (if (odd? k) (+ s (p n)) (- s (p n)))))) (let loop ((k -1) (n (- n 2)) (s 0)) (if (< n 0) s (loop (sub1 k) (+ n (* 3 k) -2) (if (odd? k) (+ s (p n)) (- s (p n)))))))) (hash-set! h n r) r))) (define h (make-hash '((0 . 1)))) ; (for ((k (in-range 0 50))) (printf "~s, " (p k))) runs in a moment. ; Jos Koot, Jun 01 2016
[number_of_partitions(n) for n in range(46)] # Zerinvary Lajos, May 24 2009
@CachedFunction def A000041(n): if n == 0: return 1 S = 0; J = n-1; k = 2 while 0 <= J: T = A000041(J) S = S+T if is_odd(k//2) else S-T J -= k if is_odd(k) else k//2 k += 1 return S [A000041(n) for n in range(50)] # Peter Luschny, Oct 13 2012
# uses[EulerTransform from A166861] a = BinaryRecurrenceSequence(1, 0) b = EulerTransform(a) print([b(n) for n in range(50)]) # Peter Luschny, Nov 11 2020
G.f. = 1 + 2*x + 4*x^2 + 7*x^3 + 12*x^4 + 19*x^5 + 30*x^6 + 45*x^7 + 67*x^8 + ... From _Omar E. Pol_, Oct 25 2012: (Start) For n = 5 consider the partitions of n+1: -------------------------------------- . Number Partitions of 6 of 1's -------------------------------------- 6 .......................... 0 3 + 3 ...................... 0 4 + 2 ...................... 0 2 + 2 + 2 .................. 0 5 + 1 ...................... 1 3 + 2 + 1 .................. 1 4 + 1 + 1 .................. 2 2 + 2 + 1 + 1 .............. 2 3 + 1 + 1 + 1 .............. 3 2 + 1 + 1 + 1 + 1 .......... 4 1 + 1 + 1 + 1 + 1 + 1 ...... 6 ------------------------------------ 35-16 = 19 . The difference between the sum of the first column and the sum of the second column of the set of partitions of 6 is 35 - 16 = 19 and equals the number of 1's in all partitions of 6, so the 6th term of this sequence is a(5) = 19. (End) From _Gus Wiseman_, Oct 26 2018: (Start) With offset 1, the a(1) = 1 through a(6) = 19 partitions of 2*n whose greatest part is > n: (2) (4) (6) (8) (A) (C) (31) (42) (53) (64) (75) (51) (62) (73) (84) (411) (71) (82) (93) (521) (91) (A2) (611) (622) (B1) (5111) (631) (732) (721) (741) (811) (822) (6211) (831) (7111) (921) (61111) (A11) (7221) (7311) (8211) (9111) (72111) (81111) (711111) With offset 1, the a(1) = 1 through a(6) = 19 partitions of 2*n whose number of parts is > n: (11) (211) (2211) (22211) (222211) (2222211) (1111) (3111) (32111) (322111) (3222111) (21111) (41111) (331111) (3321111) (111111) (221111) (421111) (4221111) (311111) (511111) (4311111) (2111111) (2221111) (5211111) (11111111) (3211111) (6111111) (4111111) (22221111) (22111111) (32211111) (31111111) (33111111) (211111111) (42111111) (1111111111) (51111111) (222111111) (321111111) (411111111) (2211111111) (3111111111) (21111111111) (111111111111) (End) From _Joerg Arndt_, Jan 01 2024: (Start) The a(5) = 19 multiset partitions of the multiset {1^5, 2^1} are: 1: {{1, 1, 1, 1, 1, 2}} 2: {{1, 1, 1, 1, 1}, {2}} 3: {{1, 1, 1, 1, 2}, {1}} 4: {{1, 1, 1, 1}, {1, 2}} 5: {{1, 1, 1, 1}, {1}, {2}} 6: {{1, 1, 1, 2}, {1, 1}} 7: {{1, 1, 1, 2}, {1}, {1}} 8: {{1, 1, 1}, {1, 1, 2}} 9: {{1, 1, 1}, {1, 1}, {2}} 10: {{1, 1, 1}, {1, 2}, {1}} 11: {{1, 1, 1}, {1}, {1}, {2}} 12: {{1, 1, 2}, {1, 1}, {1}} 13: {{1, 1, 2}, {1}, {1}, {1}} 14: {{1, 1}, {1, 1}, {1, 2}} 15: {{1, 1}, {1, 1}, {1}, {2}} 16: {{1, 1}, {1, 2}, {1}, {1}} 17: {{1, 1}, {1}, {1}, {1}, {2}} 18: {{1, 2}, {1}, {1}, {1}, {1}} 19: {{1}, {1}, {1}, {1}, {1}, {2}} (End)
List([0..45],n->Sum([0..n],k->NrPartitions(k))); # Muniru A Asiru, Jul 25 2018
a000070 = p a028310_list where p _ 0 = 1 p ks'@(k:ks) m = if m < k then 0 else p ks' (m - k) + p ks m -- Reinhard Zumkeller, Nov 06 2012
with(combinat): a:=n->add(numbpart(j),j=0..n): seq(a(n), n=0..44); # Zerinvary Lajos, Aug 26 2008
CoefficientList[ Series[1/(1 - x)*Product[1/(1 - x^k), {k, 75}], {x, 0, 45}], x] (* Robert G. Wilson v, Jul 13 2004 *) Table[ Count[ Flatten@ IntegerPartitions@ n, 1], {n, 45}] (* Robert G. Wilson v, Aug 06 2008 *) Join[{1}, Accumulate[PartitionsP[Range[50]]]+1] (* _Harvey P. Dale, Mar 12 2013 *) a[ n_] := SeriesCoefficient[ 1 / (1 - x) / QPochhammer[ x], {x, 0, n}]; (* Michael Somos, Nov 09 2013 *) Accumulate[PartitionsP[Range[0,49]]] (* George Beck, Oct 23 2014; typo fixed by Virgile Andreani, Jul 10 2016 *)
{a(n) = if( n<0, 0, polcoeff( 1 / prod(m=1, n, 1 - x^m, 1 + x * O(x^n)) / (1 - x), n))}; /* Michael Somos, Nov 08 2002 */
x='x+O('x^66); Vec(1/((1-x)*eta(x))) /* Joerg Arndt, May 15 2011 */
a(n) = sum(k=0, n, numbpart(k)); \\ Michel Marcus, Sep 16 2016
from itertools import accumulate def A000070iter(n): L = [0]*n; L[0] = 1 def numpart(n): S = 0; J = n-1; k = 2 while 0 <= J: T = L[J] S = S+T if (k//2)%2 else S-T J -= k if (k)%2 else k//2 k += 1 return S for j in range(1, n): L[j] = numpart(j) return accumulate(L) print(list(A000070iter(100))) # Peter Luschny, Aug 30 2019
# Using function A365676Row. Compare also A365675. from itertools import accumulate def A000070List(size: int) -> list[int]: return [sum(accumulate(reversed(A365676Row(n)))) for n in range(size)] print(A000070List(45)) # Peter Luschny, Sep 16 2023
def A000070_list(leng): p = [number_of_partitions(n) for n in range(leng)] return [add(p[:k+1]) for k in range(leng)] A000070_list(45) # Peter Luschny, Sep 15 2014
We represent each summand, k, in a partition of n as k identical objects. Then we color each object. We have no regard for the order of the colored objects. a(3) = 14 because we have: www; wwb; wbb; bbb; ww + w; ww + b; wb + w; wb + b; bb + w; bb + b; w + w + w; w + w + b; w + b + b; b + b + b, where the 2 colors are black b and white w. - _Geoffrey Critzer_, Sep 27 2012 a(3) = 14 because we have: 3; 3'; 3''; 3'''; 2 + 1; 2 + 1'; 2' + 1; 2' + 1'; 2'' + 1; 2'' + 1'; 1 + 1 + 1; 1 + 1 + 1'; 1 + 1' + 1'; 1' + 1' + 1', where a part k of different sorts is given as k, k', k'', etc. - _Joerg Arndt_, Mar 09 2015 From _Alois P. Heinz_, Mar 09 2015: (Start) The a(4) = 33 = 5 + 9 + 6 + 8 + 5 partitions of 4 objects of 2 colors are: 5 partitions for the integer partition of 4 = 1 + 1 + 1 + 1: 01: {{b}, {b}, {b}, {b}} 02: {{b}, {b}, {b}, {w}} 03: {{b}, {b}, {w}, {w}} 04: {{b}, {w}, {w}, {w}} 05: {{w}, {w}, {w}, {w}} 9 partitions for the integer partition of 4 = 1 + 1 + 2: 06: {{b}, {b}, {b,b}} 07: {{b}, {w}, {b,b}} 08: {{w}, {w}, {b,b}} 09: {{b}, {b}, {w,b}} 10: {{b}, {w}, {w,b}} 11: {{w}, {w}, {w,b}} 12: {{b}, {b}, {w,w}} 13: {{b}, {w}, {w,w}} 14: {{w}, {w}, {w,w}} 6 partitions for the integer partition of 4 = 2 + 2: 15: {{b,b}, {b,b}} 16: {{b,b}, {w,b}} 17: {{b,b}, {w,w}} 18: {{w,b}, {w,b}} 19: {{w,b}, {w,w}} 20: {{w,w}, {w,w}} 8 partitions for the integer partition of 4 = 1 + 3: 21: {{b}, {b,b,b}} 22: {{w}, {b,b,b}} 23: {{b}, {w,b,b}} 24: {{w}, {w,b,b}} 25: {{b}, {w,w,b}} 26: {{w}, {w,w,b}} 27: {{b}, {w,w,w}} 28: {{w}, {w,w,w}} 5 partitions for the integer partition of 4 = 4: 29: {{b,b,b,b}} 30: {{w,b,b,b}} 31: {{w,w,b,b}} 32: {{w,w,w,b}} 33: {{w,w,w,w}} Some see number partitions, others see set partitions, ... (End) It is obvious from the example of _Alois P. Heinz_ that a(n) enumerates multi-set partitions of a multi-set of n elements of two kinds. In the case that there is only one kind, this reduces to the usual case of numerical partitions. In the case that all the n elements are distinct, then this reduces to the case of set partitions. - _Michael Somos_, Mar 09 2015 There are a(3) = 14 plane partitions of 6 with trace 3; of 7 with trace 4; of 8 with trace 5; etc. See a formula above with the Stanley Exercise 7.99. - _Wolfdieter Lang_, Mar 09 2015 From _Daniel Forgues_, Mar 09 2015: (Start) The a(3) = 14 = 4 + 6 + 4 partitions of 3 objects of 2 colors are: 4 partitions for the integer partition of 3 = 1 + 1 + 1: 01: {{b}, {b}, {b}} 02: {{b}, {b}, {w}} 03: {{b}, {w}, {w}} 04: {{w}, {w}, {w}} 6 partitions for the integer partition of 3 = 1 + 2: 05: {{b}, {b,b}} 06: {{w}, {b,b}} 07: {{b}, {w,b}} 08: {{w}, {w,b}} 09: {{b}, {w,w}} 10: {{w}, {w,w}} 4 partitions for the integer partition of 3 = 3: 11: {{b,b,b}} 12: {{w,b,b}} 13: {{w,w,b}} 14: {{w,w,w}} The a(2) = 6 = 3 + 3 partitions of 2 objects of 2 colors are: 3 partitions for the integer partition of 2 = 1 + 1: 01: {{b}, {b}} 02: {{b}, {w}} 03: {{w}, {w}} 3 partitions for the integer partition of 2 = 2: 04: {{b,b}} 05: {{w,b}} 06: {{w,w}} The a(1) = 2 partitions of 1 object of 2 colors are: 2 partitions for the integer partition of 1 = 1: 01: {{b}} 02: {{w}} a(0) = 1: the empty partition, since empty sum is 0. Triangle(sort of, since n_th row has p(n) = A000041 terms): 1: 2 2: 3, 3 3: 4, 6, 4 4: 5, 9, 6, 8, 5 5: 6, ?, ?, ?, ?, ?, 6 6: 7, ?, ?, ?, ?, ?, ?, ?, ?, ?, 7 Can we find a recurrence relation? (End)
mul( (1-x^i)^(-i-1),i=1..80); series(%,x,80); seriestolist(%); # second Maple program: with(numtheory): etr:= proc(p) local b; b:=proc(n) option remember; local d,j; if n=0 then 1 else add(add(d*p(d), d=divisors(j)) *b(n-j), j=1..n)/n fi end end: a:=etr(n-> n+1): seq(a(n), n=0..40); # Alois P. Heinz, Sep 08 2008
max = 31; f[x_] = Product[ 1/(1-x^k)^(k+1), {k, 1, max}]; CoefficientList[ Series[ f[x], {x, 0, max}], x] (* Jean-François Alcover, Nov 08 2011, after g.f. *) etr[p_] := Module[{b}, b[n_] := b[n] = Module[{d, j}, If[n==0, 1, Sum[ Sum[ d*p[d], {d, Divisors[j]}]*b[n-j], {j, 1, n}]/n]]; b]; a = etr[#+1&]; Table[a[n], {n, 0, 40}] (* Jean-François Alcover, Nov 23 2015, after Alois P. Heinz *)
a(n)=polcoeff(prod(i=1,n,(1-x^i+x*O(x^n))^-(i+1)),n)
b[n_, k_] := b[n, k] = If[n>k, 0, 1] + If[PrimeQ[n], 0, Sum[If[d>k, 0, b[n/d, d]], {d, DeleteCases[Divisors[n], 1|n]}]]; a[n_] := b[3^6*2^n, 3^6*2^n]; Table[a[n], {n, 0, 40}] (* Jean-François Alcover, Mar 13 2014, after Alois P. Heinz *) nmax = 50; CoefficientList[Series[(11 + 8*x + 6*x^2 - 7*x^4 - 13*x^5 - 19*x^6 - 10*x^7 - 3*x^8 + 7*x^9 + 11*x^10 + 15*x^11 + 6*x^12 - 2*x^14 - 7*x^15 - 4*x^16 - 2*x^17 + 3*x^18 + 2*x^19 - x^20)/((1-x) * (1-x^2) * (1-x^3) * (1-x^4) * (1-x^5) * (1-x^6)) * Product[1/(1 - x^k), {k, 1, nmax}], {x, 0, nmax}], x] (* Vaclav Kotesovec, Feb 01 2016 *)
from sympy import divisors, isprime from functools import cache @cache def T(n, m): # after Indranil Ghosh in A001055 if isprime(n): return 1 if n <= m else 0 s = sum(T(n//d, d) for d in divisors(n)[1:-1] if d <= m) return s + 1 if n <= m else s def a(n): return (lambda x: T(x, x))(2**n * 3**6) print([a(n) for n in range(33)]) # Michael S. Branicky, Nov 30 2021
with(numtheory): b:= proc(n, k) option remember; `if`(n>k, 0, 1) +`if`(isprime(n), 0, add(`if`(d>k, 0, b(n/d, d)), d=divisors(n) minus {1, n})) end: a:= n-> b(6^n$2): seq(a(n), n=0..30); # Alois P. Heinz, Jun 27 2013
max = 26; se = Series[ Sum[ Log[1 - x^(n-k)*y^k], {n, 1, 2max}, {k, 0, n}], {x, 0, 2max}, {y, 0, 2max}]; coes = CoefficientList[ Series[ Exp[-se], {x, 0, 2max}, {y, 0, 2max}], {x, y}]; a[n_] := coes[[n+1, n+1]]; Table[a[n], {n, 0, max} ](* Jean-François Alcover, Dec 06 2011 *)
The second row (n=1) is 1,1 since (1,0) and (0,1) each have a single partition. The third row (n=2) is 1, 2, 1 from (2,0), (1,1) or (1,0)+(0,1), (0,2). In the fourth row, T(1,3)=5 from (1,3), (0,3)+(1,0), (0,2)+(1,1), (0,2)+(0,1)+(1,0), (0,1)+(1,2). The triangle begins: 1; 1, 1; 1, 2, 1; 2, 3, 3, 2; 2, 5, 5, 5, 2; 3, 7, 9, 9, 7, 3; 4, 10, 14, 17, 14, 10, 4; 5, 14, 21, 27, 27, 21, 14, 5; 6, 19, 31, 42, 46, 42, 31, 19, 6; 8, 25, 44, 64, 74, 74, 64, 44, 25, 8; ...
see Zumkeller link.
max = 10; f[x_, y_] := Product[1 + x^n*y^k, {n, 0, max}, {k, 0, max}]/2; se = Series[f[x, y], {x, 0, max}, {y, 0, max}] ; coes = CoefficientList[ se, {x, y}]; t[n_, k_] := coes[[n-k+1, k+1]]; Flatten[ Table[ t[n, k], {n, 0, max}, {k, 0, n}]] (* Jean-François Alcover, Dec 06 2011 *)
a(11) = 9 because 2+2= 4 starting a new array. The arrays begin as follows: 1.....2.....3.....5......7......11.....15.....22 ......2.....4.....7......12.....19.....30.....45 ............5.....11.....21.....38.....64.....105 ..................15.....36.....74.....141....250 .........................52.....135....296....592 ................................203....566....1315 .......................................877....2610 ..............................................4140 ..................9......16.....29.....47.....77 .........................26.....52.....98.....171 ................................92.....198....392 .......................................371....850 ..............................................1663 ................................31.....57.....97 .......................................109....212 ..............................................444 ................................66.....137....269 .......................................249....560 ..............................................1075 ..............................................109 ..............................................300 ..............................................712 which sums to 1.....4....12....47....170....750....3255.....16010
Partitions of (2,1) into distinct positive pairs, T(2,1) = 3: (2,1), (2,0) + (0,1), (1,1) + (1,0); Partitions of (2,2) into distinct positive pairs, T(2,2) = 5: (2,2), (2,1) + (0,1), (2,0) + (0,2), (1,2) + (1,0), (1,1) + (1,0) + (0,1). First ten rows of triangle: 0: 1 1: 1 2 2: 1 3 5 3: 2 5 9 17 4: 2 7 14 27 46 5: 3 10 21 42 74 123 6: 4 14 31 64 116 197 323 7: 5 19 44 93 174 303 506 809 8: 6 25 61 132 254 452 769 1251 1966 9: 8 33 83 185 363 659 1141 1885 3006 4660
-- see link.
nmax = 10; f[x_, y_] := Product[1 + x^n y^k, {n, 0, nmax}, {k, 0, nmax}]/2; se = Series[f[x, y], {x, 0, nmax}, {y, 0, nmax}]; coes = CoefficientList[se, {x, y}]; t[n_ /; n >= 0, k_] /; 0 <= k <= n := coes[[n-k+1, k+1]]; T[n_, k_] := t[n+k, k]; Table[T[n, k], {n, 0, nmax}, {k, 0, n}] // Flatten (* Jean-François Alcover, Nov 08 2021 *)
Comments