A077227 Triangle of compositions of n into exactly k parts each no more than k.
1, 0, 1, 0, 2, 1, 0, 1, 3, 1, 0, 0, 6, 4, 1, 0, 0, 7, 10, 5, 1, 0, 0, 6, 20, 15, 6, 1, 0, 0, 3, 31, 35, 21, 7, 1, 0, 0, 1, 40, 70, 56, 28, 8, 1, 0, 0, 0, 44, 121, 126, 84, 36, 9, 1, 0, 0, 0, 40, 185, 252, 210, 120, 45, 10, 1, 0, 0, 0, 31, 255, 456, 462, 330, 165, 55, 11, 1, 0, 0, 0, 20
Offset: 1
Examples
T(6,3)=7 since 6 can be written as 1+2+3, 1+3+2, 2+1+3, 2+2+2, 2+3+1, 3+1+2, or 3+2+1. Triangle begins: 1; 0, 1; 0, 2, 1; 0, 1, 3, 1; 0, 0, 6, 4, 1; 0, 0, 7, 10, 5, 1; 0, 0, 6, 20, 15, 6, 1; 0, 0, 3, 31, 35, 21, 7, 1; 0, 0, 1, 40, 70, 56, 28, 8, 1; 0, 0, 0, 44, 121, 126, 84, 36, 9, 1; 0, 0, 0, 40, 185, 252, 210, 120, 45, 10, 1; ... where column sums are k^k (A000312).
Crossrefs
Programs
-
PARI
T(n,k)=polcoeff(((1-x^k)/(1-x +x*O(x^n)))^k,n-k) for(n=1,12,for(k=1,n,print1(T(n,k),", "));print()) \\ Paul D. Hanna, Jan 25 2013
Formula
If n>=k^2, T(n, k) = 0. If k<=n<2k, T(n, k) = C(n-1, k-1).
G.f. of column k is: x^k*(1-x^k)^k/(1-x)^k for k>=1. - Paul D. Hanna, Jan 25 2013