SME
Grade 8 Math · Problem type
The equation from two points
Use this for “A line passes through (1, 3) and (2, 5). What is its equation?”
Chart
y₂ = 2x₂ + 1
Slope m = 2: up 2 for every 1 across
Intercept b = 1: it crosses the y-axis at (0, 1)
y₂ = 2 × 2 + 1 = 5 when x₂ = 2
This is an example. Type your own values to start a new problem.
y
=
m
x
+
b
x₁
First x
example
y₁
First y
example
x₂
Second x
example
y₂
Second y
example
Formulas
m
=
(
y₂
−
y₁
)
÷
(
x₂
−
x₁
)
(slope
=
(second
y
−
first
y)
÷
(second
x
−
first
x))
2 = (5 − 3) ÷ (2 − 1)
b
=
y₁
−
m
×
x₁
(y-intercept
=
first
y
−
slope
×
first
x)
1 = 3 − 2 × 1
Assumptions
•
The slope is the change in y divided by the change in x between the two points.
•
Then b = y − m × x at either point: go back along the line to x = 0.
•
The equation is y = mx + b.
Step-by-step
WE KNOW
x₁ = 1 (first x), y₁ = 3 (first y), x₂ = 2 (second x), y₂ = 5 (second y)
FIND
slope (m), y-intercept (b)
Step 1 · Find slope (m)
Use m = (y₂ − y₁) ÷ (x₂ − x₁) (slope = (second y − first y) ÷ (second x − first x))
The rise over the run between the two points.
m
=
5 − 3
2 − 1
m
=
2
1
m
=
2
Step 2 · Find y-intercept (b)
Use b = y₁ − m × x₁ (y-intercept = first y − slope × first x)
From
the
first
point,
go
back
x₁
steps
of
the
slope
to
x
=
0.
b
=
3
−
2
×
1
b
=
3
−
2
b
=
1
Check
Put the numbers back in. Both sides should match.
2 = (5 − 3) ÷ (2 − 1) ✓
1 = 3 − 2 × 1 ✓
Topic check
See what you know: 5 questions on this topic
New questions each time. Pass to mark it complete.
Refresh
Nothing to review first. This is a starting point.
Related lessons
Linear functions (y = mx + b)
Main lesson
Slope and intercept in a story
Use this for “A bike rental costs $8 plus $3 an hour. What do 5 hours cost, and what do the 8 and the 3 mean?”
Lines written ax + by = c
Use this for “A snack mix uses nuts at $4 a pound and raisins at $2 a pound; $16 in all” or “(4, y) is on 3x + 4y = 24: find y.”
Linear or not?
Use this for “Is the area of a square a linear function of its side?”