Inverse Matrices

Arthur Cayley

  Suppose that A is a square matrix. We want to find a matrix (which we denote naturally by A-1) of the same size, such that A-1 times A equals I, the identity matrix. Whatever A does or transforms to, A-1 undoes or transforms back. Their product is the identity matrix, which does nothing. The problem is that such inverse matrix might not exist. The notion of the inverse of a matrix first appears in an 1855 note of Arthur Cayley (1821--1895). In 1842, Arthur Cayley graduated from Trinity College, Cambridge, England, but could not find a suitable teaching post. So for 14 years starting 1863, he worked as a lawyer. During this time frame, he published about 300 mathematical papers, and finally, in 1863, he became a professor at Cambridge.

A square n × n matrix A is invertible or not singular if there exists a matrix A-1 such that
\[ {\bf A}^{-1} {\bf A} = {\bf I} \qquad \mbox{and} \qquad {\bf A}\,{\bf A}^{-1} = {\bf I} . \]
Apparently, a square matrix for which does not exist an inverse matrix is called singular.

Non-square matrices (m-by-n matrices for which mn) do not have an inverse. However, in some cases such a matrix may have a left inverse or right inverse. If A is m-by-n and the rank of A is equal to n, then A has a left inverse: an n-by-m matrix B such that BA = In. If A has rank m, then it has a right inverse: an n-by-m matrix B such that AB = Im. There are known many other generalized inverses. In other sections, we will work with the pseudoinverse, which is sometimes called the Moore–Penrose inverse, when we discuss least squares approximations and singular value decomposition. However, there are known others such as group inverse and Drazin inverse.

Raymond Beauregard

Theorem: (Raymond Beauregard) For any n × n matrices A and C over a field of scalars,

\[ {\bf A}\,{\bf C} = {\bf I} \quad \mbox{if and only if} \quad {\bf C}\,{\bf A} = {\bf I} . \qquad\qquad ▣ \]
Recall that if A is n × n matrix then its reduced row-echelon form H is a matrix of the same size with zeros in the pivot columns except for the pivots which are equal to 1. It is achieved by applying elementary row operations (row swapping, row addition, row scaling) to A. An elementary matrix is one obtained by applying a single elementary row operation to the n × n identity matrix I. Elementary matrices have inverses that are also elementary matrices. Left multiplication of A by an elementary matrix E effects the same row operation on A that was used to create E. If P is a product of those elementary matrices that reduce A to P, then P is invertible and PA = HH.

Let H be the reduced row echelon form of A, and let P be the product of those elementary matrices (in the appropriate order) that reduce A to H. P is an invertible matrix such that P A = H. Notice that H is the identity matrix if and only if it has n pivots.

Beginning with AC = I, we left multiply this equation by P obtaining \( {\bf P}\,{\bf A}\,{\bf C} = {\bf P} \) or \( {\bf H}\,{\bf C} = {\bf P} . \) If H is not the identity matrix it must have a bottom row of zeros forcing P to have likewise a bottom row of zeros, and this contradicts the invertibility of P. Thus H = I, C = P, and the equation \( {\bf P}\,{\bf A} = {\bf H} \) is actually \( {\bf C}\,{\bf A} = {\bf I} . \)

This argument shows at once that (i) a matrix is invertible if and only if its reduced row echelon form is the identity matrix, and (ii) the set of invertible matrices is precisely the set of products of elementary matrices.

From Beauregard's theorem, it follows that the inverse matrix is unique. Although, we can show directly that a matrix A cannot have two different inverses. Suppose the opposite is true and there exist two matrices B and C such that BA = I and AC = I. According to the identities
\[ {\bf B} \left( {\bf A}\, {\bf C} \right) = \left( {\bf B}\,{\bf A} \right) {\bf C} \qquad \Longrightarrow \qquad {\bf B}\,{\bf I} = {\bf I}\, {\bf C} \qquad \Longrightarrow \qquad {\bf B} = {\bf C} . \]

Theorem: If A and B are two nonsingular matrices of the same dimension, then

