Why Test the Determinant First?
For a square linear system, a determinant test can tell us whether the system has exactly one solution before we carry out a full solution procedure. This is useful when deciding whether Cramer's Rule is an option: that rule uses a nonzero determinant in its denominator, so it cannot be applied when the coefficient matrix has determinant zero. The test does not, by itself, solve the system, and a zero determinant does not automatically mean that the system is inconsistent.
Write a square system of \(n\) equations in \(n\) unknowns as \(\mathbf{A}\mathbf{x}=\mathbf{b}\), where \(\mathbf{A}\in\mathbb{R}^{n\times n}\) is the coefficient matrix, \(\mathbf{x}\in\mathbb{R}^n\) is the column of unknowns, and \(\mathbf{b}\in\mathbb{R}^n\) is the right-hand side. A solution is a vector \(\mathbf{x}\) satisfying the equation. It is unique if exactly one such vector exists.
The square-matrix restriction matters. The determinant is defined for square matrices, and Cramer's Rule is a method for solving square systems. For a system with a different number of equations and unknowns, this determinant test and Cramer's Rule do not apply in this form.
Why the Test Works
The determinant test for invertibility, established in the earlier material on determinants, says that a square matrix \(\mathbf{A}\) is invertible exactly when \(\det\mathbf{A}\ne0\). An invertible matrix has an inverse \(\mathbf{A}^{-1}\), which lets us solve \(\mathbf{A}\mathbf{x}=\mathbf{b}\) by multiplying both sides by that inverse.
Proof. Suppose first that \(\det\mathbf{A}\ne0\). Then \(\mathbf{A}\) is invertible by the determinant test for invertibility. The vector \(\mathbf{x}=\mathbf{A}^{-1}\mathbf{b}\) is a solution because \(\mathbf{A}\mathbf{A}^{-1}\mathbf{b}=\mathbf{b}\). If \(\mathbf{y}\) is any other solution, then \(\mathbf{A}\mathbf{y}=\mathbf{b}\) and \(\mathbf{A}\mathbf{x}=\mathbf{b}\), so \(\mathbf{A}(\mathbf{x}-\mathbf{y})=\mathbf{0}\). Multiplying by \(\mathbf{A}^{-1}\) gives \(\mathbf{x}-\mathbf{y}=\mathbf{0}\), hence \(\mathbf{x}=\mathbf{y}\). The solution therefore exists and is unique.
Now suppose that \(\det\mathbf{A}=0\). Then \(\mathbf{A}\) is not invertible. By the Invertible Matrix Theorem, the homogeneous system \(\mathbf{A}\mathbf{z}=\mathbf{0}\) has a nonzero solution \(\mathbf{z}\). If \(\mathbf{A}\mathbf{x}=\mathbf{b}\) has no solution, the original system is inconsistent. If it has a solution \(\mathbf{x}\), then for every real number \(t\),
Because \(\mathbf{z}\ne\mathbf{0}\), the vectors \(\mathbf{x}+t\mathbf{z}\) are distinct for distinct values of \(t\). Thus a consistent system with \(\det\mathbf{A}=0\) has more than one solution, not a unique solution. These cases prove both directions of the claim. \(\square\)
This result concerns whether there is a unique solution for a given right-hand side. In fact, when \(\det\mathbf{A}\ne0\), the solution is unique for every \(\mathbf{b}\). When \(\det\mathbf{A}=0\), the right-hand side determines whether any solutions exist, but it cannot produce exactly one.
When Cramer's Rule Applies
Cramer's Rule is a formula for the solution of a square system with an invertible coefficient matrix. To state it, let \(\mathbf{A}_i(\mathbf{b})\) be the matrix obtained from \(\mathbf{A}\) by replacing its \(i\)th column with \(\mathbf{b}\). The rule gives the \(i\)th unknown as a quotient of determinants. The formula is included here to identify the method and its conditions; its derivation is given in the later treatment of deriving Cramer's Rule by replacing columns.
The condition \(\det\mathbf{A}\ne0\) is essential: it ensures that the system has a unique solution and that the denominator in each quotient is nonzero. If \(\det\mathbf{A}=0\), do not try to use the formula. A zero denominator makes the formula undefined, and the system may have no solutions or infinitely many. If the system is rectangular, the determinant-based rule is not the appropriate method either.
Proof. The rule is stated for an \(n\times n\) coefficient matrix and requires division by \(\det\mathbf{A}\), so it requires a square matrix with nonzero determinant. Conversely, if the coefficient matrix is square and \(\det\mathbf{A}\ne0\), the stated conditions of Cramer's Rule hold, so the rule applies. The determinant test proved above also shows that these conditions guarantee a unique solution. \(\square\)
Worked Examples: Testing Before Solving
Worked Example: A System with a Unique Solution
Test the system $$ \begin{aligned} 2x_1+x_2&=5,\\ x_1+x_2&=3 \end{aligned} $$ for a unique solution, then use Cramer's Rule to calculate it and check the result.
The coefficient matrix and right-hand side are
Compute the determinant:
Since \(1\ne0\), the system has a unique solution, and Cramer's Rule applies. Replace the first column by \(\mathbf{b}\) to find \(x_1\), and the second column by \(\mathbf{b}\) to find \(x_2\):
Therefore, \(x_1=2/1=2\) and \(x_2=1/1=1\). Check: \(2(2)+1=5\), and \(2+1=3\), so \(\mathbf{x}=\begin{bmatrix}2\\1\end{bmatrix}\) satisfies both original equations.
Worked Example: A Singular System with Infinitely Many Solutions
Determine whether the system $$ \begin{aligned} x_1+2x_2&=3,\\ 2x_1+4x_2&=6 \end{aligned} $$ has a unique solution, and decide whether Cramer's Rule applies.
The coefficient matrix is \(\mathbf{A}=\begin{bmatrix}1&2\\2&4\end{bmatrix}\). Its determinant is
Consequently, the system cannot have a unique solution, and Cramer's Rule does not apply. To see which alternative occurs, row-reduce the augmented matrix:
The remaining equation is \(x_1+2x_2=3\). Set \(x_2=t\), where \(t\in\mathbb{R}\); then \(x_1=3-2t\). Thus all solutions are \(\begin{bmatrix}3-2t\\t\end{bmatrix}\), with \(t\) any real number. Check: the first left-hand side is \((3-2t)+2t=3\), and the second is \(2(3-2t)+4t=6\). The system has infinitely many solutions.
Worked Example: A Singular System with No Solution
Now change only the right-hand side: $$ \begin{aligned} x_1+2x_2&=3,\\ 2x_1+4x_2&=7. \end{aligned} $$ The coefficient matrix is unchanged, so its determinant is still \(0\). The system cannot have a unique solution and Cramer's Rule still does not apply. Check consistency by reducing the augmented matrix:
The last row represents \(0x_1+0x_2=1\), or \(0=1\), which is impossible. Hence the system has no solution. Check: the second equation's left-hand side is always twice the first equation's left-hand side, so if the first equals \(3\), the second must equal \(6\), not \(7\).
Common Mistake: Treating Zero Determinant as Inconsistency
A common incorrect conclusion is: “The determinant is zero, so the system has no solution.” The determinant test says only that there cannot be a unique solution. The two singular examples show why the distinction matters: one system had infinitely many solutions, while the other had none.
The wrong calculation is to stop at \(\det\mathbf{A}=0\) and write “no solution.” For the system with right-hand side \(\begin{bmatrix}3\\6\end{bmatrix}\), that conclusion is false: \(\begin{bmatrix}3\\0\end{bmatrix}\) is a solution, since $$ \begin{bmatrix}1&2\\2&4\end{bmatrix} \begin{bmatrix}3\\0\end{bmatrix} = \begin{bmatrix}3\\6\end{bmatrix}. $$ The correction is to use the determinant to rule out uniqueness, then test consistency separately if \(\det\mathbf{A}=0\). Row reduction of the augmented matrix is one way to decide whether solutions exist.
Keep the conclusions separate:
| Coefficient matrix | Conclusion for the system | Cramer's Rule? |
|---|---|---|
| Square and \(\det\mathbf{A}\ne0\) | Exactly one solution for every \(\mathbf{b}\) | Yes |
| Square and \(\det\mathbf{A}=0\) | No solution or more than one solution | No |
| Not square | This determinant test does not apply | No, not in this form |
A Practical Decision Process
Confirm that the coefficient matrix has the same number of rows and columns. If it is not square, the determinant test and Cramer's Rule do not apply in this form.
Use a suitable determinant method and keep track of any effects of row operations on its value.
If the determinant is nonzero, the system has a unique solution. If it is zero, uniqueness is impossible.
When the determinant is nonzero, Cramer's Rule is available. When it is zero, examine the augmented system to distinguish no solutions from multiple solutions.
The test is especially useful before lengthy calculations. It can establish immediately whether Cramer's Rule is valid, but it does not say that Cramer's Rule is always the most efficient way to find a solution. The key decision is narrower: first check whether the coefficient matrix is square and has nonzero determinant. Only then is the rule available.
Check Your Understanding
For each question, distinguish what the determinant tells you from what still requires checking.
- A square coefficient matrix has determinant \(-4\). What does this guarantee about the system for any right-hand side, and can Cramer's Rule be used?
- A square coefficient matrix has determinant \(0\). What two possibilities remain for the system?
- Why does a nonzero solution of \(\mathbf{A}\mathbf{z}=\mathbf{0}\) rule out a unique solution to any consistent system \(\mathbf{A}\mathbf{x}=\mathbf{b}\)?
- For \(\mathbf{A}=\begin{bmatrix}1&2\\2&4\end{bmatrix}\) and \(\mathbf{b}=\begin{bmatrix}3\\6\end{bmatrix}\), verify that \(\begin{bmatrix}3\\0\end{bmatrix}\) is a solution, then explain why the system is not uniquely solvable.
- Does Cramer's Rule, as stated here, apply to a system with three equations and two unknowns? Explain which condition fails.