# Solving Simultaneous Equations: Multiple Methods

### Introduction and Terms

Recently, a post on the G+ Mathematics community involved how to determine $$x$$ and $$y$$ when: $3x + 5y = 12 \\ x + y = 2$

This is generally referred to as simultaneous equations or a system of equations. As a general rule, for such a problem to be solvable, you need as many equations as there are variables.

Those discussing this problem came up with five basic ways to solve it, although two are less practical than the other three. I’m presenting the solutions here in the chronological order that they’re most likely to be seen by a student.

### Guess-and-check

Elementary mathematics these days seems to put emphasis on the idea of simply inserting numbers for an unknown value until the equation works out. For instance, given $$3 + ? = 5$$, try 1. $$3 + 1 = 4$$, so that doesn’t work; try 2. $$3 + 2 = 5$$, so that’s the correct answer. Guess-and-check has a few limitations. First, it relies on the notion that there is a single correct answer; for linear relationships with a single variable, which are what students experience in basic arithmetic, that’s true. Second, it basically relies on integer solutions, which is what students are generally exposed to in the early grades. Third, it works best with a single unknown; guess-and-check using two or more variables, particularly when there are values outside of the positive integers (as in this example), seems impractical.

Guess-and-check does have pedagogical utility, on a few levels. It helps develop number sense. If you put a number in a gap and your answer is too low, should you increase or decrease your guess? By how much? It also helps develop a habit of estimating as a first step. I went to school in the days when scientific calculators were first becoming affordable, so in high school we were taught how to interpolate to estimate irrational square roots. Interpolation is really just a sophisticated form of guess-and-check. To estimate $$\sqrt{2}$$, for instance: $1 \cdot 1 = 1 \\ 2 \cdot 2 = 4 \\ 1.5 \cdot 1.5 = 2.25 \\ 1.4 \cdot 1.4 = 1.96 \\ 1.43 \cdot 1.43 = 2.0449 \\ 1.42 \cdot 1.42 = 2.0164 \\ 1.41 \cdot 1.41 = 1.9881 \\ 1.415 \cdot 1.415 = 2.002225$and so on. On each line, we use the information from the previous calculation to make another guess.

Another version of guess-and-check that is useful for approaching new problems, particularly when a computer is available, is brute force: Estimate the minimum and maximum possible values for the solutions, then mechanically go through every possible solution. This is superior to guess-and-check in that it will find multiple solutions. It is inferior in that it is a purely mechanical process that shows little mathematical understanding (except in the in initial selection of bounds), and it is very time consuming.

I have seen too many students relying on guess-and-check as their exclusive problem-solving strategy, at the high school level. This means that when they encounter a problem where guess-and-check is ineffective at best (as in this case), they get frustrated and don’t know how to proceed.

### Rewrite the Equations

The first approach that students usually see for solving a system of two two-variable equations uses these steps:

1. Rewrite the second equation so that $$y$$ is alone on the LHS (Left Hand Side).
2. Replace $$y$$ in the first equation with the RHS (Right Hand Side) of the new second equation.
3. Solve the first equation for $$x$$.
4. Replace $$x$$ in the second equation with this numeric value.
5. Solve the second equation for $$y$$.

In the case of the example:

$(1) y = 2 – x \\ (2) 3x + 5(2 – x) = 12 \\ (3) \implies 3x + 10 – 5x = 12 \\ \implies -2x + 10 = 12 \\ \implies -2x = 2 \\ \implies x = -1 \\ (4) -1 + y = 2 \\ (5) y = 3$

This gives us the solution $$x = -1, y = 3$$.

### Graphing the Equations

Graphing the equations provides a visual explanation of what the relationship between these equations is; it reinforces that these are both straight lines, because the equations involve two variables, neither of which are raised to a power. However, graphing by hand is a mechanical act, and is prone to error. When the solution only involves integers (as is the case here), graphing is useful enough. However, most students tend to avoid graphing, and at any rate it’s less useful for cases where the solution involves non-integers. Graphing on a calculator will lead to a more exact answer.

In this particular case, rewriting the equations into slope-intercept formula prior to graphing also leads to fractions, which likewise tends to cause students to recoil: $y = -\frac{3}{5}x + \frac{12}{5} \\ y = -x + 2$So graphing in a case like this might have pedagogical uses, but as a general method for solving, its limitations outweigh its benefits.