\[ \left( {\bf A}\, {\bf B} \right)^{-1} = {\bf B}^{-1}{\bf A}^{-1} . \qquad\qquad ▣ \]
We multiply AB by B-1 A-1 to obtain
\[ \left( {\bf A}\, {\bf B} \right) \left( {\bf B}^{-1} {\bf A}^{-1} \right) = {\bf A}\,{\bf I} \,{\bf A}^{-1} = {\bf A}\,{\bf A}^{-1} = {\bf I} . \]
Similarly, B-1 A-1 times AB equals I. ■
This theorem confirms the common sense: If one put on socks and then sneakers, the first to be taken off are sneakers.
Given A ∈ ℝm×n, the transpose of A = [ai,j], denoted AT or just A', is an element of ℝn×m defined by \( \left[ a_{i,j} \right]^{\mathrm T} = \left[ a_{j,i} \right] . \)

Theorem: Let A be a rectangular m × n matrix with real entries. Then the product \( {\bf A}^{\mathrm T}{\bf A} \) is an invertible n × n matrix if and only if A has linearly independent columns (full column rank). This statement is valid for complex-valued matrices, but instead of \( {\bf A}^{\mathrm T}{\bf A} \) it should be considered \( {\bf A}^{\ast}{\bf A} , \) the product of the adjoint matrix with itself. ▣

The product is a square matrix (n-by-n). For every matrix A, we are going to show that \( {\bf A}^{\mathrm T}{\bf A} \) has the same kernel as A. When the columns of A are linearly independent, its nullspace contains only the zero vector. Then \( {\bf A}^{\mathrm T}{\bf A} , \) with this same nullspace, is invertible.

Let A be any matrix. If vector x is in its kernel, then Ax = 0. Multiplying by \( {\bf A}^{\mathrm T} \) gives \( {\bf A}^{\mathrm T}{\bf A} \,{\bf x} = {\bf 0} . \) So x is also in the nullspace of \( {\bf A}^{\mathrm T}{\bf A} . \)

Now start with the kernel of \( {\bf A}^{\mathrm T}{\bf A} . \) From \( {\bf A}^{\mathrm T}{\bf A} \,{\bf x} = {\bf 0} , \) we must prove that Ax = 0. We multiply from left by \( {\bf x}^{\mathrm T}: \)

\[ \left( {\bf x}^{\mathrm T} \right) {\bf A}^{\mathrm T} {\bf A} \,{\bf x} = {\bf 0} \qquad\mbox{or} \qquad \left( {\bf A} \,{\bf x} \right)^{\mathrm T} \left( {\bf A} \,{\bf x} \right) = {\bf 0} \qquad\mbox{or} \qquad \left\| {\bf A} \,{\bf x} \right\|^2 = 0 . \]
The vector \( {\bf A} \,{\bf x} \) has length zero. Therefore, \( {\bf A} \,{\bf x} = {\bf 0} . \) Every vector x in one nullspace is in the other nullspace. If A is of full column rank, so does \( {\bf A}^{\mathrm T}{\bf A} . \) If A has independent columns, so does \( {\bf A}^{\mathrm T}{\bf A} . \)

A diagonal matrix has an inverse provided no diagonal entries are zero:

\[ {\bf \Lambda} = \begin{bmatrix} \lambda_1 &0&0& \cdots &0 \\ 0&\lambda_2 &0 & \cdots &0 \\ \vdots&\vdots&&\ddots & \vdots \\ 0&0&0& \cdots &\lambda_n \end{bmatrix} \qquad\Longrightarrow \qquad {\bf \Lambda}^{-1} = \begin{bmatrix} 1/\lambda_1 &0&0& \cdots &0 \\ 0&1/\lambda_2 &0 & \cdots &0 \\ \vdots&\vdots&&\ddots & \vdots \\ 0&0&0& \cdots &1/\lambda_n \end{bmatrix} . \]

Now we answer a natural question how to find an inverse matrix. There are known two basic methods to determine the inverse of a square (nonsingular) matrix: the cofactor method and Gauss--Jordan elimination procedure. We discuss an iterative method in Numerical Applications section. We start with the former, which is most numerically expensive. For a completeness, the cofactor matrices are defined again. We also need another definition of minor introduced by the English mathematician James Sylvester in 1850.

