In linear algebra, a Permutation matrix is a matrix that has exactly one 1 in each row or column and 0s elsewhere. Permutation matrices are the matrix representation of permutations.
For example, the permutation matrix corresponding to σ=(1)(2 4 5 3) is
and
In general, for a permutation σ on n objects, the correponding permutation matrix is an n-by-n matrix Pσ is given by Pσ[i,j]=1 if i=σ(j) and 0 otherwise. We have
Properties:
See also generalized permutation matrix.
1 & 0 & 0 & 0 & 0 \\
0 & 0 & 0 & 1 & 0 \\
0 & 1 & 0 & 0 & 0 \\
0 & 0 & 0 & 0 & 1 \\
0 & 0 & 1 & 0 & 0 \end{bmatrix}</math>
=\begin{bmatrix}g_1\\g_4\\g_2\\g_5\\g_3\end{bmatrix}.</math>
=\begin{bmatrix}g_{\sigma(1)}\\ \vdots\\ g_{\sigma(n)}\end{bmatrix}</math>.