Content deleted Content added
m Add link to "Permutation matrix". |
Point out that place-based vs value-based notation can be seen by which value of the ordered pair is smaller. Also reword and reorder of paragraphs. |
||
Line 9:
===Inversion===
Let <math>\pi</math> be a [[permutation]].
The '''inversion set''' is the set of all inversions. A permutation's inversion set according to the place-based
The inversion is usually defined for permutations, but may also be defined for sequences:<br>Let <math>S</math> be a [[sequence]] (or [[multiset]] permutation{{sfn|Bóna|2012|pp=57}}). If <math>i < j</math> and <math>S(i) > S(j)</math>, either the pair of places <math>(i, j)</math>{{sfn|Bóna|2012|pp=57}}{{sfn|Cormen|Leiserson|Rivest|Stein|2001|pp=39}} or the pair of elements <math>\bigl(S(i), S(j)\bigr)</math>{{sfn|Barth|Mutzel|2004|pp=183}} is called an inversion of <math>S</math>.▼
▲
For sequences, inversions according to the element-based definition are not unique, because different pairs of places may have the same pair of values.▼
▲For sequences, inversions according to the element-based definition are not unique, because different pairs of places may have the same pair of values.
▲The '''inversion set''' is the set of all inversions. A permutation's inversion set according to the place-based definition is that of the [[Permutation#Product and inverse|inverse]] permutation's inversion set according to the element-based definition, and vice versa,{{sfn|Gratzer|2016|pp=221}} just with the elements of the pairs exchanged.
===Inversion number===
|