login
Triangle read by rows: T(n,k) (for 0 <= k <= floor(n/2)) is the number of permutations of length n that have k descents and avoid the patterns 321 and 2341.
0

%I #15 May 12 2018 18:40:06

%S 1,1,1,1,1,4,1,10,2,1,20,13,1,35,49,4,1,56,140,36,1,84,336,181,8,1,

%T 120,714,670,92,1,165,1386,2035,578,16,1,220,2508,5368,2625,224,1,286,

%U 4290,12727,9633,1688,32,1,364,7007,27742,30303,9080,528,1,455,11011,56485,84721,39041,4640,64

%N Triangle read by rows: T(n,k) (for 0 <= k <= floor(n/2)) is the number of permutations of length n that have k descents and avoid the patterns 321 and 2341.

%F T(n, k) = Sum_{j=0..n-2k} (-1)^(n-j)*2^(3k-n+j-1)*binomial(3k+j, 3k)*binomial(k-1, n-2k-j) for k > 0.

%F G.f.: Sum_{n>=0} Sum_{k=0..floor(n/2)} T(n, k)*x^n*y^k = ((1-x)^2-x^2*y)/((1-x)^3-x^2(2-x)*y).

%e For n = 4 and k = 2, the T(4,2) = 2 permutations are 2143 and 3142.

%e Triangle T(n,k) begins:

%e 1;

%e 1;

%e 1, 1;

%e 1, 4;

%e 1, 10, 2;

%e 1, 20, 13;

%e 1, 35, 49, 4;

%e 1, 56, 140, 36;

%e 1, 84, 336, 181, 8;

%e 1, 120, 714, 670, 92;

%e 1, 165, 1386, 2035, 578, 16;

%t T[n_, k_] :=

%t If[k == 0, 1,

%t Sum[(-1)^(n - j)*2^(3 k - n + j - 1)*Binomial[j + 3 k, 3 k]*

%t Binomial[k - 1, n - 2 k - j], {j, 0, n - 2 k}]];

%t Flatten[Table[Table[T[n, k], {k, 0, Floor[n/2]}], {n, 0, 14}]]

%Y Row sums give A001519.

%K nonn,tabf

%O 0,6

%A _Colin Defant_, May 12 2018