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.[1]: 26 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: .[1]: 26 Indeed, permutation matrices can be characterized as the orthogonal matrices whose entries are all non-negative.[2]
Let denote the set of orthogonal matrices and denote the set of element-wise non-negative matrices. Then, , where is the set of permutation matrices.