﻿ Cramer's Rule 3x3 Step by Step

# Example of Solving a System of Linear Equations by Cramer's Rule.

### This solution was made using the calculator presented on the site.

It is necessary to solve the system of linear equations using Cramer's rule.
 - 2 x1 + x2 + x3 = -13 - x1 + x2 + 2 x3 = -9 3 x1 + x2 + x3 = 12
Let's write the Cramer's rule:
x1 = det A1 / det A
x2 = det A2 / det A
x3 = det A3 / det A
It is impossible to divide by zero. Therefore, if the determinant of A is zero, then it is impossible to use Cramer's rule.
The determinant A consists of the coefficients of the left side of the system.
 - 2 x1 + x2 + x3 = -13 - x1 + x2 + 2 x3 = -9 3 x1 + x2 + x3 = 12
 det A = -2 1 1 = -1 1 2 3 1 1
The elements of row 1 multiplied by -1 are added to the corresponding elements of row 3.   more info
 -2 1 1 -1 1 2 3 + ( -2) * ( -1) 1 + 1 * ( -1) 1 + 1 * ( -1)
This elementary transformation does not change the value of the determinant.
 = -2 1 1 = -1 1 2 5 0 0
 -2 1 1 -1 1 2 5 0 0
Row number 3
Column number 1
Element Row 3 and column 1
have been deleted
( -1) 3 + 1 * 5 *
 1 1 1 2
 -2 1 1 -1 1 2 5 0 0
Row number 3
Column number 2
Element Row 3 and column 2
have been deleted
( -1) 3 + 2 * 0 *
 -2 1 -1 2
 -2 1 1 -1 1 2 5 0 0
Row number 3
Column number 3
Element Row 3 and column 3
have been deleted
( -1) 3 + 3 * 0 *
 -2 1 -1 1
Products are summed. If the element is zero than product is zero too.
 = ( -1) 3 + 1 * 5 * 1 1 = 1 2
 = 5 * 1 1 = 1 2
= 5 * ( 1 * 2 - 1 * 1 ) =
= 5 * ( 2 - 1 ) =
= 5
The determinant A is not zero. It is possible to use the Cramer's rule.
It is necessary to change column 1 in determinant A to the column of the right side of the system.
System det A det A1
 - 2 x1 + x2 + x3 = -13 - x1 + x2 + 2 x3 = -9 3 x1 + x2 + x3 = 12
 -2 1 1 -1 1 2 3 1 1
 -13 1 1 -9 1 2 12 1 1
 det A1 = -13 1 1 = -9 1 2 12 1 1
The elements of row 1 multiplied by -1 are added to the corresponding elements of row 3.   more info
 -13 1 1 -9 1 2 12 + ( -13) * ( -1) 1 + 1 * ( -1) 1 + 1 * ( -1)
This elementary transformation does not change the value of the determinant.
 = -13 1 1 = -9 1 2 25 0 0
 -13 1 1 -9 1 2 25 0 0
Row number 3
Column number 1
Element Row 3 and column 1
have been deleted
( -1) 3 + 1 * 25 *
 1 1 1 2
 -13 1 1 -9 1 2 25 0 0
Row number 3
Column number 2
Element Row 3 and column 2
have been deleted
( -1) 3 + 2 * 0 *
 -13 1 -9 2
 -13 1 1 -9 1 2 25 0 0
Row number 3
Column number 3
Element Row 3 and column 3
have been deleted
( -1) 3 + 3 * 0 *
 -13 1 -9 1
Products are summed. If the element is zero than product is zero too.
 = ( -1) 3 + 1 * 25 * 1 1 = 1 2
 = 25 * 1 1 = 1 2
