5.2. PermToInv

This function uses the stored tables of results to identify the index corresponding to a given canonical permutation.

Example:

In[97]:=

PermToInv[rperm]

Out[97]=

6 D_00,2 + I_00,2

This function only works with canonical permutations:  

In[98]:=

InvToPerm[RInv[metric][{0, 2}, 3]]

Out[98]=

RPerm[metric][{{0, 2}, 0}, Cycles[{2, 3}, {4, 5}, {6, 7, 8, 9}]]

In[99]:=

PermToInv[%]

Out[99]=

I_02,3

We rewrite the cycles in a different form

In[100]:=

RPerm[metric][{{0, 2}, 0}, Cycles[{3, 2}, {4, 5}, {6, 7, 8, 9}]]

Out[100]=

RPerm[metric][{{0, 2}, 0}, Cycles[{3, 2}, {4, 5}, {6, 7, 8, 9}]]

but now PermToInv does not work, because the new permutation is not canonical

In[101]:=

PermToInv[%]

Out[101]=

Cycles[{3, 2}, {4, 5}, {6, 7, 8, 9}]


Created by Mathematica  (May 16, 2008) Valid XHTML 1.1!