%I #30 Jan 12 2015 04:12:46
%S 1,2,0,3,1,0,5,2,1,0,8,5,2,1,0,14,9,6,2,1,0,24,18,12,7,2,1,0,43,33,25,
%T 16,8,2,1,0,77,62,49,35,21,9,2,1,0,140,115,95,73,49,27,10,2,1,0,256,
%U 215,181,148,108,68,34,11,2,1,0,472,401,346,291,230,158,93,42,12,2,1,0,874,753,657,569,470,353,228,125,51,13,2,1,0
%N Triangle T(n,k) read by rows: T(n,k) is the number of compositions of n where the k-th part is the first occurrence of a largest part, n>=1, 1<=k<=n.
%C Column k=1: T(n,1) = A079500(n) = A007059(n+1).
%C Row sums are A011782.
%H Joerg Arndt and Alois P. Heinz, <a href="/A238345/b238345.txt">Rows n = 1..141, flattened</a>
%e Triangle starts:
%e 01: 1;
%e 02: 2, 0;
%e 03: 3, 1, 0;
%e 04: 5, 2, 1, 0;
%e 05: 8, 5, 2, 1, 0;
%e 06: 14, 9, 6, 2, 1, 0;
%e 07: 24, 18, 12, 7, 2, 1, 0;
%e 08: 43, 33, 25, 16, 8, 2, 1, 0;
%e 09: 77, 62, 49, 35, 21, 9, 2, 1, 0;
%e 10: 140, 115, 95, 73, 49, 27, 10, 2, 1, 0;
%e 11: 256, 215, 181, 148, 108, 68, 34, 11, 2, 1, 0;
%e 12: 472, 401, 346, 291, 230, 158, 93, 42, 12, 2, 1, 0;
%e 13: 874, 753, 657, 569, 470, 353, 228, 125, 51, 13, 2, 1, 0;
%e 14: 1628, 1416, 1250, 1102, 943, 753, 533, 324, 165, 61, 14, 2, 1, 0;
%e 15: 3045, 2673, 2380, 2126, 1866, 1558, 1188, 791, 453, 214, 72, 15, 2, 1, 0;
%e ...
%p g:= proc(n, m) option remember; `if`(n=0, 1,
%p add(g(n-j, min(n-j, m)), j=1..min(n, m)))
%p end:
%p h:= proc(n, t, m) option remember; `if`(n=0, 0,
%p `if`(t=1, add(g(n-j, j), j=m+1..n),
%p add(h(n-j, t-1, max(m, j)), j=1..n)))
%p end:
%p T:= (n, k)-> h(n, k, 0):
%p seq(seq(T(n, k), k=1..n), n=1..15);
%t g[n_, m_] := g[n, m] = If[n == 0, 1, Sum[g[n-j, Min[n-j, m]], {j, 1, Min[n, m]}]]; h[n_, t_, m_] := h[n, t, m] = If[n == 0, 0, If[t == 1, Sum[g[n-j, j], {j, m+1, n}], Sum[h[n-j, t-1, Max[m, j]], {j, 1, n}]]]; T[n_, k_] := h[n, k, 0]; Table[Table[T[n, k], {k, 1, n}], {n, 1, 15}] // Flatten (* _Jean-François Alcover_, Jan 12 2015, translated from Maple *)
%K nonn,tabl
%O 1,2
%A _Joerg Arndt_ and _Alois P. Heinz_, Feb 25 2014