OFFSET
0,3
COMMENTS
Also number of matrices with nonnegative integer entries and without zero rows or columns such that sum of all entries is equal to n and the column sums are distinct.
a(2) = 2:
[1] [2]
[1]
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..300
EXAMPLE
a(0) = 1: the empty composition.
a(1) = 1: 1a.
a(2) = 2: 2aa (for k=1), 2ab (for k=2).
MAPLE
b:= proc(n, i, p, k) option remember;
`if`(i*(i+1)/2<n, 0, `if`(n=0, p!, b(n, i-1, p, k)+
`if`(i>n, 0, b(n-i, i-1, p+1, k)*binomial(i+k-1, k-1))))
end:
a:= n-> add(add(b(n$2, 0, k-i)*(-1)^i*binomial(k, i), i=0..k), k=0..n):
seq(a(n), n=0..25);
MATHEMATICA
b[n_, i_, p_, k_] := b[n, i, p, k] = If[i*(i+1)/2 < n, 0, If[n == 0, p!, b[n, i-1, p, k] + If[i>n, 0, b[n-i, i-1, p+1, k]*Binomial[i+k-1, k-1]]]]; a[n_] := Sum[b[n, n, 0, k-i]*(-1)^i*Binomial[k, i], {k, 0, n}, {i, 0, k}]; Table[a[n], {n, 0, 25}] (* Jean-François Alcover, Feb 25 2017, translated from Maple *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Sep 02 2015
STATUS
approved