Two equations, two unknowns
Why this matters
One equation with two unknowns has endless answers; two equations usually pin both numbers down. The picture is two lines crossing, and the answer is where they meet. This lesson solves such pairs two ways, and shows the step that real models are built around: two data points fix a line exactly, but three usually can't all be hit, which is why models are fitted rather than solved. Along the way, you'll check every answer in both equations, by hand and in Python. It's the idea that real training rests on.
- Solve two equations in two unknowns by substitution and by elimination
- See the solution as the point where two lines cross, and name the three possible outcomes
- Check a pair of values in both equations, and eliminate with a few lines of Python
- Find the line through two data points exactly, and see why three points need a fitted line
The math: two facts, two numbers
Purpose. Pin down two unknown numbers with two facts about them.
The puzzle above is two equations: x + y = 10 and x − y = 2. Each on its own has endless answers: 9 and 1, 7 and 3, 6 and 4 all add to 10. Each equation is a line of all its answers. The pair that fits both is where the two lines cross.
There are two ways to find it.
- Substitution: rearrange one equation for one letter, then put that into the other. Now there's one equation with one unknown, which you already know how to solve.
- Elimination: add or take away whole equations so that one letter cancels out.