Given A = [ai,j] ∈ ℂn×n, the minor Mi,j of the element ai,j is the determinant of the resulting (n-1)×(n-1) matrix found by removing row i and column j from A.
For a given n × n matrix \( {\bf A} = \left[ a_{ij} \right] , \) the (i,j)-cofactor of A is the number Cij given by \( C_{ij} = (-1)^{i+j} \det{\bf A}_{i,j} , \) where Ai,j is (n-1) × (n-1) matrix obtained from A by deleting i-th row and j-th column. The n × n transpose matrix of cofactors is called the adjugate of A
\[ \mbox{adj}{\bf A} = \left[ (-1)^{i+j} \det{\bf A}_{j,i} \right] = \left[ C_{ji} \right] = {\bf C}^{\mathrm T} . \]

Theorem: The inverse of a square matrix A is the transpose of the cofactor matrix times the reciprocal of the determinant of A:

\[ {\bf A}^{-1} = \frac{1}{\det\,{\bf A}} \,\mbox{adj}\,{\bf A}^{\mathrm T} = \frac{1}{\det\,{\bf A}} \,{\bf C}^{\mathrm T} , \qquad\mbox{where} \quad {\bf C} = \begin{bmatrix} C_{1,1} & C_{1,2} & \cdots & C_{1,n} \\ C_{2,1} & C_{2,2} & \cdots & C_{2,n} \\ \vdots&\vdots& \ddots & \vdots \\ C_{n,1} & C_{n,2} & \cdots & C_{n,n} \end{bmatrix} \]
is the cofactor matrix (also called the matrix of cofactors). ▣
Our starting point is the cofactor expansion:
\[ \det {\bf A} = \sum a_{i,k}\,A_{j,k} , \]
where Aj,k is the cofactor of the element aj,k, and the sum is either on j (for any fixed value of k) or on k (for any fixed value of j). If we have the sum over j, then
\[ \sum_j a_{j,k} A_{j,i} = \begin{cases} \det {\bf A} , & \ \mbox{ if } \ i=k , \\ 0, & \ \mbox{ if } \ i \ne k \end{cases} \]
since we get two identical columns when ik. Upon division by det A, we have
\[ \sum_j \left( \frac{A_{j,i}}{\det {\bf A}} \right) a_{j,k} = \delta_{i,k} = \begin{cases} 1 , & \ \mbox{ if } \ i=k , \\ 0, & \ \mbox{ if } \ i \ne k . \end{cases} \]
This scalar statement (which holds for \( 1 \le i \le n, \ 1 \le j \le n \) ) is equivalent, according to the definition of matrix multiplication to the matrix equation
\[ {\bf A}^{-1} {\bf A} = {\bf I}_n , \]
where the desired inverse matrix is
\[ {\bf A}^{-1} = \left[ \frac{A_{j,i}}{\det {\bf A}} \right] . \]

Corollary: A square matrix A is invertible (nonsingular) if and only if its determinant det(A) ≠ 0. ▣

