In mathematics, particularly in matrix theory, a permutation matrix is a square binary matrix that has exactly one entry of 1 in each row and each column with all other entries 0. An n × n permutation matrix can represent a permutation of n elements. Pre-multiplying an n-row matrix M by a permutation matrix P, forming PM, results in permuting the rows of M, while post-multiplying an n-column matrix M, forming MP, permutes the columns of M. Every permutation matrix P is orthogonal, with its inverse equal to its transpose: P − 1 = P T {\displaystyle P^{-1}=P^{\mathsf {T}}} . Indeed, permutation matrices can be characterized as the orthogonal matrices whose entries are all non-negative.
The two permutation/matrix correspondences There are two natural one-to-one correspondences between permutations and permutation matrices, one of which works along the rows of the matrix, the other along its columns. Here is an example, starting with a permutation π in two-line form at the upper left:
… excerpt ends here. Continue reading the full article.
