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.

A360451 Triangle read by rows: T(n,k) = number of partitions of an n X k rectangle into one or more integer-sided rectangles, 1 <= k <= n = 1, 2, 3, ...

This page as a plain text file.
%I A360451 #50 May 12 2025 10:14:09
%S A360451 1,2,6,3,14,50,5,34,179,892,7,72,548,3765,21225,11,157,1651,14961,
%T A360451 108798,700212,15,311,4485,53196,491235,3903733
%N A360451 Triangle read by rows: T(n,k) = number of partitions of an n X k rectangle into one or more integer-sided rectangles, 1 <= k <= n = 1, 2, 3, ...
%C A360451 Partitions are considered as ordered lists or multisets of rectangles or pairs (height, width). They are not counted with multiplicity in case there are different "arrangements" of the rectangles yielding the same "big" rectangle.
%C A360451 For example, for (n,k) = (3,1) (rectangle of height 3 and width 1) we have the A000041(3) = 3 partitions [(3,1)] and [(2,1), (1,1)] (2 X 1 rectangle above a 1 X 1 square) and [(1,1), (1,1), (1,1)]. The partition [(1,1), (2,1)] (1 X 1 square above the 2 X 1 rectangle) does not count as distinct.
%F A360451 T(n,1) = A000041(n), the partition numbers.
%e A360451 Triangle begins:
%e A360451   n\k|  1   2    3     4      5       6  7
%e A360451   ---+------------------------------------
%e A360451   1  |  1
%e A360451   2  |  2   6
%e A360451   3  |  3  14   50
%e A360451   4  |  5  34  179   892
%e A360451   5  |  7  72  548  3765  21225
%e A360451   6  | 11 157 1651 14961 108798  700212
%e A360451   7  | 15 311 4485 53196 491235 3903733  ?
%e A360451 For n = k = 2, we have the following six partitions of the 2 X 2 square:
%e A360451   { [ (2,2) ], [ (2,1), (2,1) ], [ (2,1), (1,1), (1,1) ], [ (1,2), (1,2) ],
%e A360451     [ (1,2), (1,1), (1,1) ], [ (1,1), (1,1), (1,1), (1,1) ] }.
%e A360451 They can be represented graphically as follows:
%e A360451      AA   AB   AB   AA   AA   AB
%e A360451      AA   AB   AC   BB   BC   CD
%e A360451 where in each figure a given letter corresponds to a given rectangular part.
%e A360451 For n = 3, k = 2, we have the fourteen partitions { [(3,2)], [(3,1), (3,1)],
%e A360451   [(3,1), (2,1), (1,1)], [(3,1), (1,1), (1,1), (1,1)], [(2,2), (1,2)],
%e A360451   [(2,2), (1,1), (1,1)], [(2,1), (2,1), (1,2)], [(2,1), (2,1), (1,1), (1,1)],
%e A360451   [(2,1), (1,2), (1,1), (1,1)], [(2,1), (1,1), (1,1), (1,1), (1,1)],
%e A360451   [(1,2), (1,2), (1,2)], [(1,2), (1,1), (1,1), (1,1), (1,1)],
%e A360451   [(1,2), (1,2), (1,1), (1,1)], [(1,1), (1,1), (1,1), (1,1), (1,1), (1,1)] },
%e A360451         AA   AB   AB   AB   AA   AA   AB   AB   AC   AC   AA   AA   AA   AB
%e A360451   i.e.: AA   AB   AB   AC   AA   AA   AB   AB   AD   AD   BB   BB   BC   CD .
%e A360451         AA   AB   AC   AD   BB   BC   CC   CD   BB   BE   CC   CD   DE   EF
%e A360451 For n = k = 3, we have 50 distinct partitions. Only one of them, namely
%e A360451                                                           AAB
%e A360451   [(2,1), (2,1), (1,2), (1,2), (1,1)]  corresponding to:  DEB
%e A360451                                                           DCC
%e A360451   cannot be obtained by repeatedly slicing the full square, and subsequently the resulting smaller rectangles, in two rectangular parts at each step.
%e A360451   Note that the arrangement: ABC
%e A360451                              ABD  which also cannot be obtained in that way,
%e A360451   ABD                        AED  corresponds to the equivalent partition:
%e A360451   ABD , i.e., the multiset [(3,1), (2,1), (2,1), (1,1), (1,1)],
%e A360451   AEC   which can be obtained by subsequent "slicing in two rectangles".
%o A360451 (PARI) A360451(n,k) = if(min(n,k)<3 || n+k<7, #Part(k,n), error("Not yet implemented"))
%o A360451 PartM = Map(); ROT(S) = if(type(S)=="t_INT", [1,10]*divrem(S,10), apply(ROT, S))
%o A360451 Part(a,b) = { if ( mapisdefined(PartM, [a,b]), mapget(PartM, [a,b]),
%o A360451   a == 1, [[10+x | x <- P ] | P <- partitions(b) ],
%o A360451   b == 1, [[x*10+1 | x <- P ] | P <- partitions(a) ],
%o A360451   a > b, ROT(Part(b,a)),  my(S = [[a*10+b]],
%o A360451     U(x,y,a,b, S, B = Part(x,y)) = foreach(Part(a,b), P,
%o A360451       foreach(B, Q, S = setunion([vecsort(concat(P,Q))], S) )); S);
%o A360451   for(x=1,a\2, S = U(x,b, a-x,b, S)); for(x=1,b\2, S = U(a,x, a,b-x, S));
%o A360451   a==3 && S=setunion(S, [[11,12,12,21,21]]);
%o A360451   mapput(PartM, [a,b], S); S)}
%Y A360451 Cf. A000041, A116694, A224697, A360629 (pieces are free to rotate by 90 degrees).
%K A360451 nonn,tabl,more
%O A360451 1,2
%A A360451 _M. F. Hasler_, Feb 09 2023
%E A360451 T(3,3) corrected following a remark by _Pontus von Brömssen_. - _M. F. Hasler_, Feb 10 2023
%E A360451 Last two terms of 4th row, 5th row, and first five terms of 6th row from _Pontus von Brömssen_, Feb 11 2023
%E A360451 Last term of 6th row from _Pontus von Brömssen_, Feb 13 2023
%E A360451 First five terms of 7th row from _Pontus von Brömssen_, Feb 16 2023
%E A360451 T(7,6) added by _Robin Visser_, May 09 2025