LINEAR ALGEBRA TOOL
Cramer's Rule Calculator
Solve a square system of linear equations using determinants. Calculate the coefficient determinant, each replaced-column determinant, and the solution values.
Enter your augmented matrix
Enter one equation per line. For n unknowns, each line must contain n coefficients followed by the right-hand-side constant. Supports 2–6 equations. Fractions such as 1/2 are accepted.
Example format: 2 1 8 represents 2x + y = 8.
You can also separate the last column with a vertical bar.
Results
The determinant is nonzero. The system has a unique solution.
Solution values
Step 1: Coefficient matrix A
| 2 | 1 | -1 |
| -3 | -1 | 2 |
| -2 | 1 | 2 |
Step 2: Main determinant
Step 3: Replaced-column determinants
Replace one column of A at a time with the constants vector b. Each resulting determinant is the numerator for one unknown.
Dx
Matrix with column 1 replaced by the constants:
| 8 | 1 | -1 |
| -11 | -1 | 2 |
| -3 | 1 | 2 |
x = -2 / -1 = 2
Dy
Matrix with column 2 replaced by the constants:
| 2 | 8 | -1 |
| -3 | -11 | 2 |
| -2 | -3 | 2 |
y = -3 / -1 = 3
Dz
Matrix with column 3 replaced by the constants:
| 2 | 1 | 8 |
| -3 | -1 | -11 |
| -2 | 1 | -3 |
z = 1 / -1 = -1
Step 4: Check the solution
Substitute the solution into each original equation.
| Equation | Left side | Right side | Absolute error |
| 1 | 8 | 8 | 0 |
| 2 | -11 | -11 | 0 |
| 3 | -3 | -3 | 0 |
How Cramer's rule works
Write a square linear system as Ax = b. A is the coefficient matrix, x contains the unknowns, and b contains the constants.
To calculate an unknown, replace the corresponding column of A with b, calculate that matrix's determinant, and divide by det(A).
If det(A) is zero, the system does not have a unique solution. Matrix ranks can then distinguish between no solution and infinitely many solutions.
The calculator uses floating-point arithmetic, so results for nearly singular matrices may be affected by rounding.
Frequently asked questions
How should I enter an equation?
Enter its coefficients in variable order followed by the constant.
For example, 2x + 3y = 7 is entered as 2 3 7.
Can I use negative numbers and fractions?
Yes. Values such as -3, 0.25, 1/2 and 2e-3 are accepted.
Why is there no unique solution?
A zero coefficient determinant means Cramer's rule cannot produce a unique solution. The calculator checks matrix ranks to classify the system.
Related calculators
Remove any related link whose target page does not exist on your site.