Even Permutation

Author

Eric W. Weisstein
October 10, 2005

This notebook downloaded from http://mathworld.wolfram.com/notebooks/Combinatorics/EvenPermutation.nb.

For more information, see Eric's MathWorld entry http://mathworld.wolfram.com/EvenPermutation.html.

©2005 Wolfram Research, Inc. except for portions noted otherwise

Definition

EvenPermutationQ[p_]:=(Signature[p]==1)
OddPermutationQ[p_]:=(Signature[p]==-1)

Example

Select[Permutations[Range[4]],EvenPermutationQ]

Length[%]

Counts

Even

Table[Count[Signature/@Permutations[Range[n]],-1],{n,9}]//Timing

Table[n!/2,{n,9}]

Odd

Table[Count[Signature/@Permutations[Range[n]],1],{n,9}]//Timing

Table[n!/2,{n,9}]