In mathematics, a generalized permutation matrix (or monomial matrix) is a matrix with the same nonzero pattern as a permutation matrix, i.e. there is exactly one nonzero entry in each row and each column. Unlike a permutation matrix, where the nonzero entry must be 1, in a generalized permutation matrix the nonzero entry can be any nonzero value. An example of a generalized permutation matrix is Structure An invertible matrix A is a generalized permutation matrix if and only if it can be written as a product of an invertible diagonal matrix D and an (implicitly invertible) permutation matrix P: i.e., Group structure The set of n × n generalized permutation matrices with entries in a field F forms a subgroup of the general linear group GL(n, F), in which the group of nonsingular diagonal matrices Δ(n, F) forms a normal subgroup. Indeed, the generalized permutation matrices are the normalizer of the diagonal matrices, meaning that the generalized permutation matrices are the largest subgroup of GL(n, F) in which diagonal matrices are normal. The abstract group of generalized permutation matrices is the wreath product of F× and Sn. Concretely, this means that it is the semidirect product of Δ(n, F) by the symmetric group Sn: Sn ⋉ Δ(n, F), where Sn acts by permuting coordinates and the diagonal matrices Δ(n, F) are isomorphic to the n-fold product (F×)n. To be precise, the generalized permutation matrices are a (faithful) linear representation of this abstract wreath product: a realization of the abstract group as a subgroup of matrices. Subgroups The subgroup where all entries are 1 is exactly the permutation matrices, which is isomorphic to the symmetric group. The subgroup where all entries are ±1 is the signed permutation matrices, which is the hyperoctahedral group. The subgroup where the entries are mth roots of unity is isomorphic to a generalized symmetric group. The subgroup of diagonal matrices is abelian, normal, and a maximal abelian subgroup. The quotient group is the symmetric group, and this construction is in fact the Weyl group of the general linear group: the diagonal matrices are a maximal torus in the general linear group (and are their own centralizer), the generalized permutation matrices are the normalizer of this torus, and the quotient, is the Weyl group. Properties If a nonsingular matrix and its inverse are both nonnegative matrices (i.e. matrices with nonnegative entries), then the matrix is a