GroupTheory
PermApply
apply a permutation to a point
PermAltSplit
check for a permutation whose conjugacy class splits in the alternating group
PermDegree
compute the degree of a permutation
PermOrder
compute the order of a permutation
PermParity
compute the parity of a permutation
PermProduct
compute the product of two permutations
PermInverse
compute the inverse of a permutation
PermIsInvolution
check for an involution
PermPower
compute the power of a permutation
PermLeftQuotient
compute the left quotient of two permutations
PermRightQuotient
compute the right quotient of two permutations
PermConjugate
compute the conjugate of two permutations
PermCommutator
compute the commutator of two permutations
PermCycleType
compute the cycle type of a permutation
PermFixed
compute the set of fixed points of a permutation
PermRestrict
compute the restriction of a permutation to a stable subset of its support
PermShift
shift the support of a permutation by a fixed quantity
PermSupport
compute the support of a permutation
PermMinSupport
compute the least point moved by permutation
PermMaxSupport
compute the largest point moved by permutation
PermCompare
compare two permutations
PermRandom
generate a random permutation
Calling Sequence
Parameters
Description
Examples
Compatibility
PermApply( n, p )
PermDegree( p )
PermOrder( p )
PermIsInvolution( p )
PermParity( p )
PermProduct( p, q )
PermInverse( p )
PermPower( p, n )
PermLeftQuotient( p, q )
PermRightQuotient( p, q )
PermConjugate( p, q )
PermCommutator( p, q )
PermCycleType( p )
PermFixed( p )
PermSupport( p )
PermMinSupport( p )
PermMaxSupport( p )
PermRestrict( p, dom )
PermShift( p, n )
PermCompare( p, q )
PermAltSplit( p )
PermRandom( n )
PermRandom( n, exact )
p, q
-
Perm : permutations
n
integer : an integer
dom
{set,list}(posint) : set or list of positive integers
A permutation is a bijective mapping from the set1,2,…,n to itself, for some positive integer n.
The set of all such permutations forms the symmetric group of degree n, and subgroups of symmetric groups are permutation groups.
Permutations are typically represented as products of disjoint cycles, each of which is an orbit of the permutation. This is a list of the formc1,c2,…,ck in which each ci is itself a listi1,i2,…,im representing a cycle of the formi1↦i2↦im↦i1 .
The Perm constructor creates a permutation, given a specification of its disjoint cycle structure in the form of a list of lists. You can also use a permutation list, which is just the representation of the permutation as a list L of points in which L[ i ] specifies the image of i under the permutation.
The image of a point i under a permutation p is returned by the indexed expression p[ i ]. You can also use the procedure PermApply for this purpose. The expression PermApply( p, i ) returns the image of i under the permutation p. The PermApply command is primarily intended for use with procedures such as map and map2.
The procedures described in this help page operate on permutation objects returned by the Perm constructor, and are part of the GroupTheory package (whereas Perm itself is global).
The degree of a permutation is the number of points upon which it acts. The PermDegree( p ) command returns the degree of the permutation p.
The product of two permutations a and b can be computed by using the PermProduct( a, b ) command. Note that permutation multiplication is non-commutative; that is, in general, PermProduct( a, b ) and PermProduct( b, a ) are different. You can also compute the product of the permutations a and b by using the non-commutative multiplication operator `.`, as a . b.
The inverse of the permutation p is computed using the command PermInverse( p ). It can also be computed using the syntax p^(-1).
An integral power of a permutation p is computed using the command PermPower( p, n ), which computes the n-th power of p, defined in the natural way. You can also use the syntax p^n.
The PermOrder( p ) command computes the order of a permutation p. That is the least positive integer k for which p^k is the identity.
The identity permutation can be constructed using the expression Perm( [] ).
Every permutation can be written as a product of transpositions, permutations which interchange exactly two points. Although this factorization is not unique, the number of transpositions in such a product is either always even or always odd. A permutation is said to be even (respectively, odd) according to whether is has a decomposition as a product of an even (respectively, odd) number of transpositions. An even permutation is defined to have parity equal to 1, while an odd permutation is defined to have parity equal to −1. (This defines a homomorphism from the full symmetric group onto the multiplicative group −1,1, whose kernel, consisting of the even permutations, is the alternating group.) The parity of a permutation p is returned by the PermParity( p ) command.
A transposition is a particular example of an involution, that is, an element of order 2. An involution is its own inverse. The PermIsInvolution( p ) command returns true if the permutation p is an involution, and false otherwise.
The left quotient p-1˙q of permutations p and q is computed using the PermLeftQuotient( p, q ) command. Similarly, the command PermRightQuotient( p, q ) computes the right quotient p˙q-1 of p and q.
The conjugate pq of p by q is defined to be p-1˙q˙p and may be computed by the PermConjugate( p, q ) command. The syntax p^q is also available for this computation.
The commutator of permutations p and q is defined to be the permutation p-1˙q-1˙p˙q and is computed using the command PermCommutator( p, q ).
The PermCycleType( p ) command returns the cycle type of the permutation p. This is defined to be the list consisting of the lengths of the cycles of p, in sorted order.
A point i is fixed by a permutation p if ip=i; its complement (in the domain of the permutation) is called the support of p. The set of fixed points of a permutation p is returned by the command PermFixed( p ), and the support of p is returned by the command PermSupport( p ). The smallest positive integer in the support of p is returned by the command PermMinSupport( p ), while the command PermMaxSupport( p ) returns the largest member of the support of p.
If an invariant subset dom of a permutation p exists (i.e., a union of cycles of p), then the restriction of p to dom is a permutation that can be computed by using the PermRestrict( p, dom ) command.
The PermShift( p, n ) command returns a permutation conjugate to p but acting on the result of adding the integer n to each point of the support of p, provided that the result is a set of positive integers.
The conjugacy class of an even permutation p in the symmetric group to which it belongs may or may not split into two conjugacy classes in the alternating group. The PermAltSplit( p ) command returns the value true if this happens, and returns the value false otherwise.
The PermCompare( a, b ) command compares two permutations a and b, according to the lexicographic plus degree ordering. The PermCompare command is intended for use as the second argument in a a call to sort on a list of permutations.
To generate a random permutation of degree n, use the PermRandom( n ) command. Because the resulting permutation p is randomly produced, the degree of p will be at most n, but may not be exactly n. To ensure that the resulting permutation p has degree exactly equal to n, use the exact = true (or just exact) option.
a≔Perm⁡1,2,3,4,5
a≔1,23,4,5
a1
2
a2
1
a3
4
a4
5
a5
3
b≔Perm⁡1,3,2,6
b≔1,32,6
with⁡GroupTheory:
PermApply⁡a,2
PermDegree⁡a
PermDegree⁡b
6
PermProduct⁡a,b
1,6,2,3,4,5
a·b
PermProduct⁡b,a
1,4,5,3,2,6
PermLeftQuotient⁡a,b
1,6,2,3,5,4
a−1·b
PermRightQuotient⁡a,b
a·b−1
PermPower⁡a,10
3,4,5
a10
PermConjugate⁡a,b
1,4,53,6
ab
PermCommutator⁡a,b
1,2,4,6,3
PermParity⁡a
−1
PermParity⁡b
PermOrder⁡a
PermOrder⁡b
evalb⁡b·b=Perm⁡
true
PermInverse⁡a
1,23,5,4
PermInverse⁡b
1,32,6
PermIsInvolution⁡b
PermCycleType⁡a
2,3
PermCycleType⁡b
2,2
PermSupport⁡a
1,2,3,4,5
PermSupport⁡b
1,2,3,6
PermMinSupport⁡b
PermMaxSupport⁡b
c≔PermRestrict⁡b,2,6
c≔2,6
PermShift⁡c,−1
1,5
PermShift⁡c,3000
3002,3006
A shift value of −3 is not valid in the following example, since the result of shifting by −3 would result in a non-negative integer point.
PermShift⁡c,−3
Error, (in Perm:-extShift) invalid shift value -3
PermFixed⁡b
4,5
a≔Perm⁡1,2,3;b≔Perm⁡1,2;c≔Perm⁡1,2,3,4,5
a≔1,2,3
b≔1,2
c≔1,2,34,5
PermCompare⁡a,b
false
PermCompare⁡a,c
sort⁡a,b,c,PermCompare
1,2,1,2,3,1,2,34,5
p≔PermRandom⁡12
p≔1,9,11,3,7,6,12,10,2,5,4
p≔PermRandom⁡12,exact
p≔2,10,11,5,3,12,4,7,8,6,9
PermDegree⁡p
12
The GroupTheory[PermApply], GroupTheory[PermAltSplit], GroupTheory[PermDegree], GroupTheory[PermOrder], GroupTheory[PermParity], GroupTheory[PermProduct], GroupTheory[PermInverse], GroupTheory[PermIsInvolution], GroupTheory[PermPower], GroupTheory[PermLeftQuotient], GroupTheory[PermRightQuotient], GroupTheory[PermConjugate], GroupTheory[PermCommutator], GroupTheory[PermCycleType], GroupTheory[PermFixed], GroupTheory[PermRestrict], GroupTheory[PermShift], GroupTheory[PermSupport], GroupTheory[PermMinSupport], GroupTheory[PermMaxSupport] and GroupTheory[PermRandom] commands were introduced in Maple 17.
For more information on Maple 17 changes, see Updates in Maple 17.
The GroupTheory[PermCompare] command was introduced in Maple 2017.
For more information on Maple 2017 changes, see Updates in Maple 2017.
See Also
Perm
Download Help Document