Skip to main content
Mathovia

Algebra / Systems of Equations

Substitution Method

The substitution method turns two equations in two unknowns into one equation in one unknown. You solve one equation for a variable, then plug that expression into the other. It's the method to reach for whenever a variable is already on its own.

Practice Problems
Written by
MPhil in Mathematics, Founder of Mathovia
Published

Mathematics verification: Mathematical formulas, calculations, worked examples and solutions are reviewed for accuracy before publication. How we check our work

Imagine you know that a pencil costs one dollar less than twice the price of an eraser, and that three erasers and two pencils cost . The first fact tells you exactly what “pencil” means in terms of “eraser”. So wherever the second fact says pencil, you can swap in that description, and suddenly there’s only one unknown left. That swap is the substitution method, and it’s the most natural way to solve a system of linear equations.

Substitution method: if y = px + q, substitute to get ax + b(px + q) = c
Substitution method

How the Substitution Method Works

A system of two equations has two unknowns, which is one too many to solve directly. Substitution removes one of them. If one equation tells you that , then and are the same number. You can replace with anywhere it appears in the other equation:

What’s left has only in it, so it’s an ordinary linear equation you already know how to solve.

The expression 2x − 1 from y = 2x − 1 replacing y in 3x + 2y = 12, giving 3x + 2(2x − 1) = 12, one equation in one variable
The whole method in one move: y is replaced by the expression it equals

Always put brackets around the expression you substitute. In the picture, becomes , not . Leaving the brackets out is the most common way to get a wrong answer.

The Steps of the Substitution Method

  1. Isolate one variable in one of the equations. Choose a variable with a coefficient of or if you can.
  2. Substitute that expression into the other equation, in brackets.
  3. Solve the resulting one-variable equation.
  4. Back-substitute the value into the isolated expression to find the second variable.
  5. Check the pair in both original equations.
Five numbered steps for solving x + 3y = 7 and 2x − y = 7: isolate x = 7 − 3y, substitute 2(7 − 3y) − y = 7, solve to get y = 1, back-substitute x = 4, and check 2(4) − 1 = 7
The five steps applied to one system, start to finish

Substitution Method Examples

Example 1: A Variable Is Already Isolated

Solve and .

Step 1 — the first equation already gives . Substitute it into the second:

Step 2 — expand and solve:

Step 3 — back-substitute:

Step 4 — check in the second equation:

Answer: . This is the pencil-and-eraser puzzle from the start: an eraser costs and a pencil .

Example 2: Isolate a Variable First

Solve and .

Step 1 — has coefficient in the first equation, so isolate it:

Step 2 — substitute into the second equation:

Step 3 — solve for :

Step 4 — back-substitute:

Step 5 — check both equations:

Answer:

Example 3: Choosing the Easier Variable

Solve and .

No variable is alone, and in the first equation every coefficient would leave fractions. In the second equation has coefficient , so isolate it there.

Step 1 — solve the second equation for :

Step 2 — substitute into the first equation:

Step 3 — back-substitute:

Answer: . Check: ✓ and ✓.

EquationBest variable to isolateWhy
already done is alone
coefficient
coefficient
avoid if possibleany choice gives fractions

When the Variable Disappears: No Solution or Infinitely Many

Sometimes the substitution cancels the variable completely. What’s left is a statement with no letters in it, and that statement tells you what kind of system you have.

Three ways substitution can end: a value such as x = 2 means one solution, a false statement such as −6 = 5 means no solution, and a true statement such as 2 = 2 means infinitely many solutions
The last line of the algebra tells you how many solutions there are

Substitution Method With No Solution

Solve and .

Step 1 — substitute:

Step 2 — simplify:

The -terms cancelled and left a statement that is false. No value of can make equal , so the system has no solution. The lines and have the same slope and different intercepts, so they’re parallel.

Substitution With Infinitely Many Solutions

Solve and .

Step 1 — substitute:

Step 2 — simplify:

This time the leftover statement is true no matter what is. The second equation is the first one rearranged, so both describe the same line. There are infinitely many solutions: every point .

Worked Example: A Word Problem

A school concert sold tickets and took in . Adult tickets cost and child tickets cost . How many of each were sold?

Step 1 — choose variables: let be the number of adult tickets and the number of child tickets.

Step 2 — write one equation for the count and one for the money:

Step 3 — isolate in the first equation:

Step 4 — substitute into the money equation:

Step 5 — solve for :

Step 6 — back-substitute:

Step 7 — check the money:

The concert sold 160 adult tickets and 40 child tickets.

The lines a + c = 200 and 14a + 9c = 2600 on axes of adult tickets and child tickets, crossing at (160, 40)
The count line and the money line meet at 160 adults and 40 children

When to Use Substitution

SituationBest method
one equation already reads or substitution
a variable has coefficient or substitution
both equations in standard form with larger coefficients, like and elimination
you want a picture or an estimategraphing
one equation is not linear, such as substitution

That last row matters later. Substitution is the only one of the three methods that works just as well when one equation is a curve, which is why it’s the main tool for nonlinear systems.

Common Mistakes to Avoid

  • Dropping the brackets. Substituting into gives . Writing loses the .
  • Substituting back into the same equation. If you isolated from the first equation, substitute into the second. Putting it back into the first just gives and teaches you nothing.
  • Stopping after one variable. Finding is halfway. A system’s solution is an ordered pair.
  • Misreading a cancelled variable. means no solution; means infinitely many. Neither means .
  • Sign errors when isolating. From , , not . Move across carefully.

Practice Problems

Work each one before opening the answer.

Problem 1. Solve by substitution: and .

Show answer

Step 1 — substitute :

Step 2 — back-substitute:

Answer:

Problem 2. Solve by substitution: and .

Show answer

Step 1 — substitute :

Step 2 — back-substitute:

Answer:

Problem 3. Solve by substitution: and .

Show answer

Step 1 — isolate in the first equation:

Step 2 — substitute and solve:

Step 3 — back-substitute:

Answer:

Problem 4. Solve by substitution: and .

Show answer

Step 1 — isolate in the first equation:

Step 2 — substitute and solve:

Step 3 — back-substitute:

Answer:

Problem 5. Solve by substitution: and .

Show answer

Step 1 — substitute:

Step 2 — the variable cancelled and left a true statement, so the equations describe the same line.

Answer: infinitely many solutions, every point

Problem 6. Solve by substitution: and .

Show answer

Step 1 — substitute:

Step 2 — the variable cancelled and left a false statement, so the lines are parallel.

Answer: no solution

Substitution works for every linear system, but Example 3 hinted at its weak spot: when no coefficient is , isolating a variable drags in fractions. The elimination method avoids that by adding the equations together instead.

Frequently Asked Questions

What is the substitution method?+

It is a way to solve a system of equations by solving one equation for one variable and substituting that expression into the other equation. That leaves a single equation with a single variable, which you solve, then use the result to find the other variable.

Which variable should I solve for first?+

Pick a variable whose coefficient is or , because isolating it needs no fractions. In , solving for gives in one step. If a variable is already alone, as in , use that equation directly.

What happens in the substitution method when there is no solution?+

The variable cancels and you are left with a false statement such as . That means the two lines are parallel and the system has no solution.

How does substitution show infinitely many solutions?+

The variable cancels and you are left with a true statement such as . Both equations describe the same line, so every point on it is a solution. You can write the answer as all points with given by either equation.

Is substitution or elimination better?+

Substitution is quickest when a variable is already isolated or has a coefficient of . Elimination is usually quicker when both equations are in standard form with larger coefficients. Both always give the same answer.

Related lessons

Calculators for this topic