3.3 More about lengths and simples
Let us continue studying lengths of permutations.
Let \(n \in \mathbb {N}\) and \(\sigma \in S_n\). Then, \(\ell (\sigma ^{-1}) = \ell (\sigma )\).
Recall that \(\ell (\sigma )\) is the number of inversions of \(\sigma \), while \(\ell (\sigma ^{-1})\) is the number of inversions of \(\sigma ^{-1}\).
An inversion of \(\sigma \) is a pair \((i,j) \in [n] \times [n]\) such that \(i {\lt} j\) and \(\sigma (i) {\gt} \sigma (j)\). Likewise, an inversion of \(\sigma ^{-1}\) is a pair \((u,v) \in [n] \times [n]\) such that \(u {\lt} v\) and \(\sigma ^{-1}(u) {\gt} \sigma ^{-1}(v)\).
Thus, if \((i,j)\) is an inversion of \(\sigma \), then \((\sigma (j), \sigma (i))\) is an inversion of \(\sigma ^{-1}\). Hence, we obtain a map
This map is bijective (indeed, it has an inverse map, which sends each \((u,v) \in \{ \text{inversions of } \sigma ^{-1}\} \) to \((\sigma ^{-1}(v), \sigma ^{-1}(u))\)). Thus, the bijection principle yields
In other words, \(\ell (\sigma ) = \ell (\sigma ^{-1})\). (See [ Grinbe15 , Exercise 5.2 (f) ] for details.)
The explicit bijection between inversions of \(\sigma \) and inversions of \(\sigma ^{-1}\), sending \((i,j)\) to \((\sigma (j), \sigma (i))\).
- σ.inversionsBijection = Equiv.ofBijective (fun (p : ↥σ.inversions) => ⟨Equiv.Perm.inversionBijAux✝ σ ↑p, ⋯⟩) ⋯
Let \(n \in \mathbb {N}\), \(\sigma \in S_n\) and \(k \in [n-1]\). Then:
(a) We have
(b) We have
This combines parts (a) and (b).
Part (a) of Lemma 3.56: When multiplying a permutation \(\sigma \) on the right by the simple transposition \(s_k\), we have \(\ell (\sigma s_k) = \ell (\sigma ) + 1\) if \(\sigma (k) {\lt} \sigma (k+1)\), and \(\ell (\sigma s_k) = \ell (\sigma ) - 1\) if \(\sigma (k) {\gt} \sigma (k+1)\).
The proof partitions the inversions of \(\sigma \) and \(\sigma s_k\) into two kinds. Call an inversion \((i,j)\) of a permutation \(\tau \) the key pair if \((i,j) = (k,k+1)\); all other inversions are non-key.
Key observation: There is a bijection between non-key inversions of \(\sigma \) and non-key inversions of \(\sigma s_k\), given by applying the swap \(k \leftrightarrow k+1\) to both coordinates. This bijection preserves the strict ordering of the pair coordinates because there is no element strictly between \(k\) and \(k+1\).
Thus
For the key pair \((k,k+1)\): it is an inversion of \(\sigma \) if and only if \(\sigma (k+1) {\lt} \sigma (k)\), and it is an inversion of \(\sigma s_k\) if and only if \(\sigma (k) {\lt} \sigma (k+1)\). So the key pair’s inversion status flips when we pass from \(\sigma \) to \(\sigma s_k\).
Combining these two observations: the number of inversions changes by exactly \(\pm 1\), depending on whether the key pair is added or removed.
Part (b) of Lemma 3.56: When multiplying a permutation \(\sigma \) on the left by the simple transposition \(s_k\), we have \(\ell (s_k \sigma ) = \ell (\sigma ) + 1\) if \(\sigma ^{-1}(k) {\lt} \sigma ^{-1}(k+1)\), and \(\ell (s_k \sigma ) = \ell (\sigma ) - 1\) if \(\sigma ^{-1}(k) {\gt} \sigma ^{-1}(k+1)\).
We use the identity \(s_k \sigma = (\sigma ^{-1} s_k)^{-1}\) (since \(s_k\) is its own inverse) and then apply Proposition 3.54 and part (a).
Let \(n \in \mathbb {N}\) and \(\sigma \in S_n\). Let \(i\) and \(j\) be two elements of \([n]\) such that \(i {\lt} j\). Then:
(a) We have \(\ell (\sigma t_{i,j}) {\lt} \ell (\sigma )\) if \(\sigma (i) {\gt} \sigma (j)\). We have \(\ell (\sigma t_{i,j}) {\gt} \ell (\sigma )\) if \(\sigma (i) {\lt} \sigma (j)\).
(b) We have
where
This combines parts (a) and (b).
The set \(Q\) from Proposition 3.59: \(Q = \{ k \in \{ i+1, \ldots , j-1\} \mid \sigma (j) {\lt} \sigma (k) {\lt} \sigma (i)\} \).
The set \(R\) from Proposition 3.59: \(R = \{ k \in \{ i+1, \ldots , j-1\} \mid \sigma (i) {\lt} \sigma (k) {\lt} \sigma (j)\} \).
3.3.1 Helpers for Proposition 3.59
The set \(A\) from the transposition length proof: \(A = \{ a {\lt} i \mid \sigma (j) {\lt} \sigma (a) {\lt} \sigma (i)\} \). These elements produce paired lost and gained inversions: \((a, j)\) is lost and \((a, i)\) is gained.
The set \(B\) from the transposition length proof: \(B = \{ b {\gt} j \mid \sigma (j) {\lt} \sigma (b) {\lt} \sigma (i)\} \). These elements produce paired lost and gained inversions: \((i, b)\) is lost and \((j, b)\) is gained.
The set \(Q\) for \(\sigma \cdot t_{i,j}\) equals the set \(R\) for \(\sigma \). This key symmetry allows reducing the case \(\sigma (i) {\lt} \sigma (j)\) to the case \(\sigma (i) {\gt} \sigma (j)\) in the transposition length formula.
For \(k\) between \(i\) and \(j\) with \(k \neq i, j\), the swap \(t_{i,j}\) fixes \(k\), so \((\sigma \cdot t_{i,j})(k) = \sigma (k)\). The conditions \((\sigma t_{i,j})(j) {\lt} \sigma (k) {\lt} (\sigma t_{i,j})(i)\) become \(\sigma (i) {\lt} \sigma (k) {\lt} \sigma (j)\), which defines \(R\).
When \(\sigma (j) {\lt} \sigma (i)\), the pair \((i,j)\) itself is a lost inversion: \((i,j) \in \operatorname {inv}(\sigma ) \setminus \operatorname {inv}(\sigma \cdot t_{i,j})\).
Since \((\sigma t_{i,j})(i) = \sigma (j) {\lt} \sigma (i) = (\sigma t_{i,j})(j)\), the pair \((i,j)\) is no longer an inversion after applying \(t_{i,j}\).
For \(k \in Q\): the pair \((i, k)\) is a lost inversion. Before the swap, \(\sigma (i) {\gt} \sigma (k)\) so \((i,k)\) is an inversion. After the swap, \((\sigma t_{i,j})(i) = \sigma (j) {\lt} \sigma (k)\), so it is not.
Direct verification using the definition of \(Q\) and the swap.
For \(k \in Q\): the pair \((k, j)\) is a lost inversion. Before the swap, \(\sigma (k) {\gt} \sigma (j)\) so \((k,j)\) is an inversion. After the swap, \((\sigma t_{i,j})(j) = \sigma (i) {\gt} \sigma (k)\), so it is not.
Direct verification using the definition of \(Q\) and the swap.
For \(a \in A\): the pair \((a, j)\) is a lost inversion. Before the swap, \(\sigma (a) {\gt} \sigma (j)\). After the swap, \((\sigma t_{i,j})(j) = \sigma (i) {\gt} \sigma (a)\), so \((a,j)\) is no longer an inversion.
Direct verification.
For \(b \in B\): the pair \((i, b)\) is a lost inversion. Before the swap, \(\sigma (i) {\gt} \sigma (b)\). After the swap, \((\sigma t_{i,j})(i) = \sigma (j) {\lt} \sigma (b)\), so \((i,b)\) is no longer an inversion.
Direct verification.
For \(a \in A\): the pair \((a, i)\) is a gained inversion. Before the swap, \(\sigma (a) {\lt} \sigma (i)\) so \((a,i)\) is not an inversion. After the swap, \((\sigma t_{i,j})(i) = \sigma (j) {\lt} \sigma (a)\), so it becomes one.
Direct verification.
For \(b \in B\): the pair \((j, b)\) is a gained inversion. Before the swap, \(\sigma (j) {\lt} \sigma (b)\) so \((j,b)\) is not an inversion. After the swap, \((\sigma t_{i,j})(j) = \sigma (i) {\gt} \sigma (b)\), so it becomes one.
Direct verification.
Completeness of the lost inversion classification: every lost inversion \((a,b) \in \operatorname {inv}(\sigma ) \setminus \operatorname {inv}(\sigma \cdot t_{i,j})\) (with \(\sigma (j) {\lt} \sigma (i)\)) is one of five types:
\((a,b) = (i,j)\),
\(a \in A\) and \(b = j\),
\(a = i\) and \(b \in B\),
\(a = i\) and \(b \in Q\),
\(a \in Q\) and \(b = j\).
By case analysis on whether \(a\) or \(b\) equals \(i\) or \(j\), and using the fact that the swap only changes the values at positions \(i\) and \(j\).
Completeness of the gained inversion classification: every gained inversion \((a,b) \in \operatorname {inv}(\sigma \cdot t_{i,j}) \setminus \operatorname {inv}(\sigma )\) (with \(\sigma (j) {\lt} \sigma (i)\)) is one of two types:
\(a \in A\) and \(b = i\),
\(a = j\) and \(b \in B\).
By case analysis, similar to the lost inversion completeness.
Let \(\sigma \in S_n\) and \(i {\lt} j\) with \(\sigma (j) {\lt} \sigma (i)\). Then the number of “lost” inversions (inversions of \(\sigma \) that are not inversions of \(\sigma \cdot t_{i,j}\)) exceeds the number of “gained” inversions (inversions of \(\sigma \cdot t_{i,j}\) that are not inversions of \(\sigma \)) by exactly \(2|Q| + 1\).
The proof partitions lost inversions into five disjoint types: the pair \((i,j)\) itself; pairs \((a,j)\) and \((i,b)\) for \(a \in A\), \(b \in B\); and pairs \((i,k)\) and \((k,j)\) for \(k \in Q\). Gained inversions are pairs \((a,i)\) for \(a \in A\) and \((j,b)\) for \(b \in B\). The sets \(A\) and \(B\) cancel, leaving \(2|Q|+1\).
By explicit enumeration and counting of the five types of lost inversions and two types of gained inversions.
Part (b) of Proposition 3.59: The exact formula for length change when multiplying by an arbitrary transposition \(t_{i,j}\).
Case \(\sigma (i) {\gt} \sigma (j)\): This is [ Grinbe15 , Exercise 5.20 ] . Apply Lemma 3.74 directly. The symmetric difference formula \(|\mathrm{inv}(\sigma t_{i,j})| + |\mathrm{lost}| = |\mathrm{inv}(\sigma )| + |\mathrm{gained}|\) together with \(|\mathrm{lost}| = |\mathrm{gained}| + 2|Q| + 1\) gives \(\ell (\sigma t_{i,j}) = \ell (\sigma ) - 2|Q| - 1\).
Case \(\sigma (i) {\lt} \sigma (j)\): Apply the previous case to \(\sigma t_{i,j}\) instead of \(\sigma \). Since \((\sigma t_{i,j})(i) = \sigma (j) {\gt} \sigma (i) = (\sigma t_{i,j})(j)\), and \(\sigma t_{i,j} t_{i,j} = \sigma \), and the sets \(Q\) and \(R\) trade places when we replace \(\sigma \) by \(\sigma t_{i,j}\), we obtain \(\ell (\sigma ) = \ell (\sigma t_{i,j}) - 2|R| - 1\), hence \(\ell (\sigma t_{i,j}) = \ell (\sigma ) + 2|R| + 1\).
Part (a) of Proposition 3.59: The length decreases if \((i,j)\) was an inversion, and increases if it was not.
This follows immediately from part (b): when \(\sigma (i) {\gt} \sigma (j)\), the formula gives \(\ell (\sigma t_{i,j}) = \ell (\sigma ) - 2|Q| - 1 {\lt} \ell (\sigma )\), and when \(\sigma (i) {\lt} \sigma (j)\), the formula gives \(\ell (\sigma t_{i,j}) = \ell (\sigma ) + 2|R| + 1 {\gt} \ell (\sigma )\).
A simple transposition in \(S_n\) means one of the \(n-1\) transpositions \(s_0, s_1, \ldots , s_{n-2}\). We shall occasionally abbreviate “simple transposition” as “simple”.
A word (of length \(q\)) in \(S_n\) is a finite sequence \((k_1, k_2, \ldots , k_q)\) where each \(k_i \in \{ 0, 1, \ldots , n-2\} \) is an index of a simple transposition.
The product of a word \(w = (k_1, \ldots , k_q)\) is the permutation \(s_{k_1} s_{k_2} \cdots s_{k_q}\).
A word \(w = (k_1, \ldots , k_q)\) is reduced if its length \(q\) equals \(\ell (s_{k_1} \cdots s_{k_q})\).
- Equiv.Perm.IsReduced w = (List.length w = (Equiv.Perm.wordProd w).length)
Let \(n \in \mathbb {N}\) and \(\sigma \in S_n\). Then:
(a) We can write \(\sigma \) as a composition (i.e., product) of \(\ell (\sigma )\) simples.
(b) The number \(\ell (\sigma )\) is the smallest \(p \in \mathbb {N}\) such that we can write \(\sigma \) as a composition of \(p\) simples.
Keep in mind: The composition of \(0\) simples is \(\mathrm{id}\), since \(\mathrm{id}\) is the neutral element of the group \(S_n\).
This combines parts (a) and (b).
Part (a) of Theorem 3.81: Every permutation \(\sigma \in S_n\) can be written as a composition of \(\ell (\sigma )\) simple transpositions. Equivalently, there exists a reduced word \(w\) whose product \(s_{k_1} \cdots s_{k_q} = \sigma \).
(See [ Grinbe15 , Exercise 5.2 (e) ] for details.)
We proceed by strong induction on \(\ell (\sigma )\).
Base case: If \(\ell (\sigma ) = 0\), then \(\sigma = \mathrm{id}\) (a permutation with no inversions is the identity), so the empty word works.
Induction step: If \(\ell (\sigma ) = h + 1 {\gt} 0\), then \(\sigma \) has at least one inversion, so there exists \(k \in [n-1]\) with \(\sigma (k) {\gt} \sigma (k+1)\). By Lemma 3.56 (a), \(\ell (\sigma s_k) = \ell (\sigma ) - 1 = h\). By the induction hypothesis, \(\sigma s_k\) has a reduced word \(w\) of length \(h\). Then \(w \mathbin {+\! +} [k]\) is a reduced word of length \(h+1\) for \(\sigma s_k \cdot s_k = \sigma \).
Part (b) of Theorem 3.81: For any word \(w = (k_1, \ldots , k_q)\), we have \(\ell (s_{k_1} \cdots s_{k_q}) \leq q\). In other words, \(\ell (\sigma )\) is the minimum word length.
(See [ Grinbe15 , Exercise 5.2 (g) ] for details.)
We prove \(\ell (s_{k_1} s_{k_2} \cdots s_{k_g}) \leq g\) by induction on \(g\). The base case \(g = 0\) gives \(\ell (\mathrm{id}) = 0\). For the induction step, Lemma 3.56 (b) gives \(\ell (s_k \cdot \tau ) \leq \ell (\tau ) + 1\) for any \(\tau \) and \(k\), so \(\ell (s_{k_1} \cdots s_{k_g}) \leq \ell (s_{k_2} \cdots s_{k_g}) + 1 \leq (g-1) + 1 = g\).
Combining parts (a) and (b): \(\ell (\sigma )\) is exactly the minimum word length for \(\sigma \).
Immediate from parts (a) and (b).
Let \(n \in \mathbb {N}\).
(a) We have \(\ell (\sigma \tau ) \equiv \ell (\sigma ) + \ell (\tau ) \pmod{2}\) for all \(\sigma , \tau \in S_n\).
(b) We have \(\ell (\sigma \tau ) \leq \ell (\sigma ) + \ell (\tau )\) for all \(\sigma , \tau \in S_n\).
(c) Let \(k_1, k_2, \ldots , k_q \in [n-1]\), and let \(\sigma = s_{k_1} s_{k_2} \cdots s_{k_q}\). Then \(q \geq \ell (\sigma )\) and \(q \equiv \ell (\sigma ) \pmod{2}\).
This combines parts (a), (b), and (c).
Part (a) of Corollary 3.85: The length of a product has the same parity as the sum of lengths.
(See [ Grinbe15 , Exercise 5.2 (b) ] for details.)
Write \(\tau = s_{k_1} s_{k_2} \cdots s_{k_q}\) with \(q = \ell (\tau )\) (using Theorem 3.81 (a)). Then
Part (b) of Corollary 3.85: The triangle inequality \(\ell (\sigma \tau ) \leq \ell (\sigma ) + \ell (\tau )\).
Part (c) of Corollary 3.85: For any word representing \(\sigma \), the word length is at least \(\ell (\sigma )\) and has the same parity as \(\ell (\sigma )\).
The inequality \(q \geq \ell (\sigma )\) is Theorem 3.81 (b). The parity claim \(q \equiv \ell (\sigma ) \pmod{2}\) is proved by the same telescoping argument as part (a), starting from \(\ell (\sigma ) = \ell (s_{k_1} \cdots s_{k_q})\) and peeling off one simple at a time.
Let \(n \in \mathbb {N}\). Then, the group \(S_n\) is generated by the simples \(s_0, s_1, \ldots , s_{n-2}\).
This follows directly from Theorem 3.81 (a): every \(\sigma \in S_n\) can be written as a product of simple transpositions, so every \(\sigma \) lies in the subgroup generated by the simples.
3.3.2 Rothe diagram and Lehmer entry properties
A cell \((i, j)\) is in the Rothe diagram of \(\sigma \) if \(j {\lt} \sigma (i)\) and \(i {\lt} \sigma ^{-1}(j)\). These are the cells that are not “hit” by either the row or column of a permutation matrix entry.
The number of cells in the Rothe diagram of \(\sigma \) equals \(\ell (\sigma )\). The bijection sends \((i, j)\) in the Rothe diagram to the inversion \((i, \sigma ^{-1}(j))\).
The map \((i,j) \mapsto (i, \sigma ^{-1}(j))\) is a bijection from Rothe diagram cells to inversions: the condition \(j {\lt} \sigma (i)\) becomes \(\sigma (\sigma ^{-1}(j)) {\lt} \sigma (i)\), which is \(\sigma (k) {\lt} \sigma (i)\) with \(k = \sigma ^{-1}(j) {\gt} i\).
For \(\sigma \in S_n\) and \(i \in [n]\), we have \(\ell _i(\sigma ) {\lt} n - i\). This strict bound holds because \(\ell _i(\sigma )\) counts elements among \(\{ i+1, \ldots , n-1\} \) where \(\sigma (j) {\lt} \sigma (i)\), and there are only \(n - 1 - i\) such elements.
The set counted by \(\ell _i(\sigma )\) is a subset of \(\{ j : j {\gt} i\} \), which has cardinality \(n - 1 - i {\lt} n - i\).
For \(\sigma \in S_n\) with \(n {\gt} 0\), we have \(\sigma (0) = \ell _0(\sigma )\). This is because \(\ell _0(\sigma )\) counts how many elements among \(\sigma (1), \ldots , \sigma (n-1)\) are less than \(\sigma (0)\), and since \(\sigma \) is a bijection onto \(\{ 0, \ldots , n-1\} \), this count equals \(\sigma (0)\).
The elements \(j {\gt} 0\) with \(\sigma (j) {\lt} \sigma (0)\) are in bijection (via \(j \mapsto \sigma (j)\)) with elements \(v {\lt} \sigma (0)\). Since \(\sigma \) is a bijection, there are exactly \(\sigma (0)\) such elements.
For \(\sigma \in S_n\) and \(i\) with \(i + 1 {\lt} n\), let \(i' = i + 1\). Then
This characterizes when consecutive Lehmer entries differ by at least 1, which is crucial for determining when a Lehmer block shifts a position.
The Lehmer entry \(\ell _i(\sigma )\) counts \(j {\gt} i\) with \(\sigma (j) {\lt} \sigma (i)\). We split this count by whether \(j = i'\) or \(j {\gt} i'\): \(\ell _i(\sigma ) = [[\sigma (i') {\lt} \sigma (i)]] + |\{ j {\gt} i' : \sigma (j) {\lt} \sigma (i)\} |\). The set \(\{ j {\gt} i' : \sigma (j) {\lt} \sigma (i)\} \) contains \(\{ j {\gt} i' : \sigma (j) {\lt} \sigma (i')\} \) (counted by \(\ell _{i'}(\sigma )\)) when \(\sigma (i') {\lt} \sigma (i)\), from which the equivalence follows.
Two permutations \(\sigma , \tau \in S_n\) with the same inversions are equal: if for all \(i {\lt} j\) we have \(\sigma (j) {\lt} \sigma (i) \iff \tau (j) {\lt} \tau (i)\), then \(\sigma = \tau \).
For each \(i\), the value \(\sigma (i)\) equals \(|\{ j : \sigma (j) {\lt} \sigma (i)\} |\) (since \(\sigma \) is a bijection onto \(\{ 0, \ldots , n-1\} \)). The hypothesis implies \(\{ j : \sigma (j) {\lt} \sigma (i)\} = \{ j : \tau (j) {\lt} \tau (i)\} \) for each \(i\), so \(\sigma (i) = \tau (i)\).
3.3.3 The Lehmer code representation
For each \(i \in [n]\), we define the Lehmer block \(a_i\) as
where \(i' = i + \ell _i(\sigma )\) and \(\ell _i(\sigma )\) is the Lehmer entry at position \(i\). If \(\ell _i(\sigma ) = 0\), then \(a_i = \mathrm{id}\) (the empty product). The product \(a_i\) equals the cycle \((i', i'-1, \ldots , i)\).
- σ.lehmerBlock i = List.map (fun (k : Fin (σ.lehmerEntry i)) => ⟨↑i + σ.lehmerEntry i - 1 - ↑k, ⋯⟩) (List.finRange (σ.lehmerEntry i))
The length of the Lehmer block \(a_i\) (as a word) equals the Lehmer entry \(\ell _i(\sigma )\).
The block consists of \(\ell _i(\sigma )\) simple transpositions by construction.
The canonical reduced word for \(\sigma \) is the concatenation of Lehmer blocks:
- σ.canonicalReducedWord = (List.map σ.lehmerBlock (List.finRange n)).flatten
The length of the canonical reduced word equals \(\ell (\sigma )\). This follows from \(\sum _{i} \ell _i(\sigma ) = \ell (\sigma )\).
Each block \(a_i\) has length \(\ell _i(\sigma )\), and the total length is \(\sum _i \ell _i(\sigma ) = \ell (\sigma )\) (since each inversion contributes to exactly one Lehmer entry).
The sum of Lehmer entries equals the length: \(\sum _{i \in [n]} \ell _i(\sigma ) = \ell (\sigma )\).
By a bijection between the set of pairs \(\{ (i, j) : i \in [n],\ j \text{ such that } (i,j) \text{ is an inversion}\} \) and the set of all inversions.
3.3.4 Helpers for Proposition 3.107
For \(\sigma \in S_n\) and \(i \in [n]\), define \(s(\sigma , i) = |\{ j {\lt} i : \sigma (j) {\lt} \sigma (i)\} |\). This counts positions before \(i\) with smaller values.
For \(\sigma \in S_n\) and \(i \in [n]\), define \(g(\sigma , i) = |\{ j {\lt} i : \sigma (j) {\gt} \sigma (i)\} |\). This counts inversions with \(i\) as the second element.
For \(\sigma \in S_n\) and \(i \in [n]\):
This is because the elements \(j {\lt} i\) are partitioned into those with \(\sigma (j) {\lt} \sigma (i)\) and those with \(\sigma (j) {\gt} \sigma (i)\) (equality is impossible since \(\sigma \) is injective).
The set \(\{ j : j {\lt} i\} \) has cardinality \(i\) and splits into \(\{ j {\lt} i : \sigma (j) {\lt} \sigma (i)\} \) and \(\{ j {\lt} i : \sigma (j) {\gt} \sigma (i)\} \), which are disjoint (since \(\sigma \) is injective, \(\sigma (j) \neq \sigma (i)\) for \(j \neq i\)).
For each \(i \in [n]\), we have \(\sigma (i) = s(\sigma , i) + \ell _i(\sigma )\).
The elements \(j\) with \(\sigma (j) {\lt} \sigma (i)\) partition into those with \(j {\lt} i\) (counted by \(s(\sigma , i)\)) and those with \(j {\gt} i\) (counted by \(\ell _i\)). Their total count is \(\sigma (i)\).
For \(\sigma \in S_n\) and \(p \in [n]\):
This key formula shows that the final position after applying all Lehmer blocks to position \(p\) equals \(\sigma (p)\).
From \(\sigma (p) = s(\sigma , p) + \ell _p(\sigma )\) and \(p = s(\sigma , p) + g(\sigma , p)\), we get \(p + \ell _p(\sigma ) - g(\sigma , p) = \sigma (p)\).
For \(\sigma \in S_n\) and \(i \in [n]\):
This gives the upper bound of block \(i\)’s range in terms of the permutation value and the count of larger elements before position \(i\).
Follows from the formulas \(\sigma (i) = s(\sigma , i) + \ell _i(\sigma )\) and \(i = s(\sigma , i) + g(\sigma , i)\).
Let \(n \in \mathbb {N}\) and \(\sigma \in S_n\). For each \(i \in [n]\), set
where \(i' = i + \ell _i(\sigma )\). Then \(\sigma = a_0 a_1 \cdots a_{n-1}\).
In other words, the product of the canonical reduced word equals \(\sigma \).
We refer to [ Grinbe15 , Exercise 5.21 parts (b) and (c) ] for a detailed proof.
We prove by extensionality: for each position \(p\), we track where it ends up after applying all blocks.
By tracking position \(p\) through all blocks, the final position is
Since \(p = s(\sigma , p) + g(\sigma , p)\) and \(\sigma (p) = s(\sigma , p) + \ell _p(\sigma )\) (Lemma 3.104), we get
The canonical reduced word is indeed reduced: it is a word of length \(\ell (\sigma )\) whose product is \(\sigma \).