% $Date: 2003/09/15 16:37:45 $ $Author: nthiery $ $Revision: 1.1.1.1 $

\begin{Mhelppage}{Vect2Perm}%
  {V. Prosper}%
  \begin{MInfo}
    \eng{computes a canonical permutation from a vector}
  \end{MInfo}
  

\begin{MCalls}
\Mcall{l}
\end{MCalls}

\begin{MParameters}
  \param{l}
  \eng{any list of positive integers} 
\end{MParameters}

\begin{MIntro}
  \eng{
The {\Mthis} function calculates a canonical permutation from the  list
\Mex{l}, having as cycle type, the reordering of \Mex{l}.
 
Let \Mex{l=[3, 2, 4]}, \Mex{\Mthis(l)} gives a permutation in
\Mmath{S3 x S2 x S4}{S_3\times S_2\times S_4}  which
is a direct product of cycles of length 3, 2, 4.
}
\end{MIntro}

\begin{MExample}{ex1}
\begin{Mexin}
muEC::SG::Vect2Perm( [3,1,4,1] );
\end{Mexin}
\begin{Mexout}
                  [3, 1, 2, 4, 8, 5, 6, 7, 9]
\end{Mexout}
\end{MExample}

\MRelatedFunctions{Cycle2Perm,Perm2Cycle,Perm2CycleType}
\end{Mhelppage}
