Finding the equation of a line
Finding the equation of a line from the gradient and a point, from two points, and from a graph, using y = mx + c or y − y₁ = m(x − x₁).
In the last section you started with an equation and drew the line. Now reverse it: given some facts about a line, write its equation. It is how you turn two measurements, like a taxi fare for two trip lengths, into a rule that predicts the rest.
Gradient and one point
Every non-vertical line can be written $y = mx + c$. If you know $m$, only $c$ is missing, and the point gives you one equation to find it.
Find the equation of the line with gradient $3$ that passes through $(2, 1)$.
There is also a formula that does the same job in one line:
For Example 1: $y - 1 = 3(x - 2)$, so $y = 3x - 6 + 1 = 3x - 5$. Same answer. It works because for any point $(x, y)$ on the line, the gradient from $(x_1, y_1)$ to $(x, y)$ is $m$: $\dfrac{y - y_1}{x - x_1} = m$. Multiply both sides by $(x - x_1)$ and you have the formula.
Two points
Two points fix a line. Use them to find the gradient first, then use either point to find $c$.
Find the equation of the line through $(1, 5)$ and $(4, -1)$.
From a graph
Read the $y$-intercept straight off the graph. For the gradient, pick two points where the line crosses grid corners exactly, and count the rise and run between them.
A line crosses the $y$-axis at $2$ and the $x$-axis at $3$. Find its equation.
Your turn
A water tank is draining at a steady rate. After $3$ minutes it holds $340$ L, and after $8$ minutes it holds $240$ L. Find a rule for the volume $V$ after $t$ minutes, and how much was in the tank at the start.
Show the working
Gradient: $m = \dfrac{240 - 340}{8 - 3} = \dfrac{-100}{5} = -20$ L per minute. Then $340 = -20(3) + c$, so $c = 400$. The rule is $V = -20t + 400$, and the tank started with $400$ L.
A line has gradient $2$ and passes through $(0, -3)$. Its equation is $y = 2x + c$. Find $c$.
$(0, -3)$ is the $y$-intercept, so $c = -3$.
A line has gradient $4$ and passes through $(1, 7)$. Find $c$ in $y = 4x + c$.
$7 = 4(1) + c$, so $c = 3$.
A line has gradient $-2$ and passes through $(3, 1)$. Find $c$ in $y = -2x + c$.
$1 = -2(3) + c = -6 + c$, so $c = 7$.
The line through $(2, 5)$ and $(4, 9)$ is:
$m = \dfrac{9 - 5}{4 - 2} = 2$. Then $5 = 2(2) + c$, so $c = 1$.
Find the $y$-intercept of the line through $(-1, 6)$ and $(3, -2)$.
$m = \dfrac{-2 - 6}{3 - (-1)} = -2$. Then $6 = -2(-1) + c = 2 + c$, so $c = 4$.
A line has $x$-intercept $4$ and $y$-intercept $8$. Find its gradient.
From $(0, 8)$ to $(4, 0)$: $m = \dfrac{0 - 8}{4 - 0} = -2$.
The line with gradient $3$ through $(5, -2)$ in point-gradient form is:
$y - y_1 = m(x - x_1)$ with $y_1 = -2$ and $x_1 = 5$: $y - (-2) = 3(x - 5)$, which is $y + 2 = 3(x - 5)$.
The horizontal line through $(3, -4)$ has equation $y = k$. Find $k$.
A horizontal line has gradient $0$, so every point has the same $y$ value as $(3, -4)$: $y = -4$.
Challenge: Find the $x$-intercept of the line through $(-2, 1)$ and $(4, 4)$.
$m = \dfrac{4 - 1}{4 - (-2)} = \dfrac36 = \dfrac12$. Then $1 = \tfrac12(-2) + c$, so $c = 2$ and $y = \tfrac12 x + 2$. For the $x$-intercept, $0 = \tfrac12 x + 2$, so $x = -4$.
Challenge: A plumber charges a fixed call-out fee plus an hourly rate. A $2$ hour job costs $\$203.60$ and a $5$ hour job costs $\$443.60$. Find the call-out fee in dollars.
Gradient (rate per hour): $\dfrac{443.60 - 203.60}{5 - 2} = \dfrac{240}{3} = 80$. Then $203.60 = 80(2) + c$, so $c = 43.60$. Check: $80(5) + 43.60 = 443.60$. The call-out fee is $\$43.60$.
Coaching Centre