A182703 Triangle read by rows: T(n,k) = number of occurrences of k in the last section of the set of partitions of n.
1, 1, 1, 2, 0, 1, 3, 2, 0, 1, 5, 1, 1, 0, 1, 7, 4, 2, 1, 0, 1, 11, 3, 2, 1, 1, 0, 1, 15, 8, 3, 3, 1, 1, 0, 1, 22, 7, 6, 2, 2, 1, 1, 0, 1, 30, 15, 6, 5, 3, 2, 1, 1, 0, 1, 42, 15, 10, 5, 4, 2, 2, 1, 1, 0, 1, 56, 27, 14, 10, 5, 5, 2, 2, 1, 1, 0, 1
Offset: 1
Examples
Illustration of three arrangements of the last section of the set of partitions of 7, or more generally the 7th section of the set of partitions of any integer >= 7: . _ _ _ _ _ _ _ . (7) (7) |_ _ _ _ | . (4+3) (4+3) |_ _ _ _|_ | . (5+2) (5+2) |_ _ _ | | . (3+2+2) (3+2+2) |_ _ _|_ _|_ | . (1) (1) | | . (1) (1) | | . (1) (1) | | . (1) (1) | | . (1) (1) | | . (1) (1) | | . (1) (1) | | . (1) (1) | | . (1) (1) | | . (1) (1) | | . (1) (1) |_| . ---------------- . 19,8,5,3,2,1,1 --> Row 7 of triangle A207031. . |/|/|/|/|/|/| . 11,3,2,1,1,0,1 --> Row 7 of this triangle. . Note that the "head" of the last section is formed by the partitions of 7 that do not contain 1 as a part. The "tail" is formed by A000041(7-1) parts of size 1. The number of rows (or zones) is A000041(7) = 15. The last section of the set of partitions of 7 contains eleven 1's, three 2's, two 3's, one 4, one 5, there are no 6's and it contains one 7. So, for k = 1..7, row 7 gives: 11, 3, 2, 1, 1, 0, 1. Triangle begins: 1; 1, 1; 2, 0, 1; 3, 2, 0, 1; 5, 1, 1, 0, 1; 7, 4, 2, 1, 0, 1; 11, 3, 2, 1, 1, 0, 1; 15, 8, 3, 3, 1, 1, 0, 1; 22, 7, 6, 2, 2, 1, 1, 0, 1; 30, 15, 6, 5, 3, 2, 1, 1, 0, 1; 42, 15, 10, 5, 4, 2, 2, 1, 1, 0, 1; 56, 27, 14, 10, 5, 5, 2, 2, 1, 1, 0, 1; ...
Links
Crossrefs
Programs
-
Maple
p:= (f, g)-> zip((x, y)-> x+y, f, g, 0): b:= proc(n,i) option remember; local g; if n=0 then [1] elif n<2 or i<2 then [0] else g:= `if`(i>n, [0], b(n-i, i)); p(p([0$j=2..i, g[1]], b(n, i-1)), g) fi end: h:= proc(n) option remember; `if`(n=0, 1, b(n, n)[1]+h(n-1)) end: T:= proc(n) h(n-1), b(n, n)[2..n][] end: seq(T(n), n=1..20); # Alois P. Heinz, Feb 19 2012
-
Mathematica
p[f_, g_] := Plus @@ PadRight[{f, g}]; b[n_, i_] := b[n, i] = Module[{g}, Which[n == 0, {1}, n<2 || i<2, {0}, True, g = If [i>n, {0}, b[n-i, i]]; p[p[Append[Array[0&, i-1], g[[1]]], b[n, i-1]], g]]]; h[n_] := h[n] = If[n == 0, 1, b[n, n][[1]] + h[n-1]]; t[n_] := {h[n-1], Sequence @@ b[n, n][[2 ;; n]]}; Table[t[n], {n, 1, 20}] // Flatten (* Jean-François Alcover, Jan 16 2014, after Alois P. Heinz's Maple code *) Table[{PartitionsP[n-1]}~Join~Table[Count[Flatten@Cases[IntegerPartitions[n], x_ /; Last[x] != 1], k], {k,2,n}], {n,1,12}] // Flatten (* Robert Price, May 15 2020 *)
Comments