System of Equations Calculator

Enter the coefficients of two linear equations (a₁x + b₁y = c₁ and a₂x + b₂y = c₂) to solve for x and y using Cramer's Rule.

Quick Facts

Main determinant
D = a₁b₂ - a₂b₁
A unique solution exists only when D ≠ 0.
Cramer's Rule
x = Dx / D, y = Dy / D
Dx = c₁b₂ - c₂b₁; Dy = a₁c₂ - a₂c₁.
D = 0 cases
No solution or infinite solutions
Infinite solutions if Dx = Dy = 0 too; otherwise no solution (parallel lines).

Your Results

Calculated
x
-
Solution for x
y
-
Solution for y
Determinant (D)
-
D = a₁b₂ - a₂b₁
Solution type
-
Unique, none, or infinite

Ready

Enter both equations' coefficients, then press Calculate.

How the System of Equations Calculator works

A system of two linear equations in two unknowns has the general form a₁x + b₁y = c₁ and a₂x + b₂y = c₂, where a₁, b₁, c₁, a₂, b₂, and c₂ are known numbers and x and y are the unknowns you are solving for. Geometrically, each equation is a straight line, and solving the system means finding the point (x, y) where the two lines meet. This calculator uses Cramer's Rule, a determinant-based method, to solve for x and y directly without manual substitution or elimination.

Formula and method (Cramer's Rule)

First compute the main determinant of the coefficient matrix: D = a₁b₂ - a₂b₁. Then compute two more determinants by swapping in the constants: Dx = c₁b₂ - c₂b₁ (replace the a-column with c₁, c₂) and Dy = a₁c₂ - a₂c₁ (replace the b-column with c₁, c₂). As long as D ≠ 0, the unique solution is x = Dx / D and y = Dy / D. This is algebraically equivalent to solving the system by substitution or elimination, but it is easier to automate and to reason about.

Interpreting a zero determinant

If D = 0, the two lines have identical slopes (a₁/b₁ = a₂/b₂), so they are parallel and there is no unique intersection point. In that case, check Dx and Dy: if both are also zero, the two equations describe the exact same line, so there are infinitely many solutions (every point on the line satisfies both equations). If D = 0 but Dx or Dy is nonzero, the lines are parallel but distinct, so the system has no solution.

Common sources of error

  • Wrong equation form: both equations must be rearranged into a x + b y = c before entering coefficients — for example, y = 2x - 5 becomes -2x + y = -5 (a = -2, b = 1, c = -5).
  • Sign errors: a missing negative sign on a coefficient or constant flips the answer; double-check each term's sign as you move it across the equals sign.
  • Mixing up rows: keep equation 1's coefficients (a₁, b₁, c₁) and equation 2's coefficients (a₂, b₂, c₂) in their own row — swapping a single value between rows changes the system entirely.

Checking your result

Once you have x and y, substitute them back into both original equations. If a₁x + b₁y equals c₁ and a₂x + b₂y equals c₂ (within rounding), the solution checks out. This back-substitution step catches almost all data-entry and sign mistakes.

Applications

  • Break-even analysis: find the quantity and price where two cost or revenue lines intersect.
  • Mixture and rate problems: solve for two unknown quantities (e.g., liters of two solutions, or two speeds) given two linear relationships.
  • Circuit analysis: solve simultaneous loop or node equations from Kirchhoff's laws for two unknown currents or voltages.
  • Supply-and-demand intersection: find the equilibrium price and quantity where a linear supply curve meets a linear demand curve.

Frequently Asked Questions

What is Cramer's Rule and how does it solve a system of equations?
Cramer's Rule solves a₁x + b₁y = c₁ and a₂x + b₂y = c₂ using determinants. The main determinant is D = a₁b₂ - a₂b₁. Replace the x-column with the constants to get Dx = c₁b₂ - c₂b₁, and replace the y-column to get Dy = a₁c₂ - a₂c₁. Then x = Dx / D and y = Dy / D.
What does it mean when the determinant D equals zero?
D = a₁b₂ - a₂b₁ = 0 means the two lines are parallel (equal slopes), so there is no single point of intersection. If D = 0 and both Dx and Dy also equal zero, the two equations describe the same line, so there are infinitely many solutions. If D = 0 but Dx or Dy is nonzero, the lines are parallel and distinct, so there is no solution.
How do I put my equations into the a₁x + b₁y = c₁ form?
Move every x-term and y-term to the left side and every constant to the right side. For example, 2x = 12 - 3y becomes 2x + 3y = 12, giving a₁ = 2, b₁ = 3, c₁ = 12. Do the same for the second equation before entering the coefficients.
Can this calculator solve systems with three or more variables?
No, this calculator solves exactly two linear equations in two unknowns (x and y) using Cramer's Rule for a 2×2 system. Systems with three or more variables need an extended method such as Gaussian elimination or a 3×3 (or larger) matrix determinant, which this tool does not compute.