PermutationList

PermutationList[perm]

returns a permutation list representation of permutation perm.

PermutationList[perm,len]

returns a permutation list of length len.

Details

  • The input permutation perm can be given as a permutation list or in disjoint cyclic form.
  • For cyclic input Cycles[{cyc1,cyc2,}] the cycles cyci must be lists of positive integers representing the points of the domain in which the permutation perm acts. The cycles must have no common points.
  • PermutationList returns a permutation list that is a reordering of the consecutive integers {1,2,,len}. By default the length len is the largest integer present in the input perm.
  • For an input cycle {p1,p2,,pm} the resulting permutation list has point pi+1 at position pi and p1 at position pm.
  • PermutationList also works with SparseArray objects.

Examples

open allclose all

Basic Examples  (2)

Convert permutation cycles to a permutation list:

In[1]:=
Click for copyable input
Out[1]=

Explicit length specification:

In[1]:=
Click for copyable input
Out[1]=

Scope  (3)

Properties & Relations  (3)

Possible Issues  (2)

Neat Examples  (1)

See Also

Cycles  PermutationCycles  PermutationListQ

Tutorials

Related Demonstrations

Introduced in 2010
(8.0)
| Updated in 2012
(9.0)