Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
Parity of a permutation
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{Short description|Property in group theory}} [[File:Symmetric group 4; permutation list.svg|thumb|Permutations of 4 elements<br><br>Odd permutations have a green or orange background. The numbers in the right column are the [[Inversion (discrete mathematics)|inversion]] numbers {{OEIS|A034968}}, which have the same [[Parity (mathematics)|parity]] as the permutation.]] In [[mathematics]], when ''X'' is a [[finite set]] with at least two elements, the [[permutation]]s of ''X'' (i.e. the [[bijective function]]s from ''X'' to ''X'') fall into two classes of equal size: the '''even permutations''' and the '''odd permutations'''. If any [[total ordering]] of ''X'' is fixed, the '''parity''' ('''oddness''' or '''evenness''') of a permutation <math>\sigma</math> of ''X'' can be defined as the parity of the number of [[inversion (discrete mathematics)|inversions]] for ''Ο'', i.e., of pairs of elements ''x'',β''y'' of ''X'' such that {{nowrap|''x'' < ''y''}} and {{nowrap|''Ο''(''x'') > ''Ο''(''y'')}}. The '''sign''', '''signature''', or '''signum''' of a permutation ''Ο'' is denoted sgn(''Ο'') and defined as +1 if ''Ο'' is even and −1 if ''Ο'' is odd. The signature defines the '''alternating [[character (mathematics)|character]]''' of the [[symmetric group]] S<sub>''n''</sub>. Another notation for the sign of a permutation is given by the more general [[Levi-Civita symbol]] (''Ξ΅''<sub>''Ο''</sub>), which is defined for all maps from ''X'' to ''X'', and has value zero for [[bijection | non-bijective maps]]. The sign of a permutation can be explicitly expressed as :{{math|1=sgn(''Ο'') = (β1)<sup>''N''(''Ο'')</sup>}}<!-- do not use <math> here. see https://bugzilla.wikimedia.org/show_bug.cgi?id=1594#c4 --> where ''N''(''Ο'') is the number of [[inversion (discrete mathematics)|inversion]]s in ''Ο''. Alternatively, the sign of a permutation ''Ο'' can be defined from its decomposition into the product of [[transposition (mathematics)|transpositions]] as :{{math|1=sgn(''Ο'') = (β1)<sup>''m''</sup>}}<!-- do not use <math> here. see https://bugzilla.wikimedia.org/show_bug.cgi?id=1594#c4 --> where ''m'' is the number of transpositions in the decomposition. Although such a decomposition is not unique, the parity of the number of transpositions in all decompositions is the same, implying that the sign of a permutation is [[well-defined]].<ref name="Jacobson">Jacobson (2009), p. 50.</ref> == Example == Consider the permutation ''Ο'' of the set {{mset|1,β2,β3,β4,β5}} defined by <math>\sigma(1) = 3,</math> <math>\sigma(2) = 4,</math> <math>\sigma(3) = 5,</math> <math>\sigma(4) = 2,</math> and <math>\sigma(5) = 1.</math> In [[one-line notation]], this permutation is denoted 34521. It can be obtained from the [[identity permutation]] 12345 by three transpositions: first exchange the numbers 2 and 4, then exchange 3 and 5, and finally exchange 1 and 3. This shows that the given permutation ''Ο'' is odd. Following the method of the [[Permutation#Cycle_notation|cycle notation]] article, this could be written, composing from right to left, as : <math>\sigma=\begin{pmatrix}1&2&3&4&5\\ 3&4&5&2&1\end{pmatrix} = \begin{pmatrix}1&3&5\end{pmatrix} \begin{pmatrix}2&4\end{pmatrix} = \begin{pmatrix}1&3\end{pmatrix} \begin{pmatrix}3&5\end{pmatrix} \begin{pmatrix}2&4\end{pmatrix} .</math> There are many other ways of writing ''Ο'' as a [[functional composition|composition]] of transpositions, for instance :{{math|1=''Ο'' = (1 5)(3 4)(2 4)(1 2)(2 3)}}, but it is impossible to write it as a product of an even number of transpositions. == Properties == The identity permutation is an even permutation.<ref name="Jacobson" /> An even permutation can be obtained as the composition of an [[even and odd numbers|even number]] (and only an even number) of exchanges (called [[transposition (mathematics)|transposition]]s) of two elements, while an odd permutation can be obtained by (only) an odd number of transpositions. The following rules follow directly from the corresponding rules about addition of integers:<ref name="Jacobson" /> * the composition of two even permutations is even * the composition of two odd permutations is even * the composition of an odd and an even permutation is odd From these it follows that * the inverse of every even permutation is even * the inverse of every odd permutation is odd Considering the [[symmetric group]] S<sub>''n''</sub> of all permutations of the set {1, ..., ''n''}, we can conclude that the map :{{math|1=sgn: S<sub>''n''</sub> β {β1, 1}β}}<!-- do not use <math> here. see https://bugzilla.wikimedia.org/show_bug.cgi?id=1594#c4 --> that assigns to every permutation its signature is a [[group homomorphism]].<ref>Rotman (1995), [{{Google books|plainurl=y|id=lYrsiaHSHKcC|page=9|text=sgn}} p. 9, Theorem 1.6.]</ref> Furthermore, we see that the even permutations form a [[subgroup]] of S<sub>''n''</sub>.<ref name="Jacobson" /> This is the [[alternating group]] on ''n'' letters, denoted by A<sub>''n''</sub>.<ref name="Jacobson_a">Jacobson (2009), p. 51.</ref> It is the [[Kernel (algebra)|kernel]] of the homomorphism sgn.<ref>Goodman, [{{Google books|plainurl=y|id=l1TKk4InOQ4C|page=116|text=kernel of the sign homomorphism}} p. 116, definition 2.4.21]</ref> The odd permutations cannot form a subgroup, since the composite of two odd permutations is even, but they form a [[coset]] of A<sub>''n''</sub> (in S<sub>''n''</sub>).<ref>Meijer & Bauer (2004), [{{Google books|plainurl=y|id=ZakN8Y7dcC8C|page=72|text=these permutations do not form a subgroup since the product of two odd permutations is even}} p. 72]</ref> If {{nowrap|''n'' > 1}}, then there are just as many even permutations in S<sub>''n''</sub> as there are odd ones;<ref name="Jacobson_a" /> consequently, A<sub>''n''</sub> contains [[factorial|''n''!]]/2 permutations. (The reason is that if ''Ο'' is even then {{nowrap|(1 β2)''Ο''}} is odd, and if ''Ο'' is odd then {{nowrap|(1 β2)''Ο''}} is even, and these two maps are inverse to each other.)<ref name="Jacobson_a" /> A [[cyclic permutation|cycle]] is even if and only if its length is odd. This follows from formulas like :<math>(a\ b\ c\ d\ e)=(d\ e)(c\ e)(b\ e)(a\ e)\text{ or }(a\ b)(b\ c)(c\ d)(d\ e).</math> In practice, in order to determine whether a given permutation is even or odd, one writes the permutation as a product of disjoint cycles. The permutation is odd if and only if this factorization contains an odd number of even-length cycles. Another method for determining whether a given permutation is even or odd is to construct the corresponding [[permutation matrix]] and compute its determinant. The value of the determinant is the same as the parity of the permutation. Every permutation of odd [[order (group theory)|order]] must be even. The permutation {{nowrap|(1 2)(3 4)}} in A<sub>4</sub> shows that the converse is not true in general. == Equivalence of the two definitions == This section presents proofs that the parity of a permutation ''σ'' can be defined in two equivalent ways: * as the parity of the number of inversions in ''σ'' (under any ordering); or * as the parity of the number of transpositions that ''σ'' can be decomposed to (however we choose to decompose it). {{hidden|header=Proof 1|content= Let ''Ο'' be a permutation on a ranked domain ''S''. Every permutation can be produced by a sequence of [[Transposition (mathematics)|transpositions]] (2-element exchanges). Let the following be one such decomposition :''Ο'' = ''T''<sub>1</sub> ''T''<sub>2</sub> ... ''T''<sub>''k''</sub> We want to show that the parity of ''k'' is equal to the parity of the number of inversions of ''Ο''. Every transposition can be written as a product of an odd number of transpositions of adjacent elements, e.g. :(2β5) = (2β3)β(3β4)β(4β5)β(4β3)β(3β2). Generally, we can write the transposition (''i'' ''i+d'') on the set {1,...,''i'',...,''i+d'',...} as the composition of 2''d''β1 adjacent transpositions by recursion on ''d'': * The base case ''d=1'' is trivial. * In the recursive case, first rewrite (''i'', ''i+d'') as (''i'', ''i''+1) (''i''+1, ''i+d'') (''i'', ''i''+1). Then recursively rewrite (''i''+1, ''i+d'') as adjacent transpositions. If we decompose in this way each of the transpositions ''T''<sub>1</sub> ... ''T''<sub>''k''</sub> above, we get the new decomposition: :''Ο'' = ''A''<sub>1</sub> ''A''<sub>2</sub> ... ''A<sub>m</sub>'' where all of the ''A''<sub>1</sub>...''A<sub>m</sub>'' are adjacent. Also, the parity of ''m'' is the same as that of ''k''. This is a fact: for all permutation ''Ο'' and adjacent transposition ''a,'' ''aΟ'' either has one less or one more inversion than ''Ο''. In other words, the parity of the number of inversions of a permutation is switched when composed with an adjacent transposition. Therefore, the parity of the number of inversions of ''Ο'' is precisely the parity of ''m'', which is also the parity of ''k''. This is what we set out to prove. We can thus define the parity of ''Ο'' to be that of its number of constituent transpositions in any decomposition. And this must agree with the parity of the number of inversions under any ordering, as seen above. Therefore, the definitions are indeed well-defined and equivalent. }} {{hidden|header=Proof 2|content= An alternative proof uses the [[Vandermonde polynomial]] :<math>P(x_1,\ldots,x_n)=\prod_{i<j} (x_i - x_j).</math> So for instance in the case {{nowrap|1=''n'' = 3}}, we have :<math>P(x_1, x_2, x_3) = (x_1 - x_2)(x_2 - x_3)(x_1 - x_3).</math> Now for a given permutation ''Ο'' of the numbers {1,β...,β''n''}, we define :<math>\sgn(\sigma)=\frac{P(x_{\sigma(1)},\ldots,x_{\sigma(n)})}{P(x_1,\ldots,x_n)}.</math> Since the polynomial <math>P(x_{\sigma(1)},\dots,x_{\sigma(n)})</math> has the same factors as <math>P(x_1,\dots,x_n)</math> except for their signs, it follows that sgn(''Ο'') is either +1 or −1. Furthermore, if ''Ο'' and ''Ο'' are two permutations, we see that : <math> \begin{align} \sgn(\sigma\tau) & = \frac{P(x_{\sigma(\tau(1))},\ldots,x_{\sigma(\tau(n))})}{P(x_1,\ldots,x_n)} \\[4pt] & = \frac{P(x_{\sigma(1)},\ldots,x_{\sigma(n)})}{P(x_1,\ldots,x_n)} \cdot \frac{P(x_{\sigma(\tau(1))},\ldots, x_{\sigma(\tau(n))})}{P(x_{\sigma(1)},\ldots,x_{\sigma(n)})} \\[4pt] & = \sgn(\sigma)\cdot\sgn(\tau). \end{align} </math> It can be shown that any transposition of two elements has signature −1, and thus we do indeed recover the signature as defined earlier. }} {{hidden|header=Proof 3|content= A third approach uses the [[presentation of a group|presentation]] of the group S<sub>''n''</sub> in terms of generators ''Ο''<sub>1</sub>, ..., ''Ο''<sub>''n''−1</sub> and relations * <math>\tau_i^2 = 1</math> for all ''i'' * <math>\tau_i^{}\tau_{i+1}\tau_i = \tau_{i+1}\tau_i\tau_{i+1}</math> for all ''i'' < ''n'' − 1 * <math>\tau_i^{}\tau_j = \tau_j\tau_i</math> if <math>|i- j| \geq 2.</math> [Here the generator <math>\tau_i</math> represents the transposition {{nowrap|(''i'', ''i'' + 1)}}.] All relations keep the length of a word the same or change it by two. Starting with an even-length word will thus always result in an even-length word after using the relations, and similarly for odd-length words. It is therefore unambiguous to call the elements of S<sub>''n''</sub> represented by even-length words "even", and the elements represented by odd-length words "odd". }} {{hidden|header=Proof 4|content= Recall that a pair ''x'', ''y'' such that {{nowrap|''x'' < ''y''}} and {{nowrap|''Ο''(''x'') > ''Ο''(''y'')}} is called an inversion. We want to show that the count of inversions has the same parity as the count of 2-element swaps. To do that, we can show that every swap changes the parity of the count of inversions, no matter which two elements are being swapped and what permutation has already been applied. Suppose we want to swap the ''i''th and the ''j''th element. Clearly, inversions formed by ''i'' or ''j'' with an element outside of {{nowrap|[''i'', ''j'']}} will not be affected. For the {{nowrap|1=''n'' = ''j'' − ''i'' − 1}} elements within the interval {{nowrap|(''i'', ''j'')}}, assume ''v''<sub>''i''</sub> of them form inversions with ''i'' and ''v''<sub>''j''</sub> of them form inversions with ''j''. If ''i'' and ''j'' are swapped, those ''v''<sub>''i''</sub> inversions with ''i'' are gone, but {{nowrap|''n'' − ''v''<sub>''i''</sub>}} inversions are formed. The count of inversions ''i'' gained is thus {{nowrap|''n'' − 2''v''<sub>''i''</sub>}}, which has the same parity as ''n''. Similarly, the count of inversions ''j'' gained also has the same parity as ''n''. Therefore, the count of inversions gained by both combined has the same parity as 2''n'' or 0. Now if we count the inversions gained (or lost) by swapping the ''i''th and the ''j''th element, we can see that this swap changes the parity of the count of inversions, since we also add (or subtract) 1 to the number of inversions gained (or lost) for the pair ''(i,j)''. Note that initially when no swap is applied, the count of inversions is 0. Now we obtain equivalence of the two definitions of parity of a permutation. }} {{hidden|header=Proof 5|content= Consider the elements that are sandwiched by the two elements of a transposition. Each one lies completely above, completely below, or in between the two transposition elements. An element that is either completely above or completely below contributes nothing to the inversion count when the transposition is applied. Elements in-between contribute <math>2</math>. As the transposition itself supplies <math>\pm1</math> inversion, and all others supply 0 (mod 2) inversions, a transposition changes the parity of the number of inversions. }} == Other definitions and proofs == The parity of a permutation of <math>n</math> points is also encoded in its [[cyclic permutation|cycle structure]]. Let ''Ο'' = (''i''<sub>1</sub> ''i''<sub>2</sub> ... ''i''<sub>''r''+1</sub>)(''j''<sub>1</sub> ''j''<sub>2</sub> ... ''j''<sub>''s''+1</sub>)...(''β''<sub>1</sub> ''β''<sub>2</sub> ... ''β''<sub>''u''+1</sub>) be the unique [[cycle notation|decomposition of ''Ο'' into disjoint cycles]], which can be composed in any order because they commute. A cycle {{nowrap|(''a'' ''b'' ''c'' ... ''x'' ''y'' ''z'')}} involving {{nowrap|''k'' + 1}} points can always be obtained by composing ''k'' transpositions (2-cycles): :<math>(a\ b\ c \dots x\ y\ z)=(a\ b)(b\ c) \dots (x\ y)(y\ z),</math> so call ''k'' the ''size'' of the cycle, and observe that, under this definition, transpositions are cycles of size 1. From a decomposition into ''m'' disjoint cycles we can obtain a decomposition of ''Ο'' into {{nowrap|''k''<sub>1</sub> + ''k''<sub>2</sub> + ... + ''k''<sub>''m''</sub>}} transpositions, where ''k''<sub>''i''</sub> is the size of the ''i''th cycle. The number {{nowrap|1=''N''(''Ο'') = ''k''<sub>1</sub> + ''k''<sub>2</sub> + ... + ''k''<sub>''m''</sub>}} is called the discriminant of ''Ο'', and can also be computed as :<math>n \text{ minus the number of disjoint cycles in the decomposition of } \sigma</math> if we take care to include the fixed points of ''Ο'' as 1-cycles. Suppose a transposition (''a'' ''b'') is applied after a permutation ''Ο''. When ''a'' and ''b'' are in different cycles of ''Ο'' then :<math>(a\ b)(a\ c_1\ c_2 \dots c_r)(b\ d_1\ d_2 \dots d_s) = (a\ c_1\ c_2 \dots c_r\ b\ d_1\ d_2 \dots d_s)</math>, and if ''a'' and ''b'' are in the same cycle of ''Ο'' then :<math>(a\ b)(a c_1 c_2 \dots c_r\ b\ d_1\ d_2 \dots d_s) = (a\ c_1\ c_2 \dots c_r)(b\ d_1\ d_2 \dots d_s)</math>. In either case, it can be seen that {{nowrap|1=''N''((''a'' ''b'')''Ο'') = ''N''(''Ο'') Β± 1}}, so the parity of ''N''((''a'' ''b'')''Ο'') will be different from the parity of ''N''(''Ο''). If {{nowrap|1=''Ο'' = ''t''<sub>1</sub>''t''<sub>2</sub> ... ''t''<sub>''r''</sub>}} is an arbitrary decomposition of a permutation ''Ο'' into transpositions, by applying the ''r'' transpositions <math>t_1</math> after ''t''<sub>2</sub> after ... after ''t''<sub>''r''</sub> after the identity (whose ''N'' is zero) observe that ''N''(''Ο'') and ''r'' have the same parity. By defining the parity of ''Ο'' as the parity of ''N''(''Ο''), a permutation that has an even length decomposition is an even permutation and a permutation that has one odd length decomposition is an odd permutation. ; Remarks: * A careful examination of the above argument shows that {{nowrap|''r'' β₯ ''N''(''Ο'')}}, and since any decomposition of ''Ο'' into cycles whose sizes sum to ''r'' can be expressed as a composition of ''r'' transpositions, the number ''N''(''Ο'') is the minimum possible sum of the sizes of the cycles in a decomposition of ''Ο'', including the cases in which all cycles are transpositions. * This proof does not introduce a (possibly arbitrary) order into the set of points on which ''Ο'' acts. == Generalizations == Parity can be generalized to [[Coxeter group]]s: one defines a [[length function]] β(''v''), which depends on a choice of generators (for the symmetric group, [[adjacent transposition]]s), and then the function {{nowrap|''v'' β¦ (−1)<sup>β(''v'')</sup>}} gives a generalized sign map. == See also == * The [[fifteen puzzle]] is a classic application * [[Zolotarev's lemma]] == Notes == {{Reflist}} ==References== * {{MathWorld|urlname=EvenPermutation|title=Even Permutation}} * {{Cite book| last=Jacobson| first=Nathan| author-link=Nathan Jacobson| year=2009| title=Basic algebra| edition=2nd| volume = 1 | publisher=Dover| isbn = 978-0-486-47189-1}} * {{cite book |last1=Rotman |first1=J.J. |title=An introduction to the theory of groups |series=Graduate texts in mathematics |year=1995 |publisher=Springer-Verlag |isbn=978-0-387-94285-8 }} * {{cite book |last1=Goodman |first1=Frederick M. |title=Algebra: Abstract and Concrete |publisher=Frederick M. Goodman. |isbn=978-0-9799142-0-1 }} * {{cite book |last1=Meijer |first1=Paul Herman Ernst |last2=Bauer |first2=Edmond |title=Group theory: the application to quantum mechanics |series=Dover classics of science and mathematics |year=2004 |publisher=Dover Publications |isbn=978-0-486-43798-9 }} [[Category:Group theory]] [[Category:Permutations]] [[Category:Parity (mathematics)]] [[Category:Articles containing proofs]] [[Category:Sign (mathematics)]] [[ru:ΠΠ΅ΡΠ΅ΡΡΠ°Π½ΠΎΠ²ΠΊΠ°#Π‘Π²ΡΠ·Π°Π½Π½ΡΠ΅ ΠΎΠΏΡΠ΅Π΄Π΅Π»Π΅Π½ΠΈΡ]]
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Templates used on this page:
Template:Cite book
(
edit
)
Template:Google books
(
edit
)
Template:Hidden
(
edit
)
Template:Math
(
edit
)
Template:MathWorld
(
edit
)
Template:Mset
(
edit
)
Template:Nowrap
(
edit
)
Template:OEIS
(
edit
)
Template:Reflist
(
edit
)
Template:Short description
(
edit
)
Search
Search
Editing
Parity of a permutation
Add topic