Using the above theorem, we obtain explicit formulae for 2 × 2 and 3 × 3 matrices:
\[ \begin{bmatrix} a&b \\ c&d \end{bmatrix}^{-1} = \frac{1}{ad-bc} \,\begin{bmatrix} d&-b \\ -c&a \end{bmatrix} , \]
eq1 = a*alpha + b*gamma == 1
eq2 = a*beta + b*delta == 0
eq3 = c*alpha + d*gamma == 0
eq4 = c*beta + d*delta == 1
Solve[{eq1, eq2, eq3, eq4}, {alpha, beta, gamma, delta}]
{{alpha -> d/(-b c + a d), beta -> b/(b c - a d), gamma -> c/(b c - a d), delta -> a/(-b c + a d)}}
and
\[ \begin{bmatrix} a_{11}&a_{12}&a_{13} \\ a_{21}&a_{22}&a_{23} \\ a_{31}&a_{32} &a_{33} \end{bmatrix}^{-1} = \frac{1}{\det\,{\bf A}} \,\begin{bmatrix} \begin{vmatrix} a_{22}&a_{23} \\ a_{32}&a_{33} \end{vmatrix}& \begin{vmatrix} a_{13}&a_{12} \\ a_{33}&a_{32} \end{vmatrix} & \begin{vmatrix} a_{12}&a_{13} \\ a_{22}&a_{23} \end{vmatrix} \\ \begin{vmatrix} a_{23}&a_{21} \\ a_{33}&a_{31} \end{vmatrix}&\begin{vmatrix} a_{11}&a_{13} \\ a_{31}&a_{33} \end{vmatrix} &\begin{vmatrix} a_{13}&a_{11} \\ a_{23}&a_{21} \end{vmatrix} \\ \begin{vmatrix} a_{21}&a_{22} \\ a_{31}&a_{32} \end{vmatrix} & \begin{vmatrix} a_{12}&a_{11} \\ a_{32}&a_{31} \end{vmatrix} & \begin{vmatrix} a_{11}&a_{12} \\ a_{21}&a_{22} \end{vmatrix} \end{bmatrix} , \]
where we use the vertical lines to define determinants of corresponding matrices.
A = {{a,b,c}, {d,e,f}, {g,h,i}};
K = {{p,q,r}, {u,v,w}, {x,y,z}};
P = A.K;
Solns = Simplify[Solve[{P == IdentityMatrix[3]}, {p,q,r,u,v,w,x,y,z}]]

The cofactor matrix can be computed in the Wolfram language using

Cofactor[m_List?MatrixQ, {i_Integer, j_Integer}] :=
(-1)^(i+j) Det[Drop[Transpose[
Drop[Transpose[m], {j}]], {i} ]]
which is the equivalent of the (i,j)-th component of the CofactorMatrix defined below:
MinorMatrix[m_List?MatrixQ] :=
Map[Reverse, Minors[m], {0, 1}]
CofactorMatrix[m_List?MatrixQ] :=
MapIndexed[#1 (-1)^(Plus @@ #2)&, MinorMatrix[m],{2}]
The cofactor formula for the inverse matrix allows us to make the following two statements.

Theorem: A square matrix A is invertible if and only if its determinant is not zero: detA ≠ 0. ▣

Theorem: Let A be an invertible square matrix. Then the linear equation Ax = b has a unique solution \( {\bf x} = {\bf A}^{-1} {\bf b} \) for any vector b. ▣

Theorem: \( \det {\bf A}^{-1} = 1/ \det{\bf A}. \)


Example: Consider the matrix
\[ {\bf A} = \begin{bmatrix} 48&-30&-14&1 \\ 65&-41&-19&0 \\ 17&-10&-5&3 \\ -35&22&10&0 \end{bmatrix} . \]
To find its inverse, we need to check whether the given matrix is singular or not:
A = {{48, -30, -14, 1}, {65, -41, -19, 0}, {17,-10,-5,3}, {-35, 22, 10, 0}}
Det[A]
Out[2]= -1
Now we calculate the cofactor matrix:
\begin{align*} C_{1,1} &= \det \begin{bmatrix} -41&-19&0 \\ -10&-5&3 \\ 22&10&0 \end{bmatrix} = -24 , \\ C_{1,2} &= - \det \begin{bmatrix} 65&-19&0 \\ 17&-5&3 \\ -35&10&0 \end{bmatrix} = -45, \\ C_{1,3} &= \det \begin{bmatrix} 65&-41&0 \\ 17&-10&3 \\ -35&22&0 \end{bmatrix} = 15, \\ C_{1,4} &= - \det \begin{bmatrix} 65&-41&-19 \\ 17&-10&-5 \\ -35&22&10 \end{bmatrix} = -11. \end{align*}
Similarly, we can calculate all other cofactors, which yields, together with \( \det{\bf A} = -1 , \) the inverse matrix:
\[ {\bf A}^{-1} = \begin{bmatrix} 24&-14&-8&3 \\ 45&-25&-15&8 \\ -15&6&5&-7 \\ -11&6&4&-2 \end{bmatrix} . \]

 Now we compute the inverse matrix using the Gauss-Jordan elimination procedure. If A is an n × n nonsingular matrix, then for any column vector b, which is n × 1 matrix, the linear system Ax = b has a unique solution. Partition the identity matrix In into its columns that we denote as \( {\bf e}_i , \ i=1,2,\ldots , n . \) Since the identity matrix can be represented as a collection of column-vectors \( {\bf I}_n = \left[ {\bf e}_1 \ {\bf e}_2 \ \cdots \ {\bf e}_n \right] , \) every linear equation \( {\bf A}\,{\bf x} = {\bf e}_i \) has a unique solution for each i. Hence, we have

\[ {\bf A}\,{\bf c}_1 = {\bf e}_1 , \quad {\bf A}\,{\bf c}_2 = {\bf e}_2 , \quad \cdots \quad {\bf A}\,{\bf c}_n = {\bf e}_n , \]
Writing the above system of equations in matrix form, we get
\[ \left[ {\bf A}\,{\bf c}_1 , \ {\bf A}\,{\bf c}_2 , \ \cdots \ {\bf A}\,{\bf c}_n \right] = \left[ {\bf e}_1 \ {\bf e}_2 \ \cdots \ {\bf e}_n \right] = {\bf I}_n . \]
From our observation on partitioned matrices, the above matrix equation can be written in the form
\[ {\bf A} \left[ {\bf c}_1 , \ {\bf c}_2 , \ \cdots \ {\bf c}_n \right] = {\bf I}_n . \]
Letting \( {\bf C} = \left[ {\bf c}_1 , \ {\bf c}_2 , \ \cdots \ {\bf c}_n \right] , \) we have just shown that C is the inverse of A. To find C, we introduce the augmented matrix \( \left[ {\bf A} \ {\bf I} \right] . \) Then apply the following algorithm.

Theorem: Inversion Algorithm To find the inverse of a square matrix A, use two steps

  • Step 1: form the augmented matrix \( \left[ {\bf A} \ {\bf I} \right] . \)
  • Step 2: apply the Gauss--Jordan method to attempt to reduce \( \left[ {\bf A} \ {\bf I} \right] \) to \( \left[ {\bf I} \ {\bf C} \right] . \) If the reduction can be carried out, then A-1 = C. Otherwise, A-1 does not exist. ▣
A simple method for carrying out this algorithm is given in the following example.
Example: Consider the 3 × 3 matrix
\[ {\bf A} = \begin{bmatrix} 2&3&1 \\ 4&7&4 \\ 1&-2&-6 \end{bmatrix} . \]
We find its inverse using Gauss-Jordan method applied to the augmented matrix \( \left[ {\bf A} \ {\bf I} \right] . \) Of course, using Mathematica, it is an easy job:
A = {{2, 3, 1}, {4, 7, 4}, {1, -2, -6}}
Inverse[A]
{{-34, 16, 5}, {28, -13, -4}, {-15, 7, 2}}
B = Join[A, IdentityMatrix[3], 2]
RowReduce[B]
{{1, 0, 0, -34, 16, 5}, {0, 1, 0, 28, -13, -4}, {0, 0, 1, -15, 7, 2}}
Next, we extract the last three columns that will define the inverse matrix:
BB = RowReduce[B]
{{1, 0, 0, -34, 16, 5}, {0, 1, 0, 28, -13, -4}, {0, 0, 1, -15, 7, 2}}
Drop[BB, {}, {1}]
{{0, 0, -34, 16, 5}, {1, 0, 28, -13, -4}, {0, 1, -15, 7, 2}}
Drop[%, {}, {1}]
{{0, -34, 16, 5}, {0, 28, -13, -4}, {1, -15, 7, 2}}
invA = Drop[%, {}, {1}]
{{-34, 16, 5}, {28, -13, -4}, {-15, 7, 2}}
However, we show all steps required to determine the inverse matrix without applying the standard commands. We start with the augmented matrix, which we denote as B:
\[ {\bf B} = \left[ {\bf A}\ \vert \ {\bf I}_3 \right] = \begin{bmatrix} 2&3&1&1&0&0 \\ 4&7&4&0&1&0 \\ 1&-2&-6&0&0&1 \end{bmatrix} . \]
We multiply the first row by (-2) and add to the second row. Then we multiply the first row by (-1/2) and add to the third row. This yields
\[ {\bf B} \,\sim \, {\bf B}_1 = \begin{bmatrix} 2&3&1&1&0&0 \\ 0&1&2&-2&1&0 \\ 0&-\frac{7}{2} & -\frac{13}{2} & -\frac{1}{2} & 0 & 1 \end{bmatrix} . \]
This can also be achieved with multiplication by the elementary matrices:
\[ {\bf E}_1 = \begin{bmatrix} 1&0&0 \\ -2&1&0 \\ 0&0&1 \end{bmatrix} , \qquad {\bf E}_2 = \begin{bmatrix} 1&0&0 \\ 0&1&0 \\ -1/2&0&1\end{bmatrix} . \]
Then
\[ {\bf E}_{21} = {\bf E}_2 {\bf E}_1 = {\bf E}_1 {\bf E}_2 = \begin{bmatrix} 1&0&0 \\ -2&1&0 \\ -1/2&0&1 \end{bmatrix} \qquad \Longrightarrow \qquad {\bf E}_{21}^{-1} = \begin{bmatrix} 1&0&0 \\ 2&1&0 \\ 1/2&0&1 \end{bmatrix} . \]
B = Join[A, IdentityMatrix[3], 2]
{{2, 3, 1, 1, 0, 0}, {4, 7, 4, 0, 1, 0}, {1, -2, -6, 0, 0, 1}}
B1 = {{1, 0, 0}, {-2, 1, 0}, {0, 0, 1}}.B
{{2, 3, 1, 1, 0, 0}, {0, 1, 2, -2, 1, 0}, {1, -2, -6, 0, 0, 1}}
B1 = {{1, 0, 0}, {0, 1, 0}, {-1/2, 0, 1}}.B1
{{2, 3, 1, 1, 0, 0}, {0, 1, 2, -2, 1, 0}, {0, -(7/2), -(13/2), -(1/2), 0, 1}}
Next move would be multiplication of the second row by (7/2) and adding to the third row. This is equivalent to multiplication by the elementary matrix:
\[ {\bf E}_3 = \begin{bmatrix} 1&0&0 \\ 0&1&0 \\ 0&7/2&1 \end{bmatrix} . \]
Multiplying by it, we get
\[ {\bf E}_{13} = {\bf E}_3 {\bf E}_2 {\bf E}_1 = \begin{bmatrix} 1&0&0 \\ -2&1&0 \\ -\frac{15}{2}&\frac{7}{2}&1 \end{bmatrix} \qquad \Longrightarrow \qquad {\bf E}_{13}^{-1} = \begin{bmatrix} 1&0&0 \\ 2&1&0 \\ \frac{1}{2}&-\frac{7}{2}&1 \end{bmatrix} . \]
E13 = {{1, 0, 0}, {0, 1, 0}, {0, 7/2, 1}}.{{1, 0, 0}, {0, 1, 0}, {-1/2, 0, 1}}.{{1, 0, 0}, {-2, 1, 0}, {0, 0, 1}}
{{1, 0, 0}, {-2, 1, 0}, {-(15/2), 7/2, 1}}
Inverse[E13]
{{1, 0, 0}, {2, 1, 0}, {1/2, -(7/2), 1}}
We are now halfway because the obtained matrix in the first three columns to be U, upper triangular:
\[ {\bf E}_{13} {\bf B} = \begin{bmatrix} 2&3&1&1&0&0 \\ 0&1&2&-2&1&0 \\ 0&0&\frac{1}{2} & -\frac{15}{2}&\frac{7}{2}&1 \end{bmatrix} . \]
We can speed up this part by using a subroutine:
A = {{2, 3, 1}, {4, 7, 4}, {1, -2, -6}}
B = Join[A, IdentityMatrix[3], 2]

PivotDown[m_, {i_, j_}, oneflag_: 0] :=
Block[{k}, If[m[[i, j]] == 0, Return[m]];
Return[Table[
Which[k < i, m[[k]], k > i, m[[k]] - m[[k, j]]/m[[i, j]] m[[i]],
k == i && oneflag == 0, m[[k]] , k == 1 && oneflag == 1,
m[[k]]/m[[i, j]] ], {k, 1, Length[m]}]]]

PivotDown[B, {1, 1}]
{{2, 3, 1, 1, 0, 0}, {0, 1, 2, -2, 1, 0}, {0, -(7/2), -(13/2), -(1/2), 0, 1}}
B = %
PivotDown[B, {2, 2}]
{{2, 3, 1, 1, 0, 0}, {0, 1, 2, -2, 1, 0}, {0, 0, 1/2, -(15/2), 7/2, 1}}
The forward elimination procedure would finish over here because Gauss is happy with this part, called reduced echelon form. The pivots 2, 1, 1/2 are on diagonal of submatrix U. The contribution of the geodesist Wilhelm Jordan is to continue with elimination. Wilhelm goes all the way to obtain the reduced row echelon form: rows are added to rows to produce zeroes above the pivots:
\begin{align*} {\bf E}_{13} {\bf B} & = \begin{bmatrix} 2&3&1&1&0&0 \\ 0&1&2&-2&1&0 \\ 0&0&\frac{1}{2} & -\frac{15}{2}&\frac{7}{2}&1 \end{bmatrix} \qquad (-3) \mbox{ row 2 + row 1} \\ & \sim \begin{bmatrix} 2&0&-5&7&-3&0 \\ 0&1&2&-2&1&0 \\ 0&0&\frac{1}{2} & -\frac{15}{2}&\frac{7}{2}&1 \end{bmatrix} \qquad (-4) \mbox{ row 3 + row 2} \\ & \sim \begin{bmatrix} 2&0&-5&7&-3&0 \\ 0&1&0&28&-13&-4 \\ 0&0&\frac{1}{2} & -\frac{15}{2}&\frac{7}{2}&1 \end{bmatrix} \qquad (10) \mbox{ row 3 + row 1} \\ & \sim \begin{bmatrix} 2&0&0&-68&32&10 \\ 0&1&0&28&-13&-4 \\ 0&0&\frac{1}{2} & -\frac{15}{2}&\frac{7}{2}&1 \end{bmatrix} . \end{align*}
The last step is to divide (except second row) by its pivot. The new pivots are all ones and we have reached I in the first half of the matrix. The last three columns will provide us the inverse matrix A-1:
\[ {\bf A}^{-1} = \begin{bmatrix} -34&16&5 \\ 28&-13&-4 \\ -15&7&2 \end{bmatrix} . \qquad\blacksquare \]

 

Theorem: Equivalent Statements regarding a square n × n matrix A.

  1. A is invertible.
  2. A is row equivalent to the identity matrix In.
  3. Ax = 0 has only the trivial (= zero) solution.
  4. A is expressible as a product of elementary matrices.
  5. Ax = b has a unique solution for each n-component column vector b (which is n × 1 matrix).
  6. The span (= set of all linear combinations) of the column vectors of A is \( \mathbb{R}^n . \)
  7. \( \det {\bf A} \ne 0. \)
  8. The spectrum of A does not contain zero.
  9. \( \left( {\bf A}^{-1} \right)^{\ast} = \left( {\bf A}^{\ast} \right)^{-1} \qquad \Longrightarrow \qquad \left( {\bf A}^{-1} \right)^{\mathrm T} = \left( {\bf A}^{\mathrm T} \right)^{-1} . \) This means that A is invertible if and only if its adjoint (or transpose) matrix is invertible. ▣

Inverse of partitioned matrices

Suppose we are given a square n×n matrix that could be partitioned as follows:
\[ {\bf A} = \begin{bmatrix} {\bf P} & {\bf Q} \\ {\bf R} & {\bf S} \end{bmatrix} , \]
where P is an r×r matrix, Q is an r×s matrix, R is an s×r matrix, and S is an s×s matrix such that r + s = n.

Assume that A−1 exists and can be partitioned in a similar way as

\[ {\bf A}^{-1} = \begin{bmatrix} {\bf X} & {\bf Y} \\ {\bf Z} & {\bf W} \end{bmatrix} , \]
where Xr×r, Yr×s, Zs×r, and Ws×s matrices are to be found. Observe that X, Y, Z, and W are of the same dimensions as P, Q, R, and S, respectively. Since A−1A = I, the identity matrix, we ave
\[ {\bf A}\, {\bf A}^{-1} = \begin{bmatrix} {\bf P} & {\bf Q} \\ {\bf R} & {\bf S} \end{bmatrix}\, \begin{bmatrix} {\bf X} & {\bf Y} \\ {\bf Z} & {\bf W} \end{bmatrix} = \begin{bmatrix} {\bf I}_1 & {\bf 0} \\ {\bf 0} & {\bf I}_2 \end{bmatrix} , \]
where I1 and I2 are identity matrices of the order r and s, respectively.

Using the definition of the product of matrices for partitioned matrices gives the following equations

\[ \begin{split} {\bf P\,X} + {\bf Q\,Z} &= {\bf I}_1 , \\ {\bf P\,Y} + {\bf Q\,W} &= {\bf 0} , \\ {\bf R\,X} + {\bf S\,Z} &= {\bf 0} , \\ {\bf R\,Y} + {\bf S\,W} &= {\bf I}_2 . \end{split} \]
Solving for X, Y, Z, and W, gives
\[ \begin{split} {\bf W} &= \left[ {\bf S} - {\bf R\,P}^{-1}{\bf Q} \right]^{-1} , \\ {\bf Y} &= -{\bf P}^{-1} {\bf Q\,W} , \\ {\bf Z} &= -{\bf W\,R\,P}^{-1} , \\ {\bf X} &= {\bf P}^{-1} - {\bf P}^{-1}{\bf Q\,Z} . \end{split} \]
Example: Upon partitioning the matrix, find its inverse.
\[ {\bf A} = \begin{bmatrix} \phantom{-}2 & 1 & 1 \\ -2& 3 &0 \\ -1&0& 1 \end{bmatrix} \]

  1. Determine whether the following matrices are invertible \[ \mbox{(a)}\quad \begin{bmatrix} 1 & 2 & -3 \\ 0 & 5 & -1 \\ -1 & 2 & 2 \\ \end{bmatrix}, \qquad \mbox{(b)}\quad \begin{bmatrix} -3 & 3 & 2 \\ -1 & -2 & -1 \\ 0 & 2 & 1 \\ \end{bmatrix}, \qquad \mbox{(c)}\quad \begin{bmatrix} 2 & 1 & 3 \\ -2 & 1 & -2 \\ 3 & 2 & 5 \\ \end{bmatrix}, \qquad \mbox{(d)}\quad \begin{bmatrix} -2 & 1 & -1 \\ -3 & -3 & 3 \\ -1 & 3 & -3 \\ \end{bmatrix} . \]
  2. Use Gauss--Jordan elimination procedure to find the inverse of the matrix. \[ \mbox{(a)}\quad \begin{bmatrix} 1 & 2 & -3 \\ 0 & 5 & -1 \\ -1 & 2 & 2 \\ \end{bmatrix} , \qquad \mbox{(b)}\quad \begin{bmatrix} -3 & 3 & 2 \\ -1 & -2 & -1 \\ 0 & 2 & 1 \end{bmatrix} . \]
  3. Use the adjoint (adjugate) method to find the inverse of the matrix. \[ \mbox{(a)}\quad \begin{bmatrix} \begin{bmatrix} 3 & 3 & -1 \\ -2 & 0 & 3 \\ 2 & 1 & -2 \end{bmatrix} , \qquad \mbox{(b)}\quad \begin{bmatrix} -3 & -1 & -3 \\ 2 & 1 & 1 \\ 2 & 1 & 0\\ \end{bmatrix} . \]
    1. Fadeev--LeVerrier algorithm, Wikipedia.
    2. Frame, J.S., A simple recursion formula for inverting a matrix, Bulletin of the American Mathematical Society, 1949, Vol. 55, p. 1045. doi:10.1090/S0002-9904-1949-09310-2
    3. Greenspan, D., Methods of matrix inversion, The American mathematical Monthly, 1955, Vol. 62, No. pp. 303--318.
    4. Karlsson, L., Computing explicit matrix inverses by recursion, Master's Thesis in Computing Science, 2006.
    5. Lightstone, A.H., Two methods of inverting matrices, Mathematics Magazine, 1968, Vol. 41, No. 1, pp. 1--7.