When Lines Collide
You already know how to graph a line using y = mx + b. But what happens when you put two lines on the same graph? Sometimes they cross, sometimes they don’t, and sometimes they’re secretly the same line all along.
This is the world of systems of equations — and it turns out that finding where two lines meet is one of the most useful skills in all of math.
Part 1: Two Lines, One Graph
Let’s start simple. Here are two lines sharing the same coordinate plane:
See where they cross? That point — (1, 3) — is special. It’s the one point that lives on both lines at the same time. Plug x = 1 into either equation and you get y = 3. That crossing point is called the solution to the system.
Think about it: A “solution” to a system of two equations is an (x, y) pair that makes both equations true at the same time. Graphically, it’s the point where the two lines intersect.
Part 2: Build Your Own Collision
Now it’s your turn. Use the sliders to control two lines and watch them interact in real time. Line 1 is purple, Line 2 is red.
Drag those sliders around. Watch the lines tilt, shift, cross, and separate. You’re controlling a whole system of equations with your fingertips.
Part 3: The Three Possible Outcomes
Every system of two linear equations falls into one of exactly three categories. Let’s explore each one.
Case 1: One Solution (Lines Cross)
When two lines have different slopes, they will always cross at exactly one point. One solution. Done.
Experiment: Try making the slopes closer and closer to each other. The intersection point slides further and further away from the center. The more similar the slopes, the further out the lines finally meet. But as long as the slopes are different, they will cross somewhere!
Case 2: No Solution (Parallel Lines)
What if the two lines have the same slope but different y-intercepts? They tilt the same way, but one is shifted up or down. They’re parallel — they never touch.
No matter how far you extend the graph, those lines never meet. There is no solution — no (x, y) pair that satisfies both equations at once. In math class, you might hear this called an inconsistent system.
Spot the pattern: Parallel lines have the same slope (m) but different y-intercepts (b). If you tried to solve the system algebraically, you’d end up with something impossible like 0 = 5. That’s math’s way of saying “nope, no solution exists.”
Case 3: Infinite Solutions (Same Line)
Here’s the wild one. What if both equations describe the exact same line? Same slope AND same y-intercept. Every single point on the line is a solution!
See how the red line sits right on top of the purple one? They’re the same line, so every point is an intersection. That’s infinitely many solutions. Math folks call this a dependent system.
Real talk: In practice, two equations that look totally different can still describe the same line. For example, y = 2x + 4 and 2y = 4x + 8 are the same line in disguise — just divide the second equation by 2. When you try to solve algebraically, you get something like 0 = 0, which is true but useless. That’s the sign of infinitely many solutions.
Part 4: Finding the Solution (The Math)
Seeing the intersection on a graph is great, but you can also calculate it exactly. Here’s the idea.
If two lines intersect, then at that point they share the same x and the same y. So you can set the two equations equal:
Solve for x:
Then plug that x back into either equation to get y. This is called the substitution method — you’re substituting one equation into the other.
Try It Live
Use the sliders below and watch the solution coordinates update automatically.
The faint teal line shows the difference between the two equations. Where it crosses the x-axis (the root) is the x-coordinate of the intersection — that’s where the two lines give the same y value.
Why does the difference line work? The difference line plots (m₁x + b₁) - (m₂x + b₂). When this equals zero, the two original equations are equal — that’s the intersection! Finding where a line crosses zero is exactly what “solving the system” means.
Part 5: Substitution vs. Elimination
There are two main algebraic strategies for solving a system. You’ve already seen substitution. Let’s compare them.
Substitution
- Solve one equation for y (or x)
- Plug that expression into the other equation
- Solve for the remaining variable
- Back-substitute to find the other variable
Example: Solve y = 2x + 1 and y = -x + 4.
Since both are solved for y, set them equal: 2x + 1 = -x + 4. Add x to both sides: 3x + 1 = 4. Subtract 1: 3x = 3. So x = 1. Plug back in: y = 2(1) + 1 = 3. Solution: (1, 3).
Elimination
- Line up the two equations
- Add or subtract them to eliminate one variable
- Solve for the remaining variable
- Back-substitute
Example: Solve 2x + y = 5 and x - y = 1.
Add the equations: 3x = 6, so x = 2. Plug back in: 2(2) + y = 5, so y = 1. Solution: (2, 1).
When to use which? If one equation already has y (or x) isolated, go with substitution — it’s quicker. If both equations are in standard form (Ax + By = C), try elimination — adding or subtracting often cancels a variable cleanly. Both methods always give the same answer!
Part 6: The Big Picture
Here’s a summary of everything you’ve learned. Use the interactive graph from Part 2 to verify each case for yourself.
| Slopes | Intercepts | Lines are… | Number of solutions |
|---|---|---|---|
| Different (m₁ ≠ m₂) | Anything | Crossing | One |
| Same (m₁ = m₂) | Different (b₁ ≠ b₂) | Parallel | None |
| Same (m₁ = m₂) | Same (b₁ = b₂) | Identical | Infinite |
Final Challenges:
- Use the Part 2 sliders to create two lines that intersect at the origin (0, 0). What must be true about both y-intercepts?
- Find a system where the solution is (2, 5). Hint: pick any two different slopes, then figure out the intercepts.
- Set up a parallel system. Now try to solve it using substitution on paper. What happens?
- Can you make a system where the intersection point has a negative x but a positive y? What quadrant is that?
Wrapping Up
A system of equations is just a question: “Where do these lines meet?” The answer is either one point, no point, or every point. You can find it by graphing, by substitution, or by elimination — all roads lead to the same answer.
Next time you see two equations stacked on top of each other, don’t panic. Just picture two lines on a graph and ask yourself: do they cross? If so, that crossing point is your answer.
Two equations. Two unknowns. One intersection. That’s the whole game.