What Is the Substitution Method?
The substitution method is a classic algebra technique for solving a system of two linear equations in two unknowns. You solve one equation for a single variable and substitute that expression into the other equation, reducing the problem to one equation in one variable. This calculator does that automatically for the general system \(a_1 x + b_1 y = c_1\) and \(a_2 x + b_2 y = c_2\).
How to Use It
Enter the six coefficients: \(a_1\), \(b_1\), \(c_1\) from the first equation and \(a_2\), \(b_2\), \(c_2\) from the second. Press calculate and you'll get the exact values of x and y, plus the determinant \(a_1 b_2 - a_2 b_1\) that confirms whether a unique solution exists.
The Formula Explained
From equation 1, \(x = (c_1 - b_1 y) / a_1\). Substituting into equation 2 and simplifying gives $$ y = \frac{a_1 c_2 - a_2 c_1}{a_1 b_2 - a_2 b_1} $$ Once y is known, back-substitute to find x. The denominator \(a_1 b_2 - a_2 b_1\) is the determinant of the coefficient matrix. If it equals zero, the two lines are parallel (no solution) or identical (infinitely many solutions), so there is no unique answer.
Worked Example
Solve \(2x + 3y = 13\) and \(x - y = -1\). Here \(a_1=2\), \(b_1=3\), \(c_1=13\), \(a_2=1\), \(b_2=-1\), \(c_2=-1\). Determinant $$ = (2)(-1) - (1)(3) = -5 $$ Then $$ y = \frac{2 \cdot -1 - 1 \cdot 13}{-5} = \frac{-15}{-5} = 3 $$ Back-substitute: $$ x = \frac{13 - 3 \cdot 3}{2} = \frac{4}{2} = 2 $$ So \(x = 2\), \(y = 3\).
Interpreting the Solution: Unique, None, or Infinite
Compute \(D = a_1b_2 - a_2b_1\) first. If \(D \neq 0\), the formulas give one exact answer. If \(D = 0\), the numerators decide between the other two cases.
| Determinant and consistency | Geometric meaning | Algebraic outcome during substitution | Number of solutions |
|---|---|---|---|
| \(D \neq 0\) | Lines with different slopes intersect at one point | A single equation in one variable, giving a unique x and then y | Exactly one |
| \(D = 0\) and the numerators are not both zero (inconsistent) | Parallel, distinct lines | A contradiction such as \(0 = k\) with \(k \neq 0\) (for example \(4 = 6\)) | None |
| \(D = 0\) and both numerators are zero (consistent) | Coincident lines (the same line) | An identity \(0 = 0\) (for example \(4 = 4\)) | Infinitely many |
How to verify an answer
- Take the x and y values you found.
- Substitute them into the first original equation and check that \(a_1x + b_1y\) equals \(c_1\).
- Do the same with the second original equation and \(c_2\).
- Both must hold. For example, with \(x = \frac{4}{3}\) and \(y = 3\): \(0 \cdot \frac{4}{3} + 2(3) = 6\) ✓ and \(3 \cdot \frac{4}{3} + 3 = 7\) ✓.
Checking against the original equations, not your rearranged ones, also catches algebra slips made during the substitution.
FAQ
What if the determinant is zero? The system has no unique solution — the lines are parallel or coincident.
Can I use decimals or negatives? Yes. Any real coefficient works, including fractions entered as decimals.
Is this the same answer as elimination or Cramer's rule? Yes — for a consistent system with a nonzero determinant, all three methods give the identical x and y.