Sub topic 9
Graphing a Line from Each Form
This chapter assumes you can plot points on the coordinate plane, read slope as rise over run, and solve a linear equation for one variable. It also assumes you are comfortable with fractions and negative numbers. You already know how to graph from y = mx + b. Here you will do the same job from point-slope form and standard form.
Every graph of a line rests on one fact: two distinct points determine a line. Each form gives you those two points in a different way.
The common plan
Whatever form you start with, the steps are the same.
- Find one point that is easy to read from the equation.
- Find a second point, using the slope or a second easy point.
- Plot both points and draw the line through them.
- Check with a third point, or by substituting into the original equation.
Graphing from point-slope form
Point-slope form is y - y1 = m(x - x1). The point (x1, y1) is built into the equation, so you can plot it at once. The slope then gives you the next point.
Take y + 2 = -(3/4)(x - 1).
- Rewrite y + 2 as y - (-2). The sign flips, so y1 = -2. The x part is x - 1, so x1 = 1. The point is (1, -2).
- The slope is -3/4. Read it as a rise of -3 for a run of 4.
- From (1, -2), go right 4 and down 3 to reach (5, -5). Go left 4 and up 3 to reach (-3, 1).
- Draw the line through the three points.
Moving in the opposite direction, left 4 and up 3, keeps you on the line. This is useful when the next point to the right falls off your graph paper.
When the slope is a whole number or a fraction
Write any slope as rise/run before you step. A slope of 2 is 2/1, so you go right 1 and up 2. A slope of -3/4 can be read as -3/4 (down 3, right 4) or as 3/-4 (up 3, left 4). Both land on the line.
Graphing from standard form
Standard form is Ax + By = C. It does not show a point or a slope directly. The easiest points to extract are the intercepts, where the line crosses an axis.
- y-intercept: set x = 0 and solve. You get y = C/B, so the point is (0, C/B).
- x-intercept: set y = 0 and solve. You get x = C/A, so the point is (C/A, 0).
Take 3x + 2y = 12.
- Set x = 0: 2y = 12, so y = 6. The point is (0, 6).
- Set y = 0: 3x = 12, so x = 4. The point is (4, 0).
- Plot both points and draw the line through them.
- Check with the slope. Going from (0, 6) to (4, 0) gives a rise of -6 for a run of 4, which is -3/2. Solving for y gives y = -(3/2)x + 6, which agrees.
A third check point comes from choosing x = 2. Then 6 + 2y = 12, so y = 3. The point (2, 3) lies on your line.
When the intercepts are awkward
Not every standard-form line has pleasant intercepts. Take 2x - 3y = 5.
- x-intercept: x = 5/2.
- y-intercept: y = -5/3.
Both are fractions, and fractions are hard to plot accurately. Instead, pick x values that make y a whole number. You want 2x - 5 to be divisible by 3.
- x = 1 gives -3y = 3, so y = -1. The point is (1, -1).
- x = 4 gives -3y = -3, so y = 1. The point is (4, 1).
Two points are enough to draw the line. These two are 3 apart in x, which matches the slope of 2/3.
The line through the origin
When C = 0, as in x - 2y = 0, both intercepts are the same point, (0, 0). That gives you only one point, so you need another.
- Let x = 2: 2 - 2y = 0, so y = 1. The point is (2, 1).
Draw the line through (0, 0) and (2, 1). The slope is 1/2.
Horizontal and vertical lines
Two special cases of standard form need no calculation.
- If A = 0, the equation is By = C, which gives y = C/B. This is a horizontal line. For example, 0x + 2y = 8 simplifies to y = 4. It has a y-intercept at (0, 4) and no x-intercept.
- If B = 0, the equation is Ax = C, which gives x = C/A. This is a vertical line. For example, 2x = -6 simplifies to x = -3. It has an x-intercept at (-3, 0) and no y-intercept.
Intercept logic confirms this. For y = 4, setting y = 0 gives the false statement 0 = 4, so the line never meets the x-axis. For x = -3, setting x = 0 gives -3 = 0, which is also false.
A vertical line has an undefined slope, so it has no point-slope form and no slope-intercept form. Graph it by drawing a vertical line through the stated x value.
Comparing the routes
| Form | First point | Second point | Watch for |
|---|---|---|---|
| Point-slope | (x1, y1) read from the equation | Step by run and rise from the first point | Sign flips in y - y1 and x - x1 |
| Slope-intercept | (0, b) | Step by run and rise from (0, b) | A slope written as a fraction of negatives |
| Standard | (0, C/B) | (C/A, 0) | Fractional intercepts, C = 0, A = 0 or B = 0 |
Checking the result by computer
You can verify a graphing plan with a few lines of Python. The script below generates points from a point and a slope, finds intercepts from standard form, and confirms the points satisfy the equation. It uses exact fractions so there is no rounding.
from fractions import Fraction
def points_from_point_slope(x1, y1, m):
"""Return three integer-friendly points on the line through (x1, y1)."""
m = Fraction(m)
run, rise = m.denominator, m.numerator
return [(x1 - run, y1 - rise), (x1, y1), (x1 + run, y1 + rise)]
def intercepts(a, b, c):
"""Return the intercepts of Ax + By = C that exist."""
found = {}
if a != 0:
found["x"] = (Fraction(c, a), Fraction(0))
if b != 0:
found["y"] = (Fraction(0), Fraction(c, b))
return found
def on_line(a, b, c, point):
x, y = point
return a * x + b * y == c
# y - 1 = (2/3)(x - 4) is the same line as 2x - 3y = 5
pts = points_from_point_slope(4, 1, Fraction(2, 3))
print(pts)
print(all(on_line(2, -3, 5, p) for p in pts))
# 3x + 2y = 12 has easy intercepts
for axis, (x, y) in intercepts(3, 2, 12).items():
print(f"{axis}-intercept: ({x}, {y})")
# A horizontal line has only a y-intercept
print(intercepts(0, 2, 8))The first print shows the three points (1, -1), (4, 1) and (7, 3). The check prints True, because each point satisfies 2x - 3y = 5. The intercepts of 3x + 2y = 12 come out as (4, 0) and (0, 6). The horizontal line 0x + 2y = 8 returns only a y-intercept, at (0, 4).
Common errors when graphing
- Dropping the sign of a coordinate. Reading y + 2 as y1 = 2 puts the point on the wrong side of the x-axis.
- Swapping rise and run. A slope of 2/3 means up 2 and right 3. Going up 3 and right 2 produces a steeper line.
- Mixing up the intercepts. The x-intercept comes from setting y = 0, and the y-intercept from setting x = 0.
- Plotting a fractional intercept by eye. An inaccurate point tilts the whole line. Use whole-number points instead.
- Plotting only two points and never checking. A third point catches arithmetic slips, because three correct points are collinear and a wrong one is not.
Exercises
Exercise
Graph y - 5 = -2(x + 1). Give the starting point and two more points on the line.
Show answer
Rewrite x + 1 as x - (-1), so the point is (-1, 5). The slope -2 is -2/1, so go right 1 and down 2 to reach (0, 3). Go right 1 and down 2 again to reach (1, 1). Check that (1, 1) fits: 1 - 5 = -4, and -2(1 + 1) = -4.
Exercise
Graph 4x - 5y = 20 using its intercepts, then give a third point to check the line. Then say what changes for 4x - 5y = 0.
Show answer
Setting x = 0 gives -5y = 20, so y = -4 and the point is (0, -4). Setting y = 0 gives 4x = 20, so x = 5 and the point is (5, 0). For a check, let x = 10: 40 - 5y = 20, so y = 4 and (10, 4) lies on the line. For 4x - 5y = 0 both intercepts are (0, 0), so you need another point, such as x = 5, which gives y = 4, the point (5, 4).
Exercise
Why can you graph x = -3 and y = 4 without any calculation, and why is there no point-slope form for x = -3?
Show answer
Each equation fixes one coordinate for every point on the line. x = -3 is the vertical line through (-3, 0), and y = 4 is the horizontal line through (0, 4). The vertical line has an undefined slope, and point-slope form needs a numeric slope m.