### Operate on Equations

As a precursor to matrix algebra, the next step in the evolution of solving systems of equations is to multiply one equation and then add the result to the other to eliminate a variable. With two-variable systems (like the example), this is about as much work as rewriting the equations. However, as more variables and equations are added, this is generally more efficient.

In this case, look at the coefficients. You’re looking for a case where you can multiply one equation by some value so that the coefficients for one variable are the same. You can then subtract one equation from the other, eliminating that variable. In the example, let’s multiply the second equation by 3 and then go from there. When we multiply an equation by a constant, we multiply each element on both sides of the equation by that value. $3x + 5y = 12 ; x + y = 2 \\ 3x + 5y = 12 ; 3x + 3y = 6 \\ 3x – 3x + 5y – 3y = 12 – 6 \\ 2y = 6 \\ y = 3$ From here, take the value of y and insert it into one of the two original equations and solve for x: $3x + 5(3) = 12 \\ \implies 3x + 15 = 12 \\ \implies 3x = -3 \\ \implies x = -1$

### Matrices

The most sophisticated approach to solving simultaneous equations is to basically ignore the variables and focus on the coefficients. This is yet another level of abstraction, so students may struggle with understanding it, but we can write the equations strictly in terms of the coefficients, making sure to line the columns up by the variables. For instance, we could rewrite the sample problem as: $\begin{bmatrix}3 & 5 &|& 12 \\1 & 1 &|& 2\end{bmatrix}$
The pipe (|) represents the equality sign. The goal is to create a matrix with ones along the diagonal; the values in the rightmost column then represent the values of each variable: $\begin{bmatrix}1 & 0 &|& x \\0 & 1 &|& y\end{bmatrix}$
We reach this goal using the same strategy as in the previous section. Indeed, operating on equations is a precursor to using matrices, by teaching the basic concept in a more familiar context. However, because we want 1 in the upper left corner, we’ll multiply the second line by 5 and then subtract it from the first. You can combine steps, but in the example below, I’ll only apply one step to each matrix so it’s easier to follow: $\begin{bmatrix}3 & 5 &|& 12 \\1 & 1 &|& 2\end{bmatrix} \\ \implies \begin{bmatrix}3 & 5 &|& 12 \\5 & 5 &|& 10\end{bmatrix} \text{(Line 2 \times 5)} \\ \implies \begin{bmatrix}-2 & 0 &|& 2 \\5 & 5 &|& 10\end{bmatrix} \text{(Line 1 – Line 2)} \\ \implies \begin{bmatrix}1 & 0 &|& -1 \\5 & 5 &|& 10\end{bmatrix} \text{(Line 1 \div -2)} \\ \implies \begin{bmatrix}1 & 0 &|& -1 \\1 & 1 &|& 2\end{bmatrix} \text{(Line 2 \div 5)} \\ \implies \begin{bmatrix}1 & 0 &|& -1 \\0 & 1 &|& 3\end{bmatrix} \text{(Line 2 – Line 1)}$Now that we have the target matrix to the left of the pipe, we can read the solution from the column on the right.

While the matrix method may seem like more work than the other methods, particularly for a simple problem such as the example, it has advantages for more complex problems. One of its greater advantages for solving systems of equations is its level of organization; it makes it more difficult to lose track of steps. For instance, imagine solving this set of equations (source): $2w-x+5y+z=-3 \\ 3w+2x+2y-6z=-32 \\ w+3x+3y-z=-47 \\ 5w-2x-3y+3z=49$While Dr. Math (source) suggests iteratively rewriting the equations (rewrite for z, identify three equations, rewrite for w, identify two equations, rewrite for y, solve for x, solve for y, solve for w, solve for z), a small error in that process can be difficult to track down. Laying it out in a matrix and then solving the matrix can make it easier to keep track of what you’re doing: $\begin{bmatrix} 2 & -1 & 5 & 1 &|& -3 \\ 3 & 2 & 2 & -6 &|& -32 \\ 1 & 3 & 3 & -1 &|& -47 \\ 5 & -2 & -3 & 3 &|& 49 \end{bmatrix}$

In any case, the “best” strategy is the one that works best for you.