Ekuation

method focus

Cramer's Rule Calculator

Solve systems of linear equations using Cramer's Rule. See each determinant matrix step by step -- det(A), det(A_x), det(A_y) -- with highlighted column substitutions.

Back to Linear System Solver -- Step-by-Step Calculator
Your figures

System Configuration

Number of equations and unknowns

Equation 1

a₁₁x + a₁₂y = b₁

Equation 2

a₂₁x + a₂₂y = b₂

Linear System Solver

Enter your system of linear equations to find the solution. Supports 2×2 and 3×3 systems with step-by-step Gaussian elimination, Cramer's rule, and matrix inverse.

The plate is drawn once you enter your figures.

Try an Example

Pick a scenario to see how the calculator works, then adjust the values

  1. Simple 2x2 System

    Solve 2x + 3y = 7 and x - y = 1 using Gaussian elimination

    Key values: 2×2 system · Unique solution · x=2, y=1

  2. 3x3 Engineering System

    Solve a 3-variable system commonly found in circuit analysis

    Key values: 3×3 system · Cramer's Rule · 3 unknowns

  3. Parallel Lines (No Solution)

    Explore what happens when two equations have no intersection

    Key values: 2×2 system · Inconsistent · No solution

Documentation

Cramer's Rule

Cramer's rule expresses each unknown as a ratio of determinants. For the system Ax=bA\mathbf{x} = \mathbf{b}:

xi=det⁡(Ai)det⁡(A)x_i = \frac{\det(A_i)}{\det(A)}

where AiA_i is the matrix AA with its ith column replaced by the constant vector b\mathbf{b}.


The 2×2 Case

For the system a1x+b1y=c1a_1x + b_1y = c_1, a2x+b2y=c2a_2x + b_2y = c_2:

x=∣c1b1c2b2∣∣a1b1a2b2∣=c1b2−c2b1a1b2−a2b1x = \frac{\begin{vmatrix} c_1 & b_1 \\ c_2 & b_2 \end{vmatrix}}{\begin{vmatrix} a_1 & b_1 \\ a_2 & b_2 \end{vmatrix}} = \frac{c_1 b_2 - c_2 b_1}{a_1 b_2 - a_2 b_1}
y=∣a1c1a2c2∣∣a1b1a2b2∣=a1c2−a2c1a1b2−a2b1y = \frac{\begin{vmatrix} a_1 & c_1 \\ a_2 & c_2 \end{vmatrix}}{\begin{vmatrix} a_1 & b_1 \\ a_2 & b_2 \end{vmatrix}} = \frac{a_1 c_2 - a_2 c_1}{a_1 b_2 - a_2 b_1}

The 3×3 Case

For three equations in three unknowns, compute four 3×3 determinants:

x=det⁡(A1)det⁡(A),y=det⁡(A2)det⁡(A),z=det⁡(A3)det⁡(A)x = \frac{\det(A_1)}{\det(A)}, \quad y = \frac{\det(A_2)}{\det(A)}, \quad z = \frac{\det(A_3)}{\det(A)}

Each 3×3 determinant uses cofactor expansion. For matrix (abcdefghi)\begin{pmatrix} a & b & c \\ d & e & f \\ g & h & i \end{pmatrix}:

det⁡=a(ei−fh)−b(di−fg)+c(dh−eg)\det = a(ei - fh) - b(di - fg) + c(dh - eg)

When to Use Cramer's Rule

ScenarioBest method
2×2 or 3×3 by handCramer's rule (elegant, formulaic)
Need only one variableCramer's rule (compute just 2 determinants)
Large systems (4×4+)Gaussian elimination (far fewer operations)
Nearly singular matrixGaussian elimination with pivoting

Computational cost: Cramer's rule for an n×nn \times n system requires computing n+1n+1 determinants, each costing O(n!)O(n!) with cofactor expansion. For large nn, Gaussian elimination at O(n3)O(n^3) is dramatically faster.


When Cramer's Rule Fails

If det⁡(A)=0\det(A) = 0, Cramer's rule is undefined — division by zero. This means the system is either inconsistent (no solution) or dependent (infinitely many solutions). You must use row reduction to distinguish between these cases.


Frequently Asked Questions

What is Cramer's rule?

Cramer's rule expresses each unknown in a system of linear equations as a ratio of determinants: xi=det⁡(Ai)det⁡(A)x_i = \frac{\det(A_i)}{\det(A)}, where AiA_i is the coefficient matrix AA with its iith column replaced by the constant vector b\mathbf{b}.

When should I use Cramer's rule vs. Gaussian elimination?

Cramer's rule is best for 2x2 or 3x3 systems solved by hand, or when you need only one variable. For larger systems (4x4 and above), Gaussian elimination is dramatically faster because Cramer's rule requires computing n+1n+1 determinants.

What happens when the determinant is zero?

When det⁡(A)=0\det(A) = 0, Cramer's rule is undefined (division by zero). This means the system has either no solution (inconsistent) or infinitely many solutions (dependent). You must use row reduction to distinguish between these two cases.

How do I compute a 3x3 determinant?

Use cofactor expansion along the first row: det⁡=a(ei−fh)−b(di−fg)+c(dh−eg)\det = a(ei - fh) - b(di - fg) + c(dh - eg), where the matrix entries are arranged as (a,b,c;d,e,f;g,h,i)(a,b,c;\\ d,e,f;\\ g,h,i). Alternatively, use the Sarrus rule (diagonal products) for 3x3 matrices.

Can Cramer's rule find just one variable without solving the whole system?

Yes. To find only xix_i, you only need to compute two determinants: det⁡(A)\det(A) and det⁡(Ai)\det(A_i). This is an advantage over Gaussian elimination, which always solves for all variables simultaneously.

Plate

Related method-focus calculators

Other method-focus variations of this calculator

Further plates

More Math calculators

Explore the category

Calculator Search

Search and find calculators