M-Matrix — Definition, Formula & Example
An M-matrix is a square matrix whose off-diagonal entries are all zero or negative and whose inverse exists and contains no negative entries. That nonnegative inverse is what makes these matrices useful.
A real matrix is a nonsingular M-matrix if it can be written as , where has all entries and , the spectral radius of . For a Z-matrix (one with for ), each of the following is equivalent to being a nonsingular M-matrix: (1) every leading principal minor of is positive; (2) every eigenvalue of has positive real part; (3) exists and entrywise; (4) some vector satisfies . If you allow , you get the singular M-matrices.
Key Formula
Where:
- = the n × n matrix being tested
- = the n × n identity matrix
- = a matrix whose entries are all nonnegative
- = a positive real number
- = spectral radius of B, the largest absolute value among its eigenvalues
Worked Example
Problem: Decide whether is a nonsingular M-matrix.
Step 1: Check the sign pattern. The off-diagonal entries are −3 and −1, and both are at most 0. So A is a Z-matrix, and you can apply the minor test.
Step 2: Compute the leading principal minors. The first is the top-left entry. The second is the full determinant.
Step 3: Confirm with the inverse. For a 2 × 2 matrix the inverse is the adjugate divided by the determinant. Every entry comes out nonnegative, as the theory predicts.
Answer: A is a nonsingular M-matrix. Its eigenvalues, the roots of , are 1 and 5, and both are positive. Row 1 is not diagonally dominant because . Strict diagonal dominance is sufficient for a Z-matrix with positive diagonal to be a nonsingular M-matrix, but it is not required.
Why It Matters
When you discretize a boundary-value problem such as with finite differences in a numerical analysis course, you get a tridiagonal coefficient matrix with entries 2 and −1. That matrix is an M-matrix. Its nonnegative inverse guarantees that a nonnegative heat source produces a nonnegative temperature solution, and it guarantees that Jacobi and Gauss–Seidel iteration converge. In economics, the Leontief input-output model has a nonnegative production plan for every nonnegative demand exactly when is a nonsingular M-matrix.
Common Mistakes
Mistake: Concluding that a matrix is an M-matrix just because its diagonal is positive and its off-diagonal entries are negative.
Correction: The sign pattern only makes it a Z-matrix. You still need a test such as positive leading principal minors. For example, has the right signs, but its determinant is , so it is not an M-matrix.
