On 1212-avoiding Restricted Growth Functions

Restricted growth functions (RGFs) avoiding the pattern 1212 are in natural bijection with noncrossing partitions. Motivated by recent work of Campbell et al., we study five classical statistics bk, ls, lb, rs and rb on 1212-avoiding RGFs. We show the equidistribution of (ls, rb, lb, bk) and (rb, ls, lb, bk) on 1212-avoiding RGFs by constructing a simple involution. To our surprise, this result was already proved by Simion 22 years ago via an involution on noncrossing partitions. Our involution, though turns out essentially the same as Simion's, is defined quite differently and has the advantage that makes the discussion more transparent. Consequently , a multiset-valued extension of Simion's result is discovered. Furthermore, similar approach enables us to prove the equidistribution of (mak, rb, rs, bk) and (rb, mak, rs, bk) on 1212-avoiding RGFs, where " mak " is a set partition statistic introduced by Steingrímsson. Through two bijections to Motzkin paths, we also prove that the triple of classical permutation statistics (exc + 1, den, inv − exc) on 321-avoiding permutations is equidistributed with the triple (bk, rb, rs) on 1212-avoiding RGFs, which generalizes another result of Simion. In the course, an interesting q-analog of the γ-positivity of Narayana polynomials is found.


Introduction
A restricted growth function (RGF) of length n is a word w = w 1 w 2 . . .w n on positive integers such that w 1 = 1 and w i+1 1 + max{w 1 , w 2 , . . ., w i } for all i 1.
A set partition of [n] := {1, 2, . . ., n} is a family of nonempty subsets (or blocks) B 1 , . . ., B k whose disjoint union is [n].RGFs are of interest because they are in natural bijection with set partitions in the following way.We first write a set partition σ of [n] as B 1 / . . ./B k in the standard form where min B 1 < min B 2 < • • • < min B k .Then the associated RGF w(σ) = w 1 . . .w n is defined as For example, we have w(13/24) = 1212.Note that the number of blocks of a set partition becomes the greatest integer in its associated RGF.Therefore, we denote bk(w) the greatest integer in w.
Let R n be the set of all RGFs of length n.Wachs and White [16] investigated four statistics ls (left smaller), lb (left bigger), rs (right smaller) and rb (right bigger) on RGFs defined for each w ∈ R n by: ls(w) := n i=1 #{w j : j < i, w j < w i }, lb(w) := n i=1 #{w j : j < i, w j > w i }, rs(w) := n i=1 #{w j : j > i, w j < w i } and rb(w) := n i=1 #{w j : j > i, w j > w i }.
For example, if w = 12334155 ∈ R 8 , then ls(w) = 16, lb(w) = 3, rs(w) = 4, rb(w) = 13.Recently, a systematic study of RGF patterns with respect to ls, lb, rs and rb was carried out by Campbell, Dahlberg, Dorward, Gerhard, Grubb, Purcell and Sagan in [1], where interesting connections with integer partitions and Motzkin paths were exhibited.At the end of their paper, unaware of the work by Simion [10], they conjectured that "rb" and "ls" are equidistributed on R n (1212), where R n (1212) is the set of 1212-avoiding RGFs of length n.Here an RGF w ∈ R n avoids the pattern 1212 means that there does not exist some indices i < j < k < l such that w i = w k < w j = w l .
Motivated by Campbell et al.'s conjecture above, we have been able to rediscover and reprove the following quadruple equidistribution that was first established by Simion [10] two decades ago.
the electronic journal of combinatorics 24(1) (2017), #P1.53 Our proof of Theorem 1 is by constructing an involution φ : R n (1212) → R n (1212), which interchanges the statistics "ls" and "rb" but preserves the statistics "lb" and "bk".It is not hard to show that a set partition is noncrossing (see [10] for the definition) if and only if its associated RGF is 1212-avoiding.It turns out that, under the natural bijection between set partitions and RGFs, our involution becomes Simion's [10], which was defined on noncrossing partitions (see Remark 1).Our involution φ is defined directly on 1212-avoiding RGFs, which is based on some kind of direct sum decomposition and has the advantage that makes the discussion more transparent.In particular, our approach leads to the discovery of a multiset-valued extension of Theorem 1 (see Theorem 9).Furthermore, similar approach can be applied to prove the following quadruple equidistribution involving the set partition statistic "mak" introduced by Steingrímsson [13] (see the definition of "mak" on RGFs in Section 3).
Our next result builds a relation between statistics on 1212-avoiding RGFs and classical Permutation Statistics, including excedances, inversions and Denert's statistic, on 321-avoiding permutations.We first review the involved statistics on permutations.Let S n be the set of permutations of the set of excedances (resp.excedance number) of π is and the set of non-excedances of π is Following Foata and Zeilberger [4, Th. 2], the Denert's statistic of π may be defined by where for a subset For example, if π = 2534716 ∈ S 7 , then inv(π) = 8, EXC(π) = {1, 2, 5}, exc(π) = 3 and den(π) = inv(257) + inv(3416) + 1 + 2 + 5 = 10.Note that "exc" is a Eulerian statistic, while both "inv" and "den" are Mahonian.Recall that a permutation π ∈ S n is said to be 321-avoiding if there does not exist indices i < j < k such that π i > π j > π k .Let S n (321) be the set of all 321-avoiding permutations in S n .
Let N n (t, p, q) := π∈Sn(321) t exc(π) p den(π) q inv(π)−exc(π) . (1.2) Since counting noncrossing partitions of [n] by the number of blocks minus 1 gives the n-th Narayana polynomial (cf.[11,Sec. 2.6]) the polynomial N n (t, p, q) is a (p, q)-analog of the Narayana polynomial.It is well known that N n (t) is γ-positive, i.e., it can be expanded as N n (t) = (n−1)/2 k=0 γ n,k t k (1 + t) n−1−2k with γ n,k ∈ N.Many combinatorial interpretations for γ n,k are known in the literature, see the excellent exposition by Petersen [11].For instance, Postnikov, Reiner and Williams [12] showed that γ n,k enumerates the 231-avoiding permutations of length n, with k descents and without initial and double descents.As one application of our bijection ψ, the following neat q-γ-positivity expansion for the q-Narayana polynomial N n (t, 1, q) is derived.
Note that Theorem 4 implies the sequence of coefficients of the polynomial (in t) N n (t, 1, q) is palindromic and unimodal in the sense that if N n (t, 1, q) = n−1 i=0 a n,i (q)t i , then • a n,i (q) = a n,n−1−i (q) for 0 i n − 1 and • a n,j+1 (q) − a n,j (q) ∈ N[q] for 0 j < (n − 1)/2.This result can be compared with the q-γ-positivity expansion of the (inv, exc)-q-Eulerian polynomials due to Shin and Zeng [9, Theorem 1].
The rest of this paper is organized as follows.In Section 2, we define the direct sum decomposition of RGFs and introduce the involution φ to prove Theorem 1.Based again on the direct sum decomposition, we construct in Section 3 a new involution τ on R n (1212) in the same spirit as φ (but more involved) to prove Theorem 2. Theorem 3 is proved in Section 4 by constructing the bijection ψ as function composition of two bijections to Motzkin paths.Section 5 is devoted to further applications of ψ.Indeed, we first establish Theorem 4 via a group action on Motzkin paths, then we continue to analyze Motzkin paths so as to obtain a recursion for N n (t, p, q) and a continued fraction expansion for the generating function of N n (t, 1, q).We conclude our paper with some further remarks.

