A345907 Triangle giving the main antidiagonals of the matrices counting integer compositions by length and alternating sum (A345197).
1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 2, 2, 1, 1, 0, 0, 4, 3, 1, 1, 0, 0, 3, 6, 4, 1, 1, 0, 0, 6, 9, 8, 5, 1, 1, 0, 0, 0, 18, 18, 10, 6, 1, 1, 0, 0, 0, 10, 36, 30, 12, 7, 1, 1, 0, 0, 0, 20, 40, 60, 45, 14, 8, 1, 1, 0, 0, 0, 0, 80, 100, 90, 63, 16, 9, 1, 1
Offset: 0
Examples
Triangle begins: 1 1 1 0 1 1 0 1 1 1 0 2 2 1 1 0 0 4 3 1 1 0 0 3 6 4 1 1 0 0 6 9 8 5 1 1 0 0 0 18 18 10 6 1 1 0 0 0 10 36 30 12 7 1 1 0 0 0 20 40 60 45 14 8 1 1 0 0 0 0 80 100 90 63 16 9 1 1 0 0 0 0 35 200 200 126 84 18 10 1 1 0 0 0 0 70 175 400 350 168 108 20 11 1 1 0 0 0 0 0 350 525 700 560 216 135 22 12 1 1
Crossrefs
Programs
-
Mathematica
ats[y_]:=Sum[(-1)^(i-1)*y[[i]],{i,Length[y]}]; Table[Table[Length[Select[Join@@Permutations/@IntegerPartitions[n,{n-k}],k==(n+ats[#])/2-1&]],{k,0,n-1}],{n,0,15}]
Comments