= 25 * ( 1 * 2 - 1 * 1 ) =
= 25 * ( 2 - 1 ) =
= 25
It is necessary to change column 2 in determinant A to the column of the right side of the system.
System det A det A2
 - 2 x1 + x2 + x3 = -13 - x1 + x2 + 2 x3 = -9 3 x1 + x2 + x3 = 12
 -2 1 1 -1 1 2 3 1 1
 -2 -13 1 -1 -9 2 3 12 1
 det A2 = -2 -13 1 = -1 -9 2 3 12 1
 -2 -13 1 -1 -9 2 3 + ( -2) 12 + ( -13) 1 + 1
This elementary transformation does not change the value of the determinant.
 = -2 -13 1 = -1 -9 2 1 -1 2
The elements of row 3 multiplied by 2 are added to the corresponding elements of row 1.   more info
 -2 + 1 * 2 -13 + ( -1) * 2 1 + 2 * 2 -1 -9 2 1 -1 2
This elementary transformation does not change the value of the determinant.
 = 0 -15 5 = -1 -9 2 1 -1 2
 0 -15 5 -1 + 1 -9 + ( -1) 2 + 2 1 -1 2
This elementary transformation does not change the value of the determinant.
 = 0 -15 5 = 0 -10 4 1 -1 2
 0 -15 5 0 -10 4 1 -1 2
Row number 1
Column number 1
Element Row 1 and column 1
have been deleted
( -1) 1 + 1 * 0 *
 -10 4 -1 2
 0 -15 5 0 -10 4 1 -1 2
Row number 2
Column number 1
Element Row 2 and column 1
have been deleted
( -1) 2 + 1 * 0 *
 -15 5 -1 2
 0 -15 5 0 -10 4 1 -1 2
Row number 3
Column number 1
Element Row 3 and column 1
have been deleted
( -1) 3 + 1 * 1 *
 -15 5 -10 4
Products are summed. If the element is zero than product is zero too.
 = ( -1) 3 + 1 * 1 * -15 5 = -10 4
 = -15 5 = -10 4
= -15 * 4 - 5 * ( -10) =
= -60 + 50 =
= -10
It is necessary to change column 3 in determinant A to the column of the right side of the system.
System det A det A3
 - 2 x1 + x2 + x3 = -13 - x1 + x2 + 2 x3 = -9 3 x1 + x2 + x3 = 12
 -2 1 1 -1 1 2 3 1 1
 -2 1 -13 -1 1 -9 3 1 12
 det A3 = -2 1 -13 = -1 1 -9 3 1 12
The elements of row 2 multiplied by -1 are added to the corresponding elements of row 1.   more info
 -2 + ( -1) * ( -1) 1 + 1 * ( -1) -13 + ( -9) * ( -1) -1 1 -9 3 1 12
This elementary transformation does not change the value of the determinant.
 = -1 0 -4 = -1 1 -9 3 1 12
The elements of row 2 multiplied by -1 are added to the corresponding elements of row 3.   more info
 -1 0 -4 -1 1 -9 3 + ( -1) * ( -1) 1 + 1 * ( -1) 12 + ( -9) * ( -1)
This elementary transformation does not change the value of the determinant.
 = -1 0 -4 = -1 1 -9 4 0 21
 -1 0 -4 -1 1 -9 4 0 21
Row number 1
Column number 2
Element Row 1 and column 2
have been deleted
( -1) 1 + 2 * 0 *
 -1 -9 4 21
 -1 0 -4 -1 1 -9 4 0 21
Row number 2
Column number 2
Element Row 2 and column 2
have been deleted
( -1) 2 + 2 * 1 *
 -1 -4 4 21
 -1 0 -4 -1 1 -9 4 0 21
Row number 3
Column number 2
Element Row 3 and column 2
have been deleted
( -1) 3 + 2 * 0 *
 -1 -4 -1 -9
Products are summed. If the element is zero than product is zero too.
 = ( -1) 2 + 2 * 1 * -1 -4 = 4 21
 = -1 -4 = 4 21
= -1 * 21 - ( -4) * 4 =
= -21 + 16 =
= -5
Result:
x1 = det A1 / det A = 25/5 = 5
x2 = det A2 / det A = -10/5 = -2
x3 = det A3 / det A = -5/5 = -1