Consecutive patterns in restricted permutations and involutions
M. Barnabei, F. Bonetti, N. Castronuovo, and M. Silimbani

TL;DR
This paper explores the combinatorial structures of restricted permutations and involutions, establishing bijections with Motzkin paths and analyzing pattern avoidance to derive distributions of permutation statistics.
Contribution
It introduces a new bijection between restricted permutations and Motzkin paths, and uses it to analyze pattern avoidance and permutation statistics.
Findings
Bijection between certain permutations and Motzkin paths.
Distribution of des and inv statistics over specific pattern-avoiding sets.
Enumeration of all length-three consecutive pattern distributions.
Abstract
It is well-known that the set In of involutions of the symmetric group Sn corresponds bijectively - by the Foata map F - to the set of n-permutations that avoid the two vincular patterns 123, 132. We consider a bijection Γ from the set Sn to the set of histoires de Laguerre, namely, bicolored Motzkin paths with labelled steps, and study its properties when restricted to Sn(123,132). In particular, we show that the set Sn(123,132) of permutations that avoids the consecutive pattern 123 and the classical pattern 132 corresponds via Γ to the set of Motzkin paths, while its image under F is the set of restricted involutions In(3412). We exploit these results to determine the joint distribution of the statistics des and inv…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsBayesian Methods and Mixture Models · Advanced Combinatorial Mathematics · Botanical Research and Chemistry
\publicationdetails
2120193215175
Consecutive patterns in restricted permutations and involutions ††thanks: This work was partially supported by the University of Bologna, funds for selected research topics.
Marilena Barnabei
Flavio Bonetti
Niccolò Castronuovo
Matteo Silimbani
Dipartimento di Matematica, Università di Bologna, Bologna, 40126, ITALY
(2019-2-7; 2019-5-17; 2019-5-17)
Abstract
It is well-known that the set In of involutions of the symmetric group Sn corresponds bijectively - by the Foata map F - to the set of n-permutations that avoid the two vincular patterns 123 and 132. We consider a bijection Γ from the set Sn to the set of histoires de Laguerre, namely, bicolored Motzkin paths with labelled steps, and study its properties when restricted to Sn(123,132). In particular, we show that the set Sn(123,132) of permutations that avoids the consecutive pattern 123 and the classical pattern 132 corresponds via Γ to the set of Motzkin paths, while its image under F is the set of restricted involutions In(3412). We exploit these results to determine the joint distribution of the statistics des and inv over Sn(123,132) and over In(3412). Moreover, we determine the distribution in these two sets of every consecutive pattern of length three. To this aim, we use a modified version of the well-known Goulden-Jacson cluster method.
keywords:
permutation pattern, involution, histoire de Laguerre, Motzkin path, cluster method
1 Introduction
In 1994 De Medicis and Viennot [5] introduced the definition of histoire de Laguerre, namely, a pair (d,l), where d is a Motzkin path of length n whose horizontal steps may have two different colors and l=(l1,…,ln) is a sequence of non-negative integers with suitable constraints.
Many bijections are present in the literature between the set Hn of histoires de Laguerre and the symmetric group Sn (see [10] for a survey on this topic), as well as between a specific subset Ln of Hn and the set In of involutions in Sn (see, e.g., [2]). More recently, Claesson [3] proved that the set In corresponds bijectively - via the classical Foata map - with the set Sn(123,132) of n-permutations that avoid the two vincular patterns 123 and 132.
In the first part of the present paper we consider the bijection Γ between the set of n-permutations and the set of historires de Laguerre described in [1], which is essentially the bijection defined in [4, p. 256], up to the reverse. This last bijection is in turn a slightly modified version of the well-known Françon-Viennot bijection [7]. We exploit Γ to connect the sets Sn(123,132), In and Ln. More precisely we prove that the image under Γ of the set Sn(123,132) is precisely the set Ln, namely, the set consisting of (uncolored) Motzkin paths whose down steps are labelled with an integer that does not exceed their height. Furthermore, we show that the bijection Ψ defined in [2] is nothing but the composition of the map F with Γ. Finally, the set of permutations avoiding the consecutive pattern 123 and the classical pattern 132 is mapped by Γ onto the set of unlabelled Motzkin paths and is mapped by F−1 onto the set of involutions avoiding the classical pattern 3412.
In the second part of the paper we exploit the properties of the maps Γ and Ψ to study in parallel some statistics over the two sets Sn(123,132) and In(3412). In particular, in both cases we determine the joint distribution of inversions and descents, as well as the distribution of the occurrences of every consecutive pattern of length three.
In many situations we take advantage of a particular instance of the Goulden-Jackson cluster method [8] for Motzkin paths. For the sake of completeness we describe this method in the Appendix.
2 The bijections
A Motzkin path of length n is a lattice path starting in (0,0), ending in (n,0), consisting of up steps U of the form (1,1), down steps D of the form (1,−1) and horizontal steps H of the form (1,0) and lying weakly above the x-axis.
As usual, a Motzkin path can be identified with a Motzkin word, namely, a word w=d1d2…dn of length n in the alphabet {U,D,H} with the constraint that the number of occurrences of the letter U is equal to the number of occurrences of the letter D and, for every i, the number of occurrences of U in the subword d1d2…di is not smaller than the number of occurrences of D. In the following we will not distinguish between a Motzkin path and the corresponding word.
Now we consider the set of *bicolored * Motzkin paths, defined as Motzkin paths whose horizontal steps have two possible colors c1 and c2, such that horizontal steps lying on the x-axis cannot be colored with the color c2. We will denote by H a horizontal step colored by c1 and with H a horizontal step colored by c2. It is well known that bicolored Motzkin paths are counted by Catalan numbers (see [12]).
We will denote by Mn and CMn the sets of Motzkin paths of length n and bicolored Motzkin paths of length n, respectively.
We associate to every d=d1d2…dn∈CMn the n-tuple h(d)=(h1,h2,…,hn), where for every i=1,…,n, the integer hi is defined as
[TABLE]
We will call the integer hi the height of the step di, and the n-tuple h(d) the height list of d.
Example 2.1**.**
Consider the bicolored Motzkin path d=UUDHDH, namely,
[TABLE]
where the horizontal step with color c2 is represented by a dashed line. Then h(d)=(0,1,1,1,0,0).
We now describe a map from the set of permutations of length n to the set CMn. This map is a slight modification of the map described in [1] in terms of valued Dyck paths.
Let π=π1π2…πn be a permutation in Sn written in one-line notation. An ascending run in π is a maximal increasing subword of π. For example, the ascending runs of 346512 are w1=346, w2=5 and w3=12. Write π as
[TABLE]
where the wi′s are the ascending runs in π. The first and the last element of an ascending run of length at least two are called a head and a tail, respectively. The only element of an ascending run of length one is called a head-tail. Every other element is called a boarder.
Now we associate to π a bicolored Motzkin path d of length n defined as follows. For i=1,…,n,
- •
if i is a head-tail, set di=H;
- •
if i is a head, set di=U;
- •
if i is a tail, set di=D;
- •
if i is a boarder, set di=H.
Then d=d1d2…dn.
Obviously the correspondence γ:π→d is far from being injective. For example, both the permutations 3124 and 1243 in S4 correspond to the bicolored Motzkin path UHHD. In order to get a bijection, we associate to the permutation π a pair (d,l), where d is the bicolored Motzkin path defined above and l=(l1,l2,…,ln) is the sequence of non-negative integers
[TABLE]
where sj and tj are the first and the last element of the j-th ascending run of π.
We denote by Γ(π) the pair (d,l) associated with the permutation π.
Example 2.2**.**
Consider the permutation π=826913547. The ascending runs of π are w1=8, w2=269, w3=135 and w4=47.
We have Γ(π)=(d,l), where d=UUHUDHDHD=
[TABLE]
and l=(0,0,1,2,1,0,1,0,0).
We observe that the above bijection is essentially the map defined in [4, p. 256], up to the reverse.
We recall that a pair (d,l), where d is a bicolored Motzkin path of length n and l=(l1,…,ln) is a sequence of non-negative integers, is called a histoire de Laguerre provided that li≤hi for all 1≤i≤n, where hi is the i-th element of the height list of d (see [5]). We denote by Hn the set of histoires de Laguerre of length n.
Theorem 2.3**.**
The map Γ is a bijection between Sn and Hn.
Proof.
See [1, Theorem 2.6]. ∎
We now describe the connection between the map Γ defined above and a bijection Ψ between the set In of involutions of length n and labeled Motzkin paths studied in [2]. In order to do this, we exploit a result proved by Claesson [3], namely, the fact that the classical Foata map induces a bijection between the set of involutions of length n and the set of permutations of the same length that avoid two vincular patterns.
Let π∈Sn and τ∈Sm. We say that π=π1…πn contains the pattern τ=τ1…τm in the classical sense if there exists an index subsequence 1≤i1<i2<…<im≤n such that the words πi1πi2…πim and τ1τ2…τm are order isomorphic. Otherwise, π avoids the pattern τ.
A vincular pattern is a permutation τ in Sm some of whose consecutive letters may be underlined. If τ contains τiτi+1…τj as a subword then the letters corresponding to τi,τi+1,…,τj in an occurrence of τ in a permutation σ must be adjacent, whereas there is no adjacency condition for non underlined consecutive letters (see [9, p. 10]).
For example, the permutation 431256 contains two occurrences of the vincular pattern 213, namely, 425 and 325. Note that a vincular pattern without underlined letters is a pattern in the classical sense. On the other hand, the occurrences of a vincular pattern all of whose letters are underlined must be formed by adjacent letters. The set of permutations of length n that avoid the vincular pattern τ is denoted by Sn(τ).
We now recall Claesson’s result. Let π be an involution. Write π in standard cycle notation, i.e., so that each cycle is written with its least element first and the cycles are written in decreasing order of their least element. Define F(π) to be the permutation obtained from π by erasing the parentheses separating the cycles. As an example consider π=47318625∈I8. The cycle notation for π is (6)(5,8)(3)(2,7)(1,4) and F(π)=65832714.
In [3] Claesson proved that the map F is a bijection between In and Sn(132,123). It is easily seen that this last set coincides with Sn(132,123) (see [6]). On the other hand, in [2] the authors define a bijection Φ between the set In and the set of labelled Motzkin paths of length n, namely, Motzkin paths whose down steps are labelled with an integer that does not exceed their height, while the other steps are unlabelled. The set of labelled Motzkin paths of length n will be denoted by Ln. Of course Ln⊂Hn.
In the present paper we need a bijection Ψ that is a slightly modified version of the bijection Φ. The map Ψ can be described as follows. Let π∈In.
For every i=1,…,n:
- •
if i is a fixed point for π , draw a horizontal step;
- •
if i is the first element in a 2-cycle, draw an up step;
- •
if i is the second element in a 2-cycle (j,i), draw a down step. Label this step with h, where h is the number of cycles (x,y) of π such that j<x<i<y .
For example, consider the involution π=65382174 whose standard cycle notation is (7)(48)(3)(25)(16). Then
[TABLE]
Our next aim is to prove the following result.
Theorem 2.4**.**
The image under Γ of the set Sn(132,123) is Ln, and the following diagram
[TABLE]
commutes.
First of all, we characterize the image of the map Γ, when restricted to the set Sn(132,123).
Proposition 2.5**.**
Let π∈Sn and let Γ(π)=(d,l). Then π∈Sn(132,123) if and only if
- •
the path d=d1…dn has no horizontal steps of color c2, and
- •
for every index i, li>0 implies that di is a down step.
Proof.
Firstly note that π avoids the pattern 123 if and only if the ascending runs of π have length at most two. In this case the set of boarders of π is empty and in d there are no horizontal steps of color c2.
Now let π∈Sn(132,123). Suppose that there exists an integer i such that li>0 and di is either an up step or a horizontal step. By definition of the sequence l, this implies that the permutation π contains three elements πs,πs+1,πr, with πr=i, such that
- •
r>s+1,
- •
πs and πs+1 are the head and the tail of an ascending run,
- •
πs<πr<πs+1,
- •
πr is either a head or a head-tail.
If πr is a head, then πr+1 is the corresponding tail and πs,πr,πr+1 form an occurrence of 123. If πr is a head-tail, πr−1>πr and πs,πr−1,πr form an occurrence of 132. But this is impossible since, as noted above, Sn(132,123)=Sn(132,123). On the other hand, if the permutation π contains an occurrence of the pattern 132 corresponding to the elements πj,πj+1,πj+2, then πj<πj+2<πj+1, πj+2 is a head or a head-tail, and πj,πj+1 are the head and the tail of an ascending run. Hence lπj+2>0. ∎
Theorem 2.4 now follows immediately from the description of the maps F, Γ and Ψ and from the previous Proposition.
As an example consider the involution π=(6)(48)(37)(2)(15)∈I8. Then the corresponding permutation in S8(132,123) is F(π)=64837215, and
[TABLE]
The subset of Ln of labelled Motzkin paths of length n all of whose labels are zero is obviously isomorphic to the set Mn of Motzkin paths. It is possible to characterize the preimage of this set under the maps Γ and Ψ in terms of pattern avoiding permutations. In fact, in [1] the following result is proved.
Proposition 2.6**.**
Let π∈Sn and let Γ(π)=(d,l). Then
[TABLE]
As a consequence Γ induces a bijection between Sn(132,123) and Mn.
Moreover, in [2, Theorem 9] it has been shown that the map Ψ induces a bijection between the set of involutions avoiding the pattern 3412 and the set of labelled Motzkin paths of length n all of whose labels are zero. These results imply that the following diagram
[TABLE]
commutes.
In the following sections we show how some statistics over the sets Sn(132,123) and In(3412) can be translated into statistics over Motzkin paths.
3 Inversions and descents over In(3412)
Let d be a Motzkin path. A tunnel in d is a horizontal segment between two lattice points of d lying weakly below d and containing exactly two lattice points of d. Note that each horizontal step of d is a tunnel. We will call the horizontal steps trivial tunnels.
We recall that each non-empty Motzkin path m can be decomposed either as Hm′, where m′ is an arbitrary Motzkin path, or as Um′Dm′′, where m′ and m′′ are arbitrary Motzkin paths. This decomposition is called first return decomposition. The definition of the map Ψ implies that each 2-cycle of an involution π∈In(3412) corresponds to a non-trivial tunnel of Ψ(π) and vice-versa.
Let π=π1…πn∈Sn. An inversion of π is a pair (i,j) with i<j such that πi>πj. In this case we will say that the symbol πi is in inversion with the symbol πj. The number of inversions of the permutation π will be denoted by inv(π).
The permutation π has a descent at position i if πi>πi+1. Otherwise, π has an ascent at position i.The number of descents of π will be denoted by des(π).
Now we want to study the joint distribution of the statistics inv, des, fix over the set
[TABLE]
where fix(π) denotes the number of fixed points of π, namely, determine an expression for the generating function
[TABLE]
First of all we prove a preliminary result.
Lemma 3.1**.**
Let π∈In(3412). Then
[TABLE]
where A is the area between the path Ψ(π) and the x-axis and t is the number of non-trivial tunnels of Ψ(π).
Proof.
Write π as π1π2…πn. Let i be the least index such that πi>i. Then (i,πi) is a cycle of π. Hence the symbol πi is in inversion with all the symbols πi+1,πi+2…πi+k=i, where k=πi−i. In fact, suppose by contradiction that there exist an index r, with 1≤r≤k−1, such that πi+r>πi, then πi,πi+r,i,r. would be an occurrence of the pattern 3412.
For the same reason the symbol i is in inversion with the k−1 elements πi+1,…,πi+k−1. Here we excluded the inversion (i,πi).
On the other hand, let T be the tunnel in the Motzkin path Ψ(π) corresponding to the cycle (i,πi). The area of the trapezoid with height one and T as a basis is precisely k=πi−i.
Repeating the preceding argument on the involution obtained from π by deleting the symbols i and πi we get the assertion. ∎
Lemma 3.2**.**
Let π∈In(3412). The descents of π correspond bijectively to the occurrences in Ψ(π) of the following subwords: UU, DD, UH, HD and UD.
Proof.
Suppose that one of these subwords occurs in the Motzkin path Ψ(π). Let v be this subword and i be the position of the first step of v. If v=UU, then both πi and πi+1 are the greater elements in their respective 2-cycles and hence πi>πi+1. If v=UH, then πi is the greater element in its 2-cycle while πi+1 is a fixed point and hence πi>πi+1. The other cases can be treated in a similar way. ∎
We recall that a weak valley of a Motzkin path is an occurrence of one of the following consecutive patterns:
[TABLE]
The preceding result yields immediately:
Corollary 3.3**.**
The distribution of ascents over n-involutions avoiding the pattern 3412 is the same as the distribution of weak valleys over Motzkin paths of length n.
This implies that the generating function G(x,z) of Motzkin paths according to the length (x) and the number of weak valleys (z) can be deduced from the function F(x,y,z,w) appearing in Formula (2) as follows:
[TABLE]
Similarly, 1+zF(xz,1,1/z,0)−1 gives the generating function of Dyck paths according to the length and the number of valleys, which is essentially given by Narayana polynomials.
The above lemmas imply that the generating function F satisfies the following equation obtained by the first return decomposition for Motzkin paths.
[TABLE]
In fact, the terms in the right hand side of the previous equation correspond to Motzkin paths either empty or of the form Hm, UDm, Um′Dm, with m′ non-empty, respectively.
From equation (5) we get easily the following continued fraction expression for F.
Theorem 3.4**.**
[TABLE]
where bi=−xy2iw−x2y2i+1z+x2y2i+1z2 and ci=x2y2i+1z2, i≥0.
4 The distribution of consecutive patterns in In(3412)
Lemma 3.2 allows us to translate every three-letter subword of a Motzkin path into an occurrence of a consecutive pattern of the corresponding involution in In(3412).
Theorem 4.1**.**
Let π∈In(3412) and let Ψ(π) be the corresponding Motzkin path. Then a subword of Ψ(π) of length three corresponds to an occurrence of a consecutive pattern in π according to the following table.
[TABLE]
[TABLE]
[TABLE]
[TABLE]
[TABLE]
[TABLE]
[TABLE]
[TABLE]
[TABLE]
Now we enumerate the involutions in In(3412) according to the occurrences of a given consecutive pattern of length three and the number of fixed points.
First of all, observe that an involution π∈In(3412) has k occurrences of 213 (312) and f fixed points if and only if RC(π) has k occurrences of 132 (231, respectively) and f fixed points, where RC(π) is the reverse-complement of the permutation π, namely, RC(π=π1…πn)=n+1−πn…n+1−π1.
Hence we can restrict our attention to the consecutive patterns 123, 321, 132 and 231.
4.1 The pattern 123
Let an,k,f be the number of involutions π∈In(3412) with k occurrences of 123 and with f fixed points.
Our goal is to find a formula for the generating function
[TABLE]
To this aim we use a variation of the Goulden-Jackson cluster method (see [8, p. 128]). In the Appendix we give a detailed description of the notations and the results that will be used.
By Theorem 4.1, the pattern 123 in π corresponds to occurrences in Ψ(π) of subwords in the set S={H3,H2U,DH2,DHU}. These subwords give rise to the clusters of type Hj with j≥3, HjU with j≥2, DHj with j≥2, and DHjU with j≥1.
Note that
- •
the cluster Hj reduces to a horizontal step and has depth 0,
- •
the cluster HjU reduces to an up step and has depth 0,
- •
the cluster DHj reduces to a down step and has depth 0,
- •
the cluster DHjU reduces to a horizontal step and has depth −1.
To find F we will use Theorem 7.1 of the Appendix.
First of all, we determine the generating functions AH(x,t,z), AH′(x,t,z), AD(x,t,z), AD′(x,t,z), AU(x,t,z) and AU′(x,t,z).
Consider the cluster Hj, j≥5. This can be obtained by either juxtaposing a horizontal step to the right of Hj−1 and adding an occurrence of the subword H3 that covers the last two letters of Hj−1
[TABLE]
or juxtaposing two horizontal steps to the right of Hj−2 and adding an occurrence of the subword H3 that covers the last letter of Hj−2
[TABLE]
Note that in these two cases the number of occurrences of H3 increases by one, the number of horizontal steps and the length increase by one in the first case and by two in the second case. As a consequence, the generating function for clusters of this kind is
[TABLE]
where the variables x,t, and z represent length, number of occurrences of the subwords in S and number of H, respectively.
Similarly, the cluster DHj, j≥4, can be obtained in the two ways depicted below
[TABLE]
or
[TABLE]
hence, the corresponding generating function is
[TABLE]
By similar arguments the generating function for the cluster HjU is
[TABLE]
Lastly, the cluster DHjU, j≥3 can be obtained by either juxtaposing the letter U to the right of DHj and adding an occurrence of H2U that covers the last two letters of DHj−1, or juxtaposing the letters HU to the right of DHj−1 and adding an occurrence of H2U that covers the last letter of DHj−1. By formula (12) we get the following expression for the generating function of the cluster of the form DHjU, j≥2
[TABLE]
The cluster DHU must be considered separately. Its contribution is x3tz.
As a consequence we have
[TABLE]
[TABLE]
and
[TABLE]
Now we are in position to apply Theorem 7.1, hence finding the generating function F123 evaluated in x,t+1,z. After the substitution t←t−1 we get the following expression for F123(x,t,z).
Theorem 4.2**.**
[TABLE]
where
[TABLE]
[TABLE]
and
[TABLE]
4.2 The pattern 132
Now we consider the pattern 132. By Theorem 4.1, an occurrence of this pattern in π∈In(3412) corresponds to six possible subwords in Ψ(π), namely, DUY and HUY′, where Y and Y′ can be any letters in {U,D,H}. The occurrences of such words correspond to the occurrences of DU and HU.
Also in this case we use the cluster method. Here we have S={HU,DU}. Note that the only possible clusters formed by these two words are HU and DU themselves. The first of these two clusters reduces to an up step and has depth 0, the second one reduces to a horizontal step and has depth −1. Hence we have
[TABLE]
[TABLE]
and
[TABLE]
Theorem 7.1 allows us to determine F132(x,t+1,z). After the substitution t←t−1, we get
Theorem 4.3**.**
[TABLE]
Notice that this generating function in the case z=1 encodes the distribution of weakly descending subpaths over the set of Motzkin paths (see sequence A114690 in [11]), where a weakly descending subpath is a maximal subword consisting of H and D steps. In fact, every occurrence either of HU or DU breaks a weakly descending subpath. Hence, in every Motzkin path the number of weakly descending subpaths equals the number of occurrences of these two patterns increased by one.
4.3 The pattern 321
Theorem 4.1 shows that the occurrences of the pattern 321 in π correspond to the occurrences of UUX, X′DD and UHD in Ψ(π), where X and X′ can be arbitrary letters in {U,H,D}. Hence the occurrences of this pattern corresponds to the occurrences of UU,DD and UHD in Ψ(π).
Let F321(x,t,z) be the corresponding generating function.
Denote by Xw and Yw be the first and last step of a Motzkin path w. We define
- •
A(x,t,z) to be the generating function of the set of Motzkin paths such that (Xw,Yw)=(U,D),
- •
B(x,t,z) to be the generating function of the set of Motzkin paths such that (Xw,Yw) is either (U,H) or (H,D),
- •
C(x,t,z) to be the generating function of the set of Motzkin paths such that (Xw,Yw)=(H,H).
Observe that the first return decomposition implies that
[TABLE]
A simple inclusion-exclusion argument yields
[TABLE]
Moreover it is easily seen that
[TABLE]
and
[TABLE]
Substituting in (26), we get
Theorem 4.4**.**
F321* satisfies the following functional equation*
[TABLE]
where
[TABLE]
[TABLE]
4.4 The pattern 312
This pattern correspond to occurrences of UHH and UHU in Ψ(π). Let F(x,t,z) be the corresponding generating function.
Set
[TABLE]
where o(UH),o(UHD) and o(H) denote the number of occurrences of the subwords UH,UHD and H in d.
By the first return decomposition we get the following recurrence for G.
[TABLE]
In fact, a Motzkin path can either
- •
be empty, or
- •
start by UD, UHD, or
- •
be of the form UHmDd or Um′Dd, where m is a non empty Motzkin path, m′ is a non empty path starting with U, and d an arbitrary path.
Hence we get a functional equation satisfied by F312(x,t,z) substituting in the previous equation t1←t and t2←t1:
[TABLE]
namely,
Theorem 4.5**.**
The generating function F312 satisfies the following functional equation
[TABLE]
where
[TABLE]
[TABLE]
5 Inversions and descents over Sn(132,123)
We now turn to the case of permutations in Sn(132,123).
First of all we recall that, given a permutation π∈Sn(132,123), if π=w1…wk is the decomposition of π into ascending runs, then the wi′s have length at most 2 and the sequence of the heads of π is a decreasing sequence. Moreover, the inverse of the map Γ has an easy description in terms of tunnels of the Motzkin path, as in the case of the map Ψ.
Proposition 5.1**.**
Let d be a Motzkin path and π the corresponding permutation in Sn(132,123). Let t1t2…tk be the sequence of tunnels of d, listed in decreasing order of the x-coordinate of their leftmost point. The decomposition of π into ascending runs is π=w1w2…wk with wi=xixi′, where xi is the x-coordinate of the first point of ti, increased by one, and xi′ is the x-coordinate of the last point of ti.
As an example consider the following Motzkin path
[TABLE]
The sequence of tunnels of d is given by 9-11, 6-7, 5-8, 2-4, 1-5, 0-9, where each tunnel is represented by the x-coordinates of its first and last point. Hence the corresponding permutation is π=1011768342519.
Recall that a coinversion in a permutation π is a pair (i,j) such that i<j and πi<πj. The number of coinversions of a permutation π will be denoted by coinv(π). Of course a permutation π has k coinversions if and only if it has (2n)−k inversions.
Now we are interested in the generating function for permutations in S(132,123):=∪n≥0Sn(132,123) enumerated by number of coinversions and number of descents:
[TABLE]
We have the following.
Proposition 5.2**.**
Let π∈Sn(132,123) and let Γ(π) be the corresponding Motzkin path. Then
- •
coinv(π)* is the area of Γ(π) and*
- •
des(π)* is equal to the number of tunnels of Γ(π) minus one.*
Proof.
Let (i,j) be a coinversion of the permutation π. Since the sequence of heads of π is decreasing, πj is a tail, hence it corresponds to a down step in Γ(π). Furthermore, given a down step Dˉ in Γ(π) at position k, consider the up step Uˉ that forms a tunnel with Dˉ, and denote by h the position of Uˉ. Then, by the construction of the map Γ, the coinversions of π having k as second element are precisely (x,k) where h≤x≤k−1. The number of such elements equals the area of the trapezoid determined by the tunnel between Uˉ and Dˉ.
The second statement follows immediately form the fact that every descent in π corresponds to a non initial head or head-tail. ∎
The above Proposition and the first return decomposition for Motzkin paths yield the following recurrence equation for the generating function F.
[TABLE]
Notice that F(x,1,z) is the generating function of sequence A107131 in [11], while F(x,y,1) is the generating function of sequence A129181 in [11].
6 The distribution of consecutive patterns in Sn(132,123)
Now we enumerate permutations π∈Sn(132,123) by the number of occurrences of a consecutive pattern of length three. Needless to say, we consider only the patterns 213, 231, 312 and 321.
6.1 The pattern 213
Let F213(x,t) be the generating function of permutations π∈Sn(132,123) enumerated by length and number of occurrences of 213.
Note that an occurrence of this pattern in a permutation π corresponds to an occurrence in Γ(π) of a sequence of the form UαD, where α is any non-empty Motzkin path. We call such a sequence a long tunnel.
In fact, an occurrence of 213 in π is a sequence of consecutive letters bac, with a<b<c. Here, ac is an ascending run wi+1, while b is either the tail or the head-tail of the preceding ascending run wi.
By Proposition 5.1, wi and wi+1 correspond to two tunnels ti,ti+1 such that ti lies above ti+1. Hence, the occurrence bac of the pattern 213 corresponds to the long tunnel ti+1.
Let F(x,t,y) be the generating function for Motzkin paths enumerated by length (x), occurrences of long tunnels (t) and peaks (y), i.e., occurrences of the sequence UD.
Notice that each non-empty Motzkin path can be either a horizontal step followed by any Motzkin path, or a peak followed by any Motzkin path, or a long tunnel followed by any Motzkin path. Hence, the generating function F(x,t,y) satisfies
[TABLE]
With the substitution y←1 we get
Theorem 6.1**.**
The generating function F213(x,t) satisfies the following equation:
[TABLE]
where
[TABLE]
6.2 The pattern 231
By Proposition 5.1 an occurrence in π of the pattern 231 corresponds to an occurrence in Γ(π) of an up step in a non-initial position. Let F(x,t,y) be the generating function of Motzkin paths enumerated by length (x), number of non-initial up steps (t), number of initial up steps (y).
We have the following recurrence for F(x,t,y):
[TABLE]
In fact, every non-empty Motzkin d path can be decomposed either as Hm, or Um′Dm′′, where m, m′, and m′′ are arbitrary Motzkin paths. Note that each up step in m, m′, or m′′ cannot be at the initial position of d.
Substituting y←t in (44) we find an expression for F(x,t,t):
[TABLE]
Substituting this expression in (44) and then replacing y←1 we get an expression for the generating function for permutations π∈Sn(132,123) enumerated by length (x) and number of occurrences of 231 (t):
[TABLE]
6.3 The pattern 312
An occurrence of the pattern 312 corresponds to an occurrence in Γ(π) of a peak p=UD such that Γ(π)=αpβ where β=Dk, k≥0. We call such peak a non-final peak.
Let F(x,t,y) be the generating function for Motzkin paths enumerated by length (x), number of non-final peaks (t), number of final peaks (y).
The first return decomposition implies that
[TABLE]
Using the same arguments of the previous Subsection we get the following expression for the generating function F(x,t,1):
[TABLE]
where
[TABLE]
with
[TABLE]
6.4 The pattern 321
An occurrence of the pattern 321 corresponds to an occurrence in Γ(π) of a horizontal step that is neither in the first nor in last position nor followed only by down steps. We call such a horizontal step a distinguished horizontal step.
Let F(x,t,y,z) be the generating function for Motzkin paths enumerated by length (x), number of distinguished horizontal steps (t), number of horizontal steps in the first position (y), number of horizontal steps followed only by a (possibly empty) sequence of down steps (z).
We have the following recurrence for F(x,t,y,z):
[TABLE]
As a consequence
[TABLE]
where
[TABLE]
with
[TABLE]
7 Appendix
In this appendix we describe the method that we used in Section 4 to count Motzkin paths by occurrences of a set of given subpatterns. This method is a slight modification of the Goulden-Jackson cluster method used to enumerate words over an arbitrary finite alphabet by occurrences of given subwords ([8, p. 128]). In this context the Goulden-Jackson cluster method does not apply directly, since the words we are considering correspond to Motzkin paths, hence, they have particular constraints. Our method is inspired by those presented in [13], where the author uses similar ideas to count Dyck words by occurrences of given subwords.
Let A be the set of words in the alphabet {U,D,H}, and let S⊆A.
Given w∈A, let ∣w∣ be the length of w, ∣w∣L its number of steps of type L∈{U,D,H} and ∣w∣S the total number of occurrences in w of subwords from S.
A marked subword of a word w=a1…an∈A with respect to the set S is a pair (i,v) where i is a positive integer, v=aiai+1…ai+∣v∣−1 and v∈S. A marked word is a word w∈A with a (possibly empty) set of marked subwords of w. A cluster with respect to S is a marked word that is not the concatenation of two nonempty marked words.
As an example, consider S={UUU,DHU}. The marked subwords of the word w=UUUHUDDUUUDDDDHUHDD are (1,UUU), (8,UUU) and (14,DHU). Hence
[TABLE]
is an example of a marked word.
Two clusters for S are the marked words
[TABLE]
[TABLE]
and
[TABLE]
[TABLE]
whereas
[TABLE]
[TABLE]
is not a cluster, because it can be seen as the juxtaposition of the marked words
(DHU,{(1,DHU)}) and (UUUU,{(1,UUU),(2,UUU)}).
Note that, if w′∈S, (w′,{(1,w′)}) is trivially a cluster.
We say that a word w∈A reduces to an up step (to a down step, to a horizontal step)if ∣w∣U−∣w∣D=1 (−1,0, respectively). If one of these three cases occur we say that w reduces to a single step. A cluster reduces to a single step if the underlying word does.
Now we define the depth of a word w∈A that reduces to a single step. Draw the word w in the lattice plane starting at the origin and assigning to the letters U,D,H the usual steps. Let k be the minimal y-coordinate reached by the resulting path. We say that w has depth k if it reduces to an up or horizontal step and k+1 if it reduces to a down step. For example, the word DDU has depth −1, the word DU has depth −1, and the word UDU has depth 0.
Recall that the height of a step di of a Motzkin path is
[TABLE]
Observe that if a Motzkin path can be decomposed as Um′Dm′′ then all the steps in m′ have height at least 1.
Theorem 7.1**.**
Let S={w1,…,wk} be a subset of A such that no words wi are proper subwords of other words in S. Suppose that each cluster formed by these words reduces to a single step and has depth greater than or equal to −1. Let AH(x,t,z) be the generating function of clusters that reduce to a horizontal step enumerated by length (x), occurrences of w1,…,wk as subwords (t), and horizontal steps (z). Denote by AH′(x,t,z) the generating function of clusters that reduce to a horizontal step with depth 0. The generating functions AD(x,t,z), AD′(x,t,z), and AU(x,t,z), AU′(x,t,z) are defined in the same way for clusters that reduce to a down step and an up step, respectively. Then the generating function F(x,t,z) for Motzkin paths enumerated by length, occurrences of the words w1,…,wk and number of horizontal steps satisfies
[TABLE]
where
- •
l=xz+AH(x,t,z),**
- •
l′=xz+AH′(x,t,z),**
- •
y=x+AU(x,t,z),**
- •
y′=x+AU′(x,t,z),**
- •
s=x+AD(x,t,z),**
- •
s′=x+AD′(x,t,z).**
Proof.
[TABLE]
[TABLE]
[TABLE]
where Sw is the set of words in S contained in w as subwords.
Hence F(x,t+1,z) counts Motzkin words weighted by the number of marked subwords contained therein, by length and number of horizontal steps.
We want to show that the right-hand side of (55) counts the same objects.
Let G(y,s,l,y′,s′,l′) be the generating function for Motzkin paths enumerated by occurrences of U,D and H at non-zero height and by occurrences of U,D and H at zero height. Hence, the formal power series G1(y,s,l):=G(y,s,l,y,s,l) is the generating function of Motzkin paths enumerated by occurrences of U,D and H.
By the first return decomposition we get immediately
[TABLE]
and
[TABLE]
As a consequence
[TABLE]
and
[TABLE]
Let G(x,t,z) be the generating function obtained from G(y,s,l,y′,s′,l′) by replacing
- •
the variable l by xz+AH(x,t,z)
- •
the variable l′ by xz+AH′(x,t,z)
- •
the variable y by x+AU(x,t,z)
- •
the variable y′ by x+AU′(x,t,z)
- •
the variable s by x+AD(x,t,z)
- •
the variable s′ by x+AD′(x,t,z).
Note that G(x,t,z) is precisely the right-hand side of Equation (55).
Let w be a Motzkin word. Choose in w some clusters c1,…,ck. By hypothesis these clusters have depth −1 or 0.
If in w we replace each cluster ci with the step that ci reduces to, we get another Motzkin word.
Conversely, given a Motzkin word v we can choose in v some up, down and horizontal steps, and replace them by a cluster that reduces to an up, down and horizontal step, respectively, with the constraint that a step of height [math] can be only replaced by a cluster of depth 0.
As a consequence the generating function G(x,t,z) counts marked Motzkin words weighted by the number of marked subwords contained therein.
∎
Acknowledgements.
We thank the anonymous referees for their detailed revisions and valuable suggestions.
The reference list from the paper itself. Each links out to its DOI / PubMed record.
- 1[1] M. Barnabei, F. Bonetti, N. Castronuovo, and M.Silimbani. Ascending runs in permutations and valued Dyck paths. Ars Mathematica Contemporanea , 16:445–463, 2019.
- 2[2] M. Barnabei, F. Bonetti, and M. Silimbani. Restricted involutions and Motzkin paths. Adv. in Appl. Math. , 47(1):102–115, 2011.
- 3[3] Anders Claesson. Generalized pattern avoidance. European J. Combin. , 22(7):961–971, 2001.
- 4[4] R. J. Clarke, E. Steingrímsson, and J. Zeng. New Euler-Mahonian statistics on permutations and words. Adv. in Appl. Math. , 18(3):237–270, 1997.
- 5[5] A. de Médicis and X. G. Viennot. Moments des q 𝑞 q -polynômes de Laguerre et la bijection de Foata-Zeilberger. Adv. in Appl. Math. , 15(3):262–304, 1994.
- 6[6] S. Elizalde and M. Noy. Consecutive patterns in permutations. Adv. in Appl. Math. , 30(1-2):110–125, 2003. Formal power series and algebraic combinatorics (Scottsdale, AZ, 2001).
- 7[7] J. Françon and G. X. Viennot. Permutations selon leurs pics, creux, doubles montées et double descentes, nombres d’Euler et nombres de Genocchi. Discrete Math. , 28(1):21–35, 1979.
- 8[8] I.P. Goulden and D.M. Jackson. Combinatorial Enumeration . Dover Publications, Inc., New York, NY, USA, 2004.
