# document.write (document.title)

 Math Help > Basic Math > Word Problems and Basic Arithmetic > Substitution Method

## Substitution Method

### Two variables and Two unknowns

Let the variables be x and y.  The substitution method has four basic steps:

1. Solve the first equation for y.
2. Substitute the whole right-hand side of the equation (the one you just wrote) in place of "y" in the second equation. You should use parentheses around the substituted expression to keep everything orderly.
3. Solve this equation for x.
4. Use this value of x in any of the equations (the one you wrote in step 1 is easiest) to get the value of y.

Now I will apply these steps to an example, and I will label them so you can understand what I'm doing at each step.

### Example: two variables and two unknowns

x=-2y+1
x = y - 5

Step 1: solve eq. 1 for y
x=-2y+1
2y=-x+1
y=(-x+1)/2

Step 2: substitute value of y in eq. 2
x = y - 5
x = ((-x+1)/2) - 5

Step 3: solve step 2's eq. for x
x = -x/2 + 1/2 - 5
(3/2)x = -9/2
3x = -9
x = -3

Step 4: substitute value of x in step 1's eq.
y=(-x+1)/2
y=(-(-3)+1)/2
y=(3+1)/2
y=4/2
y=2

x = -2y + 1
-3 = -2(2) + 1
-3 = -4 + 1
-3 = -3
True.

x = y - 5
-3 = 2 - 5
-3 = -3
True.

Can you see how this procedure can be expanded to work with three equations in three variables?  Click here to see how this is done.

### Related pages in this website

The webmaster and author of this Math Help site is Graeme McRae.