Direct sum and the involution φ
We first recall one operation that is usually used to combine shorter words into longer ones.Suppose w = w 1 w 2 . . .w l 1 and v = v 1 v 2 . . .v l 2 are two words on positive integers with w's (resp.v's) maximum being m 1 (resp.m 2 ).We define the direct sum of w and v, denoted w ⊕ v, to be a word with maximum being m 1 + m 2 and length being l 1 + l 2 , and point-wisely it satisfies For example, we have 121 ⊕ 12 = 12134.If a word can be written as the direct sum of two non-empty words, we call it direct sum decomposable or simply decomposable.It is clear that the direct sum operation is associative, i.e., u ⊕ (v ⊕ w) = (u ⊕ v) ⊕ w.The following two fundamental lemmas are crucial for constructing our involution φ, the first of which should be immediate.
The direct sum w ⊕ v is a 1212-avoiding RGF if and only if both w and v are 1212-avoiding RGFs.

Now with the operation of direct sum in mind, we can give a new characterization of RGFs avoiding 1212.
the electronic journal of combinatorics 24(1) (2017), #P1.53 Lemma 6.For any RGF w = w 1 . . .w n ∈ R n , the following are equivalent: 1.The RGF w avoids 1212.
2. If w i = w i for some i < i , then for all j > i , either w j w i or w j > max{w 1 , . . ., w i }.
3. w is one of the following two types.
• Type II (decomposable): w does not end with 1, and there exists some nonempty 1212-avoiding RGFs u and v, such that w = u ⊕ v.
Proof.The equivalence of ( 1) and ( 2) is Lemma 5.2 in [1].We show here their equivalence with (3).When w satisfies (3), then w avoids 1212 by Lemma 5.It remains to show that if the RGF w avoids 1212, then it must be one of the two types in (3).Find the rightmost 1 in w, say at position i.If i = n, then clearly w is type I. Otherwise, 1 i < n.Let u = w 1 w 2 . . .w i .Since w i is the rightmost 1 of w, according to condition (2), we have w j > max{w 1 , . . ., w i } for all j > i.Hence, w = u ⊕ v, where v j = w i+j −bk(u) for all 1 j n−i.By Lemma 5, both u and v are RGFs and avoiding 1212.This shows w is type II in this case and the proof is complete.
We are ready to define our key map φ for Theorem 1.
Definition 1.For any RGF w that avoids 1212, we define the map φ recursively and according to the type of w (set φ(∅) = ∅): • Type I. Suppose w = ŵ1 k , where k 1 and ŵ (possibly empty) does not end with 1.
• Type II.Suppose w = u ⊕ v, then let Note that Lemma 5 ensures φ(w) is a 1212-avoiding RGF.In general, the direct sum decomposition of a 1212-avoiding RGF is not unique.For example, 12134 = 121 ⊕ 12 = 1213⊕1.However, the following lemma shows that φ is independent of the decomposition of w, hence well-defined.
the electronic journal of combinatorics 24(1) (2017), #P1.53 Proof.We prove this result by induction on the length of w.Without loss of generality, we suppose u ∈ R k (1212) and u ∈ R l (1212) with 1 k < l < n.Then, there exists a unique c ∈ R l−k (1212) such that u = u ⊕ c and v = c ⊕ v .Hence, by induction on the length of w and by the associativity of the direct sum, as desired.
The following result provides a proof of Theorem 1.
Theorem 8.The map φ is an involution on R n (1212) such that (ls, rb, lb, bk)(w) = (rb, ls, lb, bk)(φ(w)) (2.1) Proof.This result can be checked easily by induction on n.Notice that φ preserves the type of 1212-avoiding RGFs.We discuss in two cases according to the type of w.
Type I: suppose w = ŵ1 k , where k 1 and ŵ (possibly empty) does not end with 1.Thus, = rb(w) = 0 so (2.1) holds trivially.For the following we assume ŵ = ∅ and we have Type II: suppose w = u⊕v.Then, In either case the statement is true, which completes the proof of Theorem 8.
Remark 1.We recall Simion's involution φ in [10] that proves Theorem 1.Given a noncrossing partition Π of [n] written in standard form Relabel the elements of [n] as follows: the elements of the last block B k are relabeled 1, 2, . . ., |B k | in increasing order; next, the elements of the penultimate block in increasing order; and so on.Now, the i-th block of φ (Π) consists of the set of new labels given to the elements in the original interval For example, for Π = 1 2 3 8 13/4 6 7/5/9 12/10 11, φ (Π) = 1 2 4 13/3/5 7 8 12/6/9 10 11.Note that w(Π) = w = 1112322145541 and φ(w) = 1121343355531 as computed in the previous example.Now we see that φ(w(Π)) = w(φ (Π)) for this particular Π.In fact, this coincidence is true in general.One possible way to see this is by induction on n and by distinguishing two types of noncrossing partitions of [n]: (i) n is in the first block and (ii) n is not in the first block, which corresponds to type I and II of RGFs under the natural bijection.The details are left to the interested reader.
For any w ∈ R n , let us define the multiset-valued extension of ls(w) as the multiset LS(w) := {ls(w 1 ), ls(w 2 ), . . ., ls(w n )}, where ls(w i ) = #{w j : j < i, w j < w i }.Similarly, we define LB(w), RS(w) and RB(w).Actually, the involution φ can be applied to show the following multiset-valued extension of Theorem 1 without any difficulty.

Steingrímsson's set partition statistic "mak"
In [13], Steingrímsson introduced many statistics on (ordered or unordered) set partitions, of which the statistic "mak" is quite interesting.This statistic was inspired by the permutation statistic under the same name "mak" introduced by Foata and Zeilberger [4].
Here we will define "mak" on RGFs directly as follows.
Let w ∈ R n be a RGF.For each i ∈ [n], define lcs i (w) := #{w j : j < i, w j < w i and w k = w j for all k > j}.
Theorem 10 (See [6,7,16]).For any n 0, we have the quadruple equidistribution w∈Rn p mak(w) 1 p rb(w) 2 q rs(w) t bk(w) = w∈Rn p rb(w) 1 p mak(w) 2 q rs(w) t bk(w) (3.1) Moreover, there holds w∈Rn bk(w)=k p rb(w) q rs(w) = S p,q (n, k) = w∈Rn bk(w)=k p mak(w) q rs(w) , where S p,q (n, k) is the (p, q)-Stirling number of the second kind defined by the recursion: Note that the first identity of (3.2) is due to Wachs and White [16], while the second was proved by Ksavrelof and Zeng [7] in answering a conjecture of Steingrímsson [13].The quadruple equidistribution (3.1), as well as two different generalizations to ordered set partitions, were proved by Kasraoui and Zeng in [6] via the intermediate structure of path diagrams.Our quadruple equidistribution stated in Theorem 2 is a restricted version of (3.1).
• Type I.This means w must end with 1.Let w be the word obtained from w by subtracting each letter of w by 1 and then omitting all the 0s, and for any k with Then, For example, given w = 1112322145541, we have w = 12113443 and (4) = 8, (5) = 7, (9) = 4, etc.
the electronic journal of combinatorics 24(1) (2017), #P1.53 • Type II.Suppose w = u ⊕ v, then let When w is of type II, with the aid of Lemma 5 and 7, it is clear that τ (w) also avoids 1212 and is independent of the decomposition of w.But for those w of type I, we need the following lemma to see that τ is indeed well-defined.
Proof.We prove (3.3) by induction on n.It holds trivially for n = 1 since τ Now since w is of shorter length than w, say w ∈ R m (1212), m < n, by inductive hypothesis we get wm+1− (n+1−i) = wm+1− (n+1−j) .A moment of reflection reveals that the (m + 1 − (n + 1 − i))-th letter in w is indeed the (n + 1 − i)-th letter in w.We get w n+1−i = w n+1−j as desired.The case with w being of type II is similar by induction, thus omitted.Next we use (3.3) to show that τ (w) ∈ R n (1212) for any w of type I. Again we use induction on n.Suppose on the contrary that τ (w) ∈ R n (1212), by induction we can assume such occurrence of pattern 1212 involves letter 1.More precisely, suppose there exists some indices i < j < k such that Then by (3.3) we have Now the subword w 1 w n+1−k w n+1−j w n+1−i forms a pattern 1212 in w, a contradiction.This completes the proof.
The following result parallels Theorem 8 and proves Theorem 2.
Proof.That τ is an involution and bk(τ (w)) = bk(w) can be easily checked by definition and induction.Notice that τ also preserves the type of 1212-avoiding RGFs, so we deal with two types respectively.
the electronic journal of combinatorics 24(1) (2017), #P1.53 Type II is simpler so we consider it first.Given any We compute directly the remaining three statistics.
Type I is more involved.First note that since τ is an involution, we can strengthen (3.3) to the following form: This is the key to the ensuing argument.Given any w of type I, for each a, 1 < a bk(w), we consider the maximal subword of w formed purely by 1 and a, it must be of the following form since w avoids 1212 where the sub-indices are the original ones in w.As a result of property (3.5), we see that must be the maximal subword of τ (w) composed of 1 and b only, for certain 1 < b bk(w).And when a runs over 2, 3, . . ., bk(w), so does b.Now we analyse their contributions to each of the three statistics.
• mak = lb + lcs: w (a) adds t to lb, 0 to lcs, while τ (w) (b) adds r to lb, 0 to lcs; • rb: w (a) adds r to rb, while τ (w) (b) adds t to rb; • rs: both w (a) and τ (w) (b) add s to rs.
We sum up all the contributions when a and b traverse 2, 3, . . ., bk(w) respectively, and use induction on w, this amounts to establish (3.4), and the proof ends here.4 The bijection ψ and a proof of Theorem 3 The Motzkin paths are at the heart of our proof of Theorem 3. Recall that a Motzkin path of length n is a lattice path in N 2 starting at (0, 0), ending at (n, 0), with three possible steps: (1, 1) = U (up step), (1, −1) = D (down step) and (1, 0) = H (horizontal step).
For our purpose, we color each horizontal step of a Motzkin path by color a or b.We call such a Motzkin path a two-colored Motzkin path.See Fig. 1 for a display of the two-colored Motzkin path U bU aU DbDDU aD.Denote by M n the set of all two-colored Motzkin paths of length n.Note that M n−1 is enumerated by the famous n-th Catalan number as well as R n (1212) and S n (321).There is a bijection from M n−1 to R n (1212) due to Campbell et al. [1] which forms one step of our bijection ψ that we now describe.
Let M = s 1 s 2 . . .s n−1 be a two-colored Motzkin path in M n−1 .Given a step s i in M , we realize s i geometrically as the line segment in the plane that connects two lattice points in the obvious way.If s i = U then we pair it with the first D-step s j to its right, i.e. j > i, whose midpoint has the same height as the midpoint of s i .Continuing with our running example path, s 3 is paired with s 8 (see the dashed line in Fig. 1).The associated RGF ψ 1 (M ) = w = w 1 . . .w n of M is then defined as follows.Let w 1 = 1 and For instance, for the two-colored Motzkin path M in Fig. 1, we have ψ 1 (M ) = w = 1234454631771 and rb(w) = 28, rs(w) = 16, bk(w) = 7. Campbell et al. [1,Th. 5.7] showed that ψ 1 : M n−1 → R n (1212) is a bijection that satisfies the property area(M ) = rs(w), the electronic journal of combinatorics 24(1) (2017), #P1.53 where w = ψ 1 (M ) and area(M ) is the area between M and the x-axis.More precisely, they proved that rs(w i ) equals h(s i ) (resp.h(s i ) + 1) if s i = a, b or U (resp.s i = D).But what are the two statistics "rb" and "bk" on RGFs corresponding to?
To answer this question, we need to introduce a set-valued extension of "rb", which is different from the multiset-valued statistic "RB" introduced earlier.For each RGF w ∈ R n (1212), a shifted left-to-right maximum (position) of w is an index i ∈ [n − 1] such that w i+1 > w j for all j < i + 1.Let SLR(w) be the set of all shifted left-to-right maximum of w.For example, SLR(1234454631771) = {1, 2, 3, 5, 7, 10}.Proof.For any integer t ∈ {2, 3, . . ., bk(w)}, from left to right, w i is the first occurrence of letter t in w if and only if i − 1 is a shifted left-to-right maximum of w.Thus, the first equality follows.
Note that if w k = w k for some k < k , then all the letters in between positions k and k should be no less than w k .Otherwise, say w l < w k with k < l < k , then there must exist a letter w l = w l that occurs before w k , but this means w l w k w l w k is a 1212 pattern, a contradiction.Therefore, for any fixed letter t ∈ {2, 3, . . ., bk(w)}, only the first occurrence of t in w could contribute one to rb(w i ) for each letter w i (w i < t) to the left of it.The second equality then follows.
Let us introduce the statistic Ub(M ) for a two-colored Motzkin path M ∈ M Next, we will introduce a bijection ψ 2 : S n (321) → M (2) n−1 which transforms the pair (EXC, inv − exc) to (Ub, area).Our bijection ψ 2 is inspired by a bijection of Foata and Zeilberger [4] from permutations to Laguerre histories and a bijection of Cheng et al. [2] from 321-avoiding permutations to two-colored Motzkin paths.
We need two important vectors to keep track of the values and positions of excedances.
For each i ∈ EXC(π) (resp.i ∈ NEXC(π)), we call π i the excedance (resp.nonexcedance) value of π.We will also need the following characterization of 321-avoiding permutations, which is folkloric in pattern avoidance.Lemma 15.A permutation is 321-avoiding if and only if both the subsequence formed by its excedance values and the one formed by the remaining non-excedance values are increasing.Equivalently, π is 321-avoiding if and only if inv(EXC * (π)) = inv(NEXC * (π)) = 0.
We are ready for the key lemma of this section.Proof.Given a two-colored Motzkin path M that is an image under ψ 2 , we have the information for the positions and values of all the excedances of π such that ψ 2 (π) = M .Hence, by Lemma 15 such a π must be unique.This shows that ψ 2 is injective and thus bijective, since the cardinalities of M n−1 and S n (321) are both the Catalan number C n .The first equality in (4.2) is clear from the definition of ψ 2 and we will prove the second one by calculating (inv−exc)(π) via the two associated vectors val(π) and pos(π).Indeed, using the characterization given in Lemma 15, we see that for any π = π 1 . . .π n ∈ S n (321), an excedance of π must also be a left-to-right maximum of π.Consequently, an excedance, say π i , contributes π i − i to the value of inv(π), while each non-excedance contributes nothing.This observation leads to the following computation of inv(π) and exc(π): (2) n−1 t ub(M ) q area(M ) = M ∈O n−1 q area(M ) t ub(M ) (1 + t) n−1−2ub(M ) . (5.1) n−1 has no b-step if and only if ψ −1 2 (M ) = π 1 . . .π n has no excedance, say at i, such that π −1 i+1 i, applying ψ −1 2 to both sides of (5.1) then gives the q-γ-positivity expansion in Theorem 4.
5.2 A recurrence for N n (t, p, q) It is known that the Catalan numbers C n satisfy the recurrence relation Regarding our (p, q)-Narayana polynomials N n (t, p, q), we have the following Catalan-like recursion, which can be derived easily from Lemma 16 by using the usual decomposition of two-colored Motzkin paths.
Problem 23.Is there a combinatorial interpretation for the γ-coefficients γ n,k (q) in terms of 231-avoiding permutations or 1212-avoiding RGFs?Or more precisely, can one find certain statistic, say "st", on R n (1212) so that γ n,k (q) = w∈ Rn(1212) q st(w) ?