Permutations of Fin (n + 1) are equivalent to fixing a single
Fin (n + 1) and permuting the remaining with a Perm (Fin n).
The fixed Fin (n + 1) is swapped with 0.
(See also Equiv.Perm.decomposeFin' for a slightly different bijection.)
Instances For
cycleRange section #
Define the permutations Fin.cycleRange i, the cycle (0 1 2 ... i).
Fin.cycleRange i is the cycle (0 1 2 ... i) leaving (i+1 ... (n-1)) unchanged.
Instances For
The permutation cycleIcc #
In this section, we define the permutation cycleIcc i j, which is the cycle (i i+1 .... j)
leaving (0 ... i-1) and (j+1 ... n-1) unchanged when i ≤ j and returning the dummy value id
when i > j. In other words, it rotates elements in [i, j] one step to the right.
A bijection between Perm (Fin (n + 2)) and Fin (n + 2) × Perm (Fin (n + 1)).
The inverse map sends ⟨i, σ⟩ (with i : Fin (n + 2) and σ : Perm (Fin (n + 1))
to decomposeFin'Symm i σ which sends 0 to i and j.succ to i.succAbove (σ j).
(This bijection is slightly different from Equiv.Perm.decomposeFin.)