Solving Three Variable Equations

••• perfectlab/iStock/GettyImages

When first introduced to systems of equations, you probably learned to solve a system of two-variable equations by graphing. But solving equations with three variables or more requires a new set of tricks, namely the techniques of elimination or substitution.

An Example System of Equations

Consider this system of three, three-variable equations:

Equation #1:

2x + y + 3z = 10

Equation #2:

5x - y - 5z = 2

Equation #3:

x + 2y - z = 7

Solving by Elimination

Look for places where adding any two equations together will make at least one of the variables cancel itself out.

    Choose any two of the equations and combine them to eliminate one of the variables. In this example, adding Equation #1 and Equation #2 will cancel out the ​y​ variable, leaving you with the following new equation:

    New Equation #1:

    7x - 2z = 12

    Repeat Step 1, this time combining a ​different​ set of two equations but eliminating the ​same​ variable. Consider Equation #2 and Equation #3:

    Equation #2:

    5x - y - 5z = 2

    Equation #3:

    x + 2y - z = 7

    In this case the ​y​ variable doesn't immediately cancel itself out. So before you add the two equations together, multiply both sides of Equation #2 by 2. This gives you:

    Equation #2 (modified):

    10x - 2y - 10z = 4

    Equation #3:

    x + 2y - z = 7

    Now the 2​y​ terms will cancel each other out, giving you another new equation:

    New Equation #2:

    11x - 11z = 11

    Combine the two new equations you created, with the goal of eliminating yet another variable:

    New Equation #1:

    7x - 2z = 12

    New Equation #2:

    11x - 11z = 11

    No variables cancel themselves out just yet, so you'll have to modify both equations. Multiply both sides of the first new equation by 11, and multiply both sides of the second new equation by −2. This gives you:

    New Equation #1 (modified):

    77x – 22z = 132

    New Equation #2 (modified):

    -22x + 22z = -22

    Add both equations together and simplify, which gives you:

    x = 2

    Now that you know the value of ​x​, you can substitute it into the original equations. This gives you:

    Substituted Equation #1:

    y + 3z = 6

    Substituted Equation #2:

    -y - 5z = -8

    Substituted Equation #3:

    2y - z = 5

    Choose any two of the new equations and combine them to eliminate another one of the variables. In this case, adding Substituted Equation #1 and Substituted Equation #2 makes ​y​ cancel out nicely. After simplifying, you'll have:

    z = 1

    Substitute the value from Step 5 into any one of the substituted equations, and then solve for the remaining variable, ​y.​ Consider Substituted Equation #3:

    Substituted Equation #3:

    2y - z = 5

    Substituting in the value for ​z​ gives you 2​y​ – 1 = 5, and solving for ​y​ brings you to:

    y = 3

    So the solution for this system of equations is ​x​ = 2, ​y​ = 3 and ​z​ = 1.

Solving by Substitution

You can also solve the same system of equations using another technique called substitution. Here's the example again:

Equation #1:

2x + y + 3z = 10

Equation #2:

5x - y - 5z = 2

Equation #3:

x + 2y - z = 7

    Pick any variable and solve any one equation for that variable. In this case, solving Equation #1 for ​y​ works out easily to:

    y = 10 - 2x - 3z

    Substitute the new value for ​y​ into the other equations. In this case, choose Equation #2. This gives you:

    Equation #2: 5​x​ - (10 - 2​x​ - 3​z​) ​-​ 5z = 2

    Equation #3: ​x​ + 2(10 - 2​x​ - ​3z​) - ​z​ = 7

    Make your life easier by simplifying both equations:

    Equation #2:

    7x - 2z = 12

    Equation #3:

    -3x - 7z = -13

    Choose one of the remaining two equations and solve for another variable. In this case, choose Equation #2 and ​z​. This gives you:

    z = \frac{7x - 12}{2}

    Substitute the value from Step 3 into the final equation, which is #3. This gives you:

    -3x - 7 × \frac{7x - 12}{2} = -13

    Things get a little messy here but once you simplify, you'll be back to:

    x = 2

    "Back-substitute" the value from Step 4 into the two-variable equation you created in Step 3:

    z = \frac{7x - 12}{2}

    This lets you solve for ​z.​ (In this case, ​z​ = 1).

    Next, back-substitute both the ​x​ value and the ​z​ value into the first equation that you'd already solved for ​y​. This gives you:

    y = 10 - (2 × 2) - (3 × 1)

    ...and simplifying gives you the value ​y​ = 3.

Always Check Your Work

Note that both methods of solving the system of equations brought you to the same solution: (​x​ = 2, ​y​ = 3, ​z​ = 1). Check your work by substituting this value into each of the three equations.

Related Articles

3 Methods for Solving Systems of Equations
How to Solve Linear Equations With 2 Variables
Algebra 1 Substitution Method
How to Use Elimination to Solve the Linear Equation
How to Solve a System of Equations
How to Factorise a Quadratic Expression
How to Store & Access Equations on a TI-83 Plus
How to Solve for Both X & Y
How to Multiply Monomials
How to Factorize Equations
Pros & Cons in Methods of Solving Systems of Equations
Infinite Solution Elimination Method
How to Explain Basic Pre-Algebra Equations
Tips for Solving Multi-Step Equations
How to Find X-Intercept & Y-Intercept
Tips for Solving Algebraic Equations
How to Solve Rational Expression Equations
How to Factor Polynomials With 4 Terms
How to Find an Ordered Pair From an Equation
How to Solve Double Inequalities

Dont Go!

We Have More Great Sciencing Articles!