PermApply - Maple Help

GroupTheory

 PermApply
 apply a permutation to a point
 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
 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
 PermSupport
 compute the support of a permutation
 PermCompare
 compare two permutations

 Calling Sequence 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 ) PermRestrict( p, dom ) PermShift( p, n ) PermCompare( p, q ) PermAltSplit( p )

Parameters

 p, q - Perm : permutations n - integer : an integer dom - {set,list}(posint) : set or list of positive integers

Description

 • A permutation is a bijective mapping from the set$\left\{1,2,\dots ,n\right\}$ 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 form$\left[{c}_{1},{c}_{2},\dots ,{c}_{k}\right]$ in which each ${c}_{i}$ is itself a list$\left[{i}_{1},{i}_{2},\dots ,{i}_{m}\right]$ representing a cycle of the form${i}_{1}↦{i}_{2}↦{i}_{m}↦{i}_{1}$ .
 • 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 $\left\{-1,1\right\}$, whose kernel, consisting of the even permutations, is the alternating group.) The parity of a permutation p is returned by the PermParity( p ) command.
 • 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 ${p}^{q}$ 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 ${i}^{p}=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 ).
 • 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.

Examples

 > $a≔\mathrm{Perm}\left(\left[\left[1,2\right],\left[3,4,5\right]\right]\right)$
 ${a}{≔}\left({1}{,}{2}\right)\left({3}{,}{4}{,}{5}\right)$ (1)
 > $a\left[1\right]$
 ${2}$ (2)
 > $a\left[2\right]$
 ${1}$ (3)
 > $a\left[3\right]$
 ${4}$ (4)
 > $a\left[4\right]$
 ${5}$ (5)
 > $a\left[5\right]$
 ${3}$ (6)
 > $b≔\mathrm{Perm}\left(\left[\left[1,3\right],\left[2,6\right]\right]\right)$
 ${b}{≔}\left({1}{,}{3}\right)\left({2}{,}{6}\right)$ (7)
 > $\mathrm{with}\left(\mathrm{GroupTheory}\right):$
 > $\mathrm{PermApply}\left(a,2\right)$
 ${1}$ (8)
 > $\mathrm{PermDegree}\left(a\right)$
 ${5}$ (9)
 > $\mathrm{PermDegree}\left(b\right)$
 ${6}$ (10)
 > $\mathrm{PermProduct}\left(a,b\right)$
 $\left({1}{,}{6}{,}{2}{,}{3}{,}{4}{,}{5}\right)$ (11)
 > $a·b$
 $\left({1}{,}{6}{,}{2}{,}{3}{,}{4}{,}{5}\right)$ (12)
 > $\mathrm{PermProduct}\left(b,a\right)$
 $\left({1}{,}{4}{,}{5}{,}{3}{,}{2}{,}{6}\right)$ (13)
 > $\mathrm{PermLeftQuotient}\left(a,b\right)$
 $\left({1}{,}{6}{,}{2}{,}{3}{,}{5}{,}{4}\right)$ (14)
 > ${a}^{-1}·b$
 $\left({1}{,}{6}{,}{2}{,}{3}{,}{5}{,}{4}\right)$ (15)
 > $\mathrm{PermRightQuotient}\left(a,b\right)$
 $\left({1}{,}{6}{,}{2}{,}{3}{,}{4}{,}{5}\right)$ (16)
 > $a·{b}^{-1}$
 $\left({1}{,}{6}{,}{2}{,}{3}{,}{4}{,}{5}\right)$ (17)
 > $\mathrm{PermPower}\left(a,10\right)$
 $\left({3}{,}{4}{,}{5}\right)$ (18)
 > ${a}^{10}$
 $\left({3}{,}{4}{,}{5}\right)$ (19)
 > $\mathrm{PermConjugate}\left(a,b\right)$
 $\left({1}{,}{4}{,}{5}\right)\left({3}{,}{6}\right)$ (20)
 > ${a}^{b}$
 $\left({1}{,}{4}{,}{5}\right)\left({3}{,}{6}\right)$ (21)
 > $\mathrm{PermCommutator}\left(a,b\right)$
 $\left({1}{,}{2}{,}{4}{,}{6}{,}{3}\right)$ (22)
 > $\mathrm{PermParity}\left(a\right)$
 ${-1}$ (23)
 > $\mathrm{PermParity}\left(b\right)$
 ${1}$ (24)
 > $\mathrm{PermOrder}\left(a\right)$
 ${6}$ (25)
 > $\mathrm{PermOrder}\left(b\right)$
 ${2}$ (26)
 > $\mathrm{evalb}\left(b·b=\mathrm{Perm}\left(\left[\right]\right)\right)$
 ${\mathrm{true}}$ (27)
 > $\mathrm{PermInverse}\left(a\right)$
 $\left({1}{,}{2}\right)\left({3}{,}{5}{,}{4}\right)$ (28)
 > $\mathrm{PermInverse}\left(b\right)$
 $\left({1}{,}{3}\right)\left({2}{,}{6}\right)$ (29)
 > $\mathrm{PermCycleType}\left(a\right)$
 $\left[{2}{,}{3}\right]$ (30)
 > $\mathrm{PermCycleType}\left(b\right)$
 $\left[{2}{,}{2}\right]$ (31)
 > $\mathrm{PermSupport}\left(a\right)$
 $\left\{{1}{,}{2}{,}{3}{,}{4}{,}{5}\right\}$ (32)
 > $\mathrm{PermSupport}\left(b\right)$
 $\left\{{1}{,}{2}{,}{3}{,}{6}\right\}$ (33)
 > $c≔\mathrm{PermRestrict}\left(b,\left\{2,6\right\}\right)$
 ${c}{≔}\left({2}{,}{6}\right)$ (34)
 > $\mathrm{PermShift}\left(c,-1\right)$
 $\left({1}{,}{5}\right)$ (35)
 > $\mathrm{PermShift}\left(c,3000\right)$
 $\left({3002}{,}{3006}\right)$ (36)
 > $\mathrm{PermShift}\left(c,-3\right)$
 > $\mathrm{PermFixed}\left(b\right)$
 $\left\{{4}{,}{5}\right\}$ (37)
 > $a≔\mathrm{Perm}\left(\left[\left[1,2,3\right]\right]\right);$$b≔\mathrm{Perm}\left(\left[\left[1,2\right]\right]\right);$$c≔\mathrm{Perm}\left(\left[\left[1,2,3\right],\left[4,5\right]\right]\right)$
 ${a}{≔}\left({1}{,}{2}{,}{3}\right)$
 ${b}{≔}\left({1}{,}{2}\right)$
 ${c}{≔}\left({1}{,}{2}{,}{3}\right)\left({4}{,}{5}\right)$ (38)
 > $\mathrm{PermCompare}\left(a,b\right)$
 ${\mathrm{false}}$ (39)
 > $\mathrm{PermCompare}\left(a,c\right)$
 ${\mathrm{true}}$ (40)
 > $\mathrm{sort}\left(\left[a,b,c\right],\mathrm{PermCompare}\right)$
 $\left[\left({1}{,}{2}\right){,}\left({1}{,}{2}{,}{3}\right){,}\left({1}{,}{2}{,}{3}\right)\left({4}{,}{5}\right)\right]$ (41)

Compatibility

 • The GroupTheory[PermApply], GroupTheory[PermDegree], GroupTheory[PermOrder], GroupTheory[PermParity], GroupTheory[PermProduct], GroupTheory[PermInverse], GroupTheory[PermPower], GroupTheory[PermLeftQuotient], GroupTheory[PermRightQuotient], GroupTheory[PermConjugate], GroupTheory[PermCommutator], GroupTheory[PermCycleType], GroupTheory[PermFixed] and GroupTheory[PermSupport] commands were introduced in Maple 17.