Permutation matrices can be used to rearrange the rows or columns of a matrix. A permutation matrix is a square matrix with ones in exactly one position of each row and column and zeros elsewhere. Multiplying a matrix A on the left by a permutation matrix P rearranges the rows of A, while multiplying A on the right by P rearranges the columns. The position of the one in each row/column of P determines which row/column of A will be moved.