Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Search: a230621 -id:a230621
     Sort: relevance | references | number | modified | created      Format: long | short | data
Triangle read by rows: T(n,k) is the number of permutations of {1,2,...,n} having k doubledescents (0 <= k <= n-2). We say that i is a doubledescent (also called a double fall) of a permutation p if p(i) > p(i+1) > p(i+2).
+10
18
1, 1, 2, 5, 1, 17, 6, 1, 70, 41, 8, 1, 349, 274, 86, 10, 1, 2017, 2040, 803, 167, 12, 1, 13358, 16346, 8221, 2064, 316, 14, 1, 99377, 143571, 86214, 28143, 4961, 597, 16, 1, 822041, 1365354, 966114, 374166, 88482, 11486, 1138, 18, 1
OFFSET
0,3
COMMENTS
Row n (n>=2) contains n-1 entries.
Sum of entries in row n is n! = A000142(n).
Sum_{k=0..n-2} k*T(n,k) = A005990(n-1).
The first Maple program yields (by straightforward counting) the generating polynomial of a specified row n.
REFERENCES
I. P. Goulden and D. M. Jackson, Combinatorial Enumeration, Wiley, New York, 1983.
LINKS
S. Elizalde and M. Noy, Consecutive patterns in permutations, Adv. Appl. Math. 30 (2003), 110-123.
P. Flajolet and R. Sedgewick, Analytic Combinatorics, 2009; see page 210
Yan Zhuang, Monoid networks and counting permutations by runs, arXiv preprint arXiv:1505.02308 [math.CO], 2015.
Y. Zhuang, Counting permutations by runs, J. Comb. Theory Ser. A 142 (2016), pp. 147-176.
FORMULA
E.g.f.: 1/(1 - x - Sum_{k,n} I(n,k)(y - 1)^k*x^n/n!) where I(n,k) is the coefficient of y^k*x^n in the ordinary generating function expansion of y x^3/(1 - y*x - y*x^2). See Flajolet and Sedgewick reference in Links section. - Geoffrey Critzer, Dec 12 2012
EXAMPLE
T(5,2) = 8 because we have 15432, 25431, 35421, 43215, 45321, 53214, 54213, and 54312.
Triangle starts:
1;
1;
2;
5, 1;
17, 6, 1;
70, 41, 8, 1;
349, 274, 86, 10, 1;
MAPLE
n := 7: dds := proc (p) local ct, j: ct := 0: for j from 3 to nops(p) do if p[j] < p[j-1] and p[j-1] < p[j-2] then ct := ct+1 else end if end do: ct end proc: with(combinat): P := permute(n): f[n] := sort(add(t^dds(P[i]), i = 1 .. factorial(n)));
# second Maple program:
b:= proc(u, o, t) option remember; `if`(u+o=0, 1, expand(
add(b(u-j, o+j-1, 1), j=1..u)+
add(b(u+j-1, o-j, 2)*`if`(t=2, x, 1), j=1..o)))
end:
T:= n-> (p-> seq(coeff(p, x, i), i=0..degree(p)))(b(n, 0, 1)):
seq(T(n), n=0..15); # Alois P. Heinz, Oct 25 2013
MATHEMATICA
nn=10; u=y-1; a=Apply[Plus, Table[Normal[Series[y x^3/(1-y x - y x^2), {x, 0, nn}]][[n]]/(n+2)!, {n, 1, nn-2}]]/.y->u; Range[0, nn]! CoefficientList[Series[1/(1-x-a), {x, 0, nn}], {x, y}]//Grid (* Geoffrey Critzer, Dec 12 2012 *)
KEYWORD
nonn,tabf
AUTHOR
Emeric Deutsch, Jul 26 2009
STATUS
approved
Number of permutations of [n] with at least two (possibly overlapping) occurrences of the consecutive step pattern {up}^2.
+10
2
0, 0, 0, 0, 1, 9, 97, 983, 10616, 119932, 1441405, 18383351, 249155667, 3581896559, 54540748818, 877824410030, 14904605652001, 266431586957773, 5004557444810885, 98594548150006583, 2033673324306909868, 43845407809459639440, 986496730691143433269
OFFSET
0,6
LINKS
FORMULA
a(n) = Sum_{i=2..n-2} A162975(n,i).
a(n) ~ n!. - Vaclav Kotesovec, Sep 06 2014
EXAMPLE
a(4) = 1: 1234.
a(5) = 9: 12345, 12354, 12453, 13452, 21345, 23451, 31245, 41235, 51234.
a(6) = 97: 123456, 123465, 123546, ..., 631245, 641235, 651234.
a(7) = 983: 1234567, 1234576, 1234657, ..., 7631245, 7641235, 7651234.
MAPLE
b:= proc(u, o, t) option remember;
`if`(t=5, (u+o)!, `if`(u+o+t<4, 0,
add(b(u-j, o+j-1, [1, 1, 4, 4][t]), j=1..u)+
add(b(u+j-1, o-j, [2, 3, 5, 3][t]), j=1..o)))
end:
a:= n-> b(n, 0, 1):
seq(a(n), n=0..25);
MATHEMATICA
b[u_, o_, t_] := b[u, o, t] =
If[t == 5, (u + o)!, If[u + o + t < 4, 0,
Sum[b[u - j, o + j - 1, {1, 1, 4, 4}[[t]]], {j, 1, u}] +
Sum[b[u + j - 1, o - j, {2, 3, 5, 3}[[t]]], {j, 1, o}]]];
a[n_] := b[n, 0, 1];
a /@ Range[0, 25] (* Jean-François Alcover, Dec 22 2020, after Alois P. Heinz *)
CROSSREFS
Cf. A230621.
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Oct 25 2013
STATUS
approved

Search completed in 0.006 seconds