Systems of Equations

Solving Systems by Graphing

To solve a system by graphing, draw both lines on the same axes and read the point where they cross: that ordered pair (x,y)(x, y) satisfies both equations. For y=m1x+b1y = m_1x + b_1 and y=m2x+b2y = m_2x + b_2, the crossing sits at x=b2−b1m1−m2x = \dfrac{b_2 - b_1}{m_1 - m_2}.

x=b2−b1m1−m2x = \frac{b_2 - b_1}{m_1 - m_2}

Try it with your numbers

Show every step

Graphing is slower than algebra for exact answers, but it is the one method that shows you the whole system at once: whether the lines cross, run parallel, or lie on top of each other, before any arithmetic. The sections below cover fast sketching, where the crossing formula comes from, the check that catches bad readings, and the point where substitution or elimination should take over.

How does solving systems by graphing work?

A line is a picture of every solution to one equation. Each point on y=2x−1y = 2x - 1 makes that equation true, and nothing off the line does. Two equations draw two lines, so a point sitting on both lines makes both equations true at the same moment. That shared point is the intersection, and it is the solution.

This turns an algebra question into a geometry question: which points live on both lines? The answer can be one point, none, or all of them, and the graph shows which case you are in before you do any calculation.

The method has five moves:

  1. Rewrite each equation in a form that is easy to graph.
  2. Plot both lines on the same axes, using a ruler and one shared scale.
  3. Decide whether the lines cross, run parallel, or coincide.
  4. Read the crossing as an ordered pair, xx first, then yy.
  5. Substitute that pair into both original equations.

The last move is not optional. A point read from a sketch is a guess until it passes both equations.

How do you graph each line for a system?

If an equation reads y=mx+by = mx + b, plot (0,b)(0, b) and step mm units up (or down) for every 1 unit right. That is the whole idea behind slope-intercept form. If you are handed a slope and a point instead, point-slope form gives you the same line in one step.

For standard form ax+by=cax + by = c, skip the rearranging and use intercepts. Set x=0x = 0 to get the y-intercept cb\frac{c}{b}, set y=0y = 0 to get the x-intercept ca\frac{c}{a}, and draw through those two points. This avoids fraction slopes entirely. The one trap: when c=0c = 0, both intercepts are the origin, so you must find a second point.

Example 1. Solve 2x+3y=122x + 3y = 12 and x−y=1x - y = 1 by graphing.

Line one: if x=0x = 0, then 3y=123y = 12 and y=4y = 4. If y=0y = 0, then 2x=122x = 12 and x=6x = 6. It passes through (0,4)(0, 4) and (6,0)(6, 0).

Line two: if x=0x = 0, then −y=1-y = 1 and y=−1y = -1. If y=0y = 0, then x=1x = 1. It passes through (0,−1)(0, -1) and (1,0)(1, 0).

Draw both lines well past where they seem to meet. They cross at (3,2)(3, 2). Check in the original equations:

2(3)+3(2)=123−2=12(3) + 3(2) = 12 \qquad 3 - 2 = 1

Both hold, so the solution is (3,2)(3, 2).

Quick check

Find the x-intercept and y-intercept of 4x+5y=204x + 5y = 20.

Where does the crossing-point formula come from?

At the crossing, both lines have the same xx and the same yy. So their yy-values must be equal there, which means you can set the two right-hand sides equal and solve for xx:

m1x+b1=m2x+b2  ⇒  (m1−m2)x=b2−b1  ⇒  x=b2−b1m1−m2m_1x + b_1 = m_2x + b_2 \;\Rightarrow\; (m_1 - m_2)x = b_2 - b_1 \;\Rightarrow\; x = \frac{b_2 - b_1}{m_1 - m_2}

Then substitute that xx into either line to get yy. The formula fails exactly when m1=m2m_1 = m_2, because the denominator becomes zero. Equal slopes mean the lines are parallel or identical, so there is no single crossing to find.

Sign check for a sketch

The line with the larger slope sits lower than the other line to the left of the crossing and higher to the right. If your sketch disagrees, a slope sign is wrong.

Example 2. Solve y=−12x+4y = -\tfrac{1}{2}x + 4 and y=32x−2y = \tfrac{3}{2}x - 2.

The slope difference is −12−32=−2-\tfrac{1}{2} - \tfrac{3}{2} = -2, and the intercept difference is −2−4=−6-2 - 4 = -6:

x=−6−2=3,y=−12(3)+4=52x = \frac{-6}{-2} = 3, \qquad y = -\tfrac{1}{2}(3) + 4 = \tfrac{5}{2}

The solution is (3,52)\left(3, \tfrac{5}{2}\right). On paper, line one runs through (0,4)(0,4), (2,3)(2,3), (4,2)(4,2) and line two through (0,−2)(0,-2), (2,1)(2,1), (4,4)(4,4). At x=2x = 2 line one is above; at x=4x = 4 it is below. That flip tells you the crossing lies between them, and x=3x = 3 is the midpoint. Check in line two: 32(3)−2=52\tfrac{3}{2}(3) - 2 = \tfrac{5}{2}.

How many solutions can a graphed system have?

Two lines can relate in only three ways, and the slopes and intercepts tell you which before you draw anything.

Slopes y-intercepts Result
Different Any Cross once: one solution
Same Different Parallel: no solution
Same Same Same line: infinitely many

The deeper story of the last two rows lives in no solution vs infinitely many solutions. Here the practical point is that disguised equations fool the eye. The equations 4x−2y=64x - 2y = 6 and 2x−y=32x - y = 3 look different, yet one is double the other, so they draw a single line.

For two equations in standard form, a1x+b1y=c1a_1x + b_1y = c_1 and a2x+b2y=c2a_2x + b_2y = c_2, there is a fast test. Compute a1b2−a2b1a_1b_2 - a_2b_1, which is a 2×2 determinant. If it is not zero, the lines have different slopes and cross exactly once. For Example 1 it gives 2(−1)−1(3)=−52(-1) - 1(3) = -5, so a single crossing was guaranteed. If it is zero, the slopes match, and the intercepts decide between parallel and identical.

Try this: Without drawing anything, decide how many solutions 4x−2y=64x - 2y = 6 and y=2x−3y = 2x - 3 have. Rewrite the first equation as y=mx+by = mx + b and compare.

How do you check a solution after graphing a system?

Graph of x + y = 6 and x - y = 2 showing (5, 1) fails but (4, 2) works
The point (5, 1) lies on x + y = 6 but fails x - y = 2, while the true crossing (4, 2) satisfies both.

Substitute the point into both original equations, not the rewritten versions. If you made an error while rearranging, checking the rewritten form hides it.

The trap that costs the most points is checking only one equation. Suppose a sketch of x+y=6x + y = 6 and x−y=2x - y = 2 seems to cross near (5,1)(5, 1). Test it:

5+1=6  ✓5−1=4≠25 + 1 = 6 \;\checkmark \qquad 5 - 1 = 4 \neq 2

The point lies on the first line, which is why it looked plausible near the crossing, but it fails the second. The true solution is (4,2)(4, 2): 4+2=64 + 2 = 6 and 4−2=24 - 2 = 2.

A second, faster check works on any sketch: read the point’s coordinates, then ask whether the numbers fit the slope you drew. If a line has slope 22 and passes through (0,1)(0, 1), then the point at x=3x = 3 must have y=7y = 7. A reading that breaks this relationship means the line was drawn crookedly, not that the solution is odd.

Quick check

Does (2,1)(2, 1) solve the system x+3y=5x + 3y = 5 and 2x−y=42x - y = 4?

Solving systems by graphing when the answer is not a whole number

Graph of y = 3x - 1 and y = -2x + 3 crossing at (0.8, 1.4) between grid lines
The lines swap order between x = 0 and x = 1, so they cross at (0.8, 1.4), not at the tempting guess (1, 1).

Many crossings fall between grid lines. Graphing then gives an estimate, and the algebra gives the exact value. Use the graph to see where the answer lives, then compute.

Example 3. Solve y=3x−1y = 3x - 1 and y=−2x+3y = -2x + 3.

Compare heights at whole numbers. At x=0x = 0, line one is at −1-1 and line two at 33, so line two is above. At x=1x = 1, line one is at 22 and line two at 11, so line one is above. The order flips between 00 and 11, so the crossing is there. Now use the formula:

x=3−(−1)3−(−2)=45,y=3(45)−1=75x = \frac{3 - (-1)}{3 - (-2)} = \frac{4}{5}, \qquad y = 3\left(\frac{4}{5}\right) - 1 = \frac{7}{5}

The solution is (45,75)\left(\tfrac{4}{5}, \tfrac{7}{5}\right), or (0.8,1.4)(0.8, 1.4). A tempting guess is (1,1)(1, 1), but 3(1)−1=23(1) - 1 = 2, not 11. Check the exact answer in line two: −2(45)+3=75-2\left(\tfrac{4}{5}\right) + 3 = \tfrac{7}{5}.

Technology removes the estimating. In Desmos, type both equations and click the crossing to see its coordinates. On a TI-84, graph both, then press 2nd, CALC, and choose intersect. One warning: lines with nearly equal slopes can cross far outside your window. The lines y=xy = x and y=1.02x−3y = 1.02x - 3 look parallel on a standard screen, yet they meet at (150,150)(150, 150).

Can you solve nonlinear systems by graphing?

Yes, and graphing is often the clearest way to see how many solutions exist. Graph each curve and mark every crossing. A line and a parabola can meet twice, once, or never.

For y=x2y = x^2 and y=x+2y = x + 2, the curves cross at (−1,1)(-1, 1) and (2,4)(2, 4). Algebra confirms it: x2=x+2x^2 = x + 2 gives x2−x−2=0x^2 - x - 2 = 0, which factors as (x−2)(x+1)=0(x - 2)(x + 1) = 0. Both points check: 4=2+24 = 2 + 2 and 1=−1+21 = -1 + 2.

The tangent case

If a line only touches a parabola, the system has exactly one solution. For y=x2y = x^2 and y=2x−1y = 2x - 1, the equation x2−2x+1=0x^2 - 2x + 1 = 0 gives only x=1x = 1, so the single solution is (1,1)(1, 1).

When the crossings are not tidy, the graph is only a map. With y=x2y = x^2 and y=x+1y = x + 1, you get x2−x−1=0x^2 - x - 1 = 0, so x=1±52x = \frac{1 \pm \sqrt{5}}{2}, about 1.621.62 and −0.62-0.62. No hand-drawn graph reads those cleanly, but the quadratic formula does.

Where does graphing a system show up in real life?

Whenever two quantities change at steady rates and you want to know when they match, you are solving a system. The slope is the rate, the y-intercept is the starting amount, and the crossing is the break-even moment.

Say Plan A charges a $20 membership plus $5 per visit, so y=20+5xy = 20 + 5x, and Plan B charges $10 per visit with no fee, so y=10xy = 10x. Setting them equal gives 20+5x=10x20 + 5x = 10x, so x=4x = 4 and y=40y = 40. At 4 visits both cost $40. Check: 20+5(4)=4020 + 5(4) = 40 and 10(4)=4010(4) = 40.

The graph tells you more than the number does. Left of the crossing, Plan B’s line is lower, so it is cheaper. Right of the crossing, Plan A wins. The same structure appears in supply and demand (the crossing is the market price), in two travelers moving at different speeds (the crossing is where they meet), and in mixture problems. In real problems, choose axes from the context: negative visits make no sense, so the graph starts at zero.

Quick check

Plan A costs y=15+3xy = 15 + 3x dollars and Plan B costs y=6xy = 6x dollars for xx visits. At how many visits do the plans cost the same?

When should you switch to substitution or elimination?

Switch whenever you need an exact answer and the crossing is not clearly on a grid point. Graphing builds understanding and catches structure; algebra delivers precision. The best habit is to use both: solve algebraically, then sketch quickly to confirm the answer is in the right neighborhood.

Graphing never goes away, though. Every algebraic method is an exact way of locating the same crossing point you can see on the graph.

Practice problems

0 of 5 solved

  1. Solve by graphing: y=x+1y = x + 1 and y=−x+5y = -x + 5.

  2. Solve by graphing: y=34x+1y = \frac{3}{4}x + 1 and y=−12x+6y = -\frac{1}{2}x + 6.

  3. Solve by graphing: 2x+y=42x + y = 4 and x−y=5x - y = 5.

  4. How many solutions does 6x−3y=96x - 3y = 9 and y=2x+1y = 2x + 1 have?

  5. Find the exact solution of 2x+3y=72x + 3y = 7 and x−y=−1x - y = -1.

Common questions

How do you solve a system of equations by graphing?

Graph both equations on the same axes, find the point where the lines cross, and write it as an ordered pair (x,y)(x, y). Then substitute that pair into both original equations to confirm it works in each.

What does it mean if the two lines are parallel?

Parallel lines have the same slope and different y-intercepts, so they never meet. No point satisfies both equations, which means the system has no solution.

What if both equations graph as the same line?

Every point on the line satisfies both equations, so the system has infinitely many solutions. Such a system is called dependent, and the answer is described by the line itself, such as y=2x−3y = 2x - 3.

Is solving systems by graphing accurate?

It is exact only when the crossing point lands on grid points you can verify. When the intersection falls between grid lines, treat the graph as an estimate and finish with substitution, elimination, or a formula.

How do you graph an equation in standard form for a system?

Find the intercepts: set x=0x = 0 to get the y-intercept and y=0y = 0 to get the x-intercept, then draw a line through those two points. If the constant term is 00, both intercepts are the origin, so pick one more point.

Can a graphing calculator or Desmos solve a system?

Yes. Enter both equations as yy in terms of xx, graph them, and use the intersect feature (or click the crossing point in Desmos) to read the coordinates. Still check the result in both original equations.

Up next