Skip to main content

Method of Determinants

This method uses determinants to find the solution of a linear system. There are two kinds of determinants. One is the determinant of the coefficients matrix denoted by Δ\Delta. Other are the determinants of matrices formed by replacing a single column with the constant vector, if column 1 is replaced then the determinant is denoted by Δ1\Delta_1 and similarly Δ2\Delta_2, Δ3\Delta_3 etc.

After calculating the determinants we can get the solution as x1=Δ1/Δ, x2=Δ2/Δx_1=\Delta_1/\Delta,\ x_2=\Delta_2/\Delta and so on.

This method is also known as Cramer's rule as it was proposed by Gabriel Cramer.

Interactive Calculator

This section demonstrates an interactive calculator for solving a linear system using the method of determinants.

System size
x1+x_{1}+
x2+x_{2}+
x3=x_{3}=
x1+x_{1}+
x2+x_{2}+
x3=x_{3}=
x1+x_{1}+
x2+x_{2}+
x3=x_{3}=
Given system is:
[753216123][x1x2x3]=[123]\begin{bmatrix}7 & 5 & 3 \\ 2 & 1 & 6 \\ 1 & 2 & 3\end{bmatrix}\begin{bmatrix}x_{1} \\ x_{2} \\ x_{3}\end{bmatrix}=\begin{bmatrix}1 \\ 2 \\ 3\end{bmatrix}
or, AX=B\text{or, }AX=B
We calculate Δ\Delta as the determinant of AA.
Δ=753216123=54\Delta=\begin{vmatrix}7 & 5 & 3\\2 & 1 & 6\\1 & 2 & 3\end{vmatrix}=-54
We calculate Δ1\Delta_1 by replacing the first column with constant vector BB
Δ1=153216323=54\Delta_{1}=\begin{vmatrix}\colorbox{aqua}{1} & 5 & 3\\\colorbox{aqua}{2} & 1 & 6\\\colorbox{aqua}{3} & 2 & 3\end{vmatrix}=54
Similarly,
Δ2=713226133=72\Delta_{2}=\begin{vmatrix}7 & \colorbox{aqua}{1} & 3\\2 & \colorbox{aqua}{2} & 6\\1 & \colorbox{aqua}{3} & 3\end{vmatrix}=-72
Δ3=751212123=24\Delta_{3}=\begin{vmatrix}7 & 5 & \colorbox{aqua}{1}\\2 & 1 & \colorbox{aqua}{2}\\1 & 2 & \colorbox{aqua}{3}\end{vmatrix}=-24
Therefore, the solution of the system is:
x1=Δ1/Δ=5454=1x_{1}=\Delta_{1}/\Delta=-\frac{54}{54}=-1
x2=Δ2/Δ=7254=1.3333x_{2}=\Delta_{2}/\Delta=\frac{72}{54}=1.3333
x3=Δ3/Δ=2454=0.4444x_{3}=\Delta_{3}/\Delta=\frac{24}{54}=0.4444

Complexity

The time complexity of this method is O(N4)O(N^4). This is because we need to calculate NN determinants and it requires O(N3)O(N^3) to calculate the determinant of a matrix. The space complexity is O(N2)O(N^2).

Advantages

  1. Simple to understand and implement
  2. Easier to perform manually.

Disadvantages

  1. This method is one of the most inefficient in terms of time complexity.