Gradient and Equation of a Line
Key Ideas
Key Terms
- gradient formula
- M = (y2 − y1) ÷ (x2 − x1), using any two points on the line.
- Positive gradient
- Line rises from left to right (m > 0).
- Negative gradient
- Line falls from left to right (m < 0).
- Zero gradient
- Horizontal line (m = 0), equation y = c.
- Undefined gradient
- Vertical line; run = 0 — equation x = c.
- y = mx + c
- Where m is the gradient and c is the y-intercept.
| Formula | Use |
|---|---|
| m = (y2 − y1) ÷ (x2 − x1) | Find gradient from two points |
| y = mx + c | Gradient-intercept form; m = gradient, c = y-intercept |
| y − y1 = m(x − x1) | Find equation from a point and gradient |
Types of gradient
Worked Example
Question: Find the equation of the line passing through (2, 5) with gradient 3.
Step 1: y − y1 = m(x − x1) ⇒ y − 5 = 3(x − 2)
Step 2: y − 5 = 3x − 6 ⇒ y = 3x − 1
Check: Sub (2, 5): y = 3(2) − 1 = 5. ✓
Calculating Gradient from Two Points
The gradient of a line measures how steep it is. Given two points (x1, y1) and (x2, y2), the gradient is calculated using the formula: m = (y2 − y1) / (x2 − x1). This is "rise over run" — the vertical change divided by the horizontal change. For example, for the points (1, 3) and (5, 11): m = (11 − 3) / (5 − 1) = 8 / 4 = 2. It does not matter which point you label as 1 or 2, as long as you are consistent in both the numerator and denominator.
A positive gradient means the line goes up from left to right. A negative gradient means it goes down. A gradient of zero means horizontal. Undefined gradient means vertical.
Writing the Equation y = mx + b
Once you know the gradient m, you can find the full equation of the line by substituting a known point into y = mx + b and solving for b. For example, if m = 2 and the line passes through (1, 5): substitute to get 5 = 2(1) + b, so b = 3. The equation is y = 2x + 3. You can verify this by checking the other known point satisfies the equation.
Parallel Lines
Two lines are parallel if they never intersect — they run in exactly the same direction. Parallel lines always have equal gradients. For example, y = 3x + 1 and y = 3x − 4 are parallel because both have m = 3. Note that parallel lines have different y-intercepts (otherwise they would be the same line). In problems, if you are told a line is parallel to another, you can immediately use the same gradient value.
Perpendicular Lines
Two lines are perpendicular if they meet at a right angle (90°). The gradients of perpendicular lines satisfy the rule: m1 × m2 = −1. This means the gradients are negative reciprocals of each other. For example, if one line has m = 2, a perpendicular line has m = −1/2 (flip and negate). Check: 2 × −1/2 = −1. ✓
Putting It All Together
Coordinate geometry questions often combine these ideas: for example, "Find the equation of a line passing through (2, 1) that is parallel to y = 4x − 3." Step 1: parallel means same gradient, so m = 4. Step 2: substitute into y = 4x + b using (2, 1): 1 = 4(2) + b, so b = 1 − 8 = −7. Answer: y = 4x − 7. Similarly for perpendicular: take the negative reciprocal of the given gradient, then substitute the point.
Mastery Practice
-
Calculate the gradient of the line passing through each pair of points. Fluency
Point 1 Point 2 Gradient m (a) (1, 3) (3, 7) (b) (0, 5) (4, 13) (c) (2, 8) (6, 4) (d) (−1, 2) (3, 10) (e) (−3, 4) (1, −4) (f) (2, −1) (2, 6) (g) (−4, 3) (2, 3) (h) (−2, −5) (4, 7) -
Identify the gradient and y-intercept for each equation in y = mx + c form. Fluency
Equation Gradient m y-intercept c (a) y = 4x + 3 (b) y = −2x + 7 (c) y = x − 5 (d) y = ½x (e) y = −3x − 4 (f) y = 6 (g) 2y = 6x − 4 (h) y + 3x = 8 -
Write the equation of the line in y = mx + c form given each gradient and y-intercept. Fluency
Gradient m y-intercept c Equation (a) 3 5 (b) −2 0 (c) ½ −3 (d) 0 7 (e) −4 2 (f) ¾ 1 (g) 5 −6 (h) −1 4 -
State whether each statement is True or False. If false, write the correct statement. Fluency
- A horizontal line has a gradient of zero.
- A vertical line has a gradient of zero.
- The gradient of the line through (0, 0) and (4, 8) is 2.
- In y = −3x + 5, the gradient is 5 and the y-intercept is −3.
- Two lines with the same gradient are always the same line.
- A steeper line always has a larger gradient value.
-
Interpret the gradient in each context. Understanding
Rate of Change. The gradient of a linear graph equals the rate of change of the quantity on the y-axis with respect to the x-axis quantity.Graph for Q5(a) Graph for Q5(c) - A line has equation C = 12t + 25, where C is cost in dollars and t is time in hours. What does the gradient 12 represent?
- The gradient of a ramp is 0.08. Does the ramp slope upward or downward left-to-right? Express the gradient as a percentage grade.
- A line through (0, 0) and (5, −20) represents the depth of a diver (metres) versus time (seconds). Calculate and interpret the gradient.
- A horizontal line passes through (0, 4). Write its equation and state its gradient. Give a real-world example of a zero-gradient relationship.
-
Steepness and real-world gradients. Understanding
Comparing Slopes. The absolute value of a gradient tells you how steep the line is, regardless of direction. A larger absolute value means a steeper line.- Line A passes through (0, 0) and (4, 12). Line B passes through (1, 5) and (3, 9). Line C passes through (−2, 10) and (2, 2). Calculate the gradient of each line and arrange them flattest to steepest.
- Three ramps have gradients of 0.05, 0.2, and 0.5. Which ramp is steepest and which is most accessible (flattest)?
-
Find the equation of the line with the given gradient passing through the given point. Write your answer in y = mx + c form. Understanding
Point-Gradient Method. Use y − y1 = m(x − x1), then rearrange to y = mx + c.- m = 2, through (1, 5)
- m = −3, through (2, 4)
- m = 4, through (0, −7)
- m = ½, through (4, 3)
- m = −1, through (−2, 6)
- m = 5, through (3, 0)
-
Arrange these lines from flattest to steepest (use absolute value of gradient). Justify your order. Understanding
Steepness. Steepness depends on |m|, not the sign. A line with m = −5 is steeper than one with m = 2.- y = 6x − 1, y = ⅓x + 4, y = −4x + 2
- Line through (0,0) and (3, 9); line with m = −2; line through (1,1) and (5, 3)
-
Problem solving with gradient. Problem Solving
Road and Geometry Problems. Apply gradient concepts to solve multi-step problems.- A straight road rises 120 m vertically over a horizontal distance of 1500 m. Calculate the gradient of the road. Express it as a decimal and as a percentage grade.
- Two points on a line are (k, 3) and (4, 11). If the gradient is 2, find the value of k.
- A line has gradient 3 and passes through the midpoint of (0, 2) and (4, 8). Find the equation of the line.
-
Equations in context. Problem Solving
Real-World Linear Models. Use gradient and intercept to model and interpret practical situations.- A vertical line and a horizontal line intersect at (5, −3). Write the equations of both lines. Explain why the gradient of the vertical line is undefined.
- A ski slope drops 80 m vertically over a horizontal run of 400 m. Write the equation of the slope in the form y = mx + c if it starts at (0, 80). What does the gradient mean in this context?
- A line passes through (1, 7) and has the same gradient as the line y = −2x + 3. Find its equation. Then find where this line crosses the x-axis.