Straight line graphs
Gradient, intercept, y = mx + c, and parallel and perpendicular lines.
Learning objectives
What you need to be able to do
Teacher-mapped phrasing — check against the official Cambridge syllabus for exact wording.
- 3.1.1Find the gradient and equation of a straight line and interpret y = mx + c.
- 3.1.2Determine the conditions for lines to be parallel or perpendicular.Supplement
6 minute read
Straight line graphs
The equation of a straight line
y = mx + c where m is the gradient and c is the y-intercept — where the line crosses the y-axis.
Gradient
m = (y₂ − y₁) / (x₂ − x₁) — the change in y divided by the change in x, often remembered as "rise over run".
- A positive gradient slopes upward from left to right.
- A negative gradient slopes downward.
- A steeper line has a larger magnitude of gradient.
Take the coordinates in the same order on top and bottom. Swapping one but not the other flips the sign.
Finding the equation from two points
- Calculate the gradient m.
- Substitute m and one point into
y = mx + cand solve for c. - Write the full equation.
Parallel and perpendicular
- Parallel lines have equal gradients: m₁ = m₂.
- Perpendicular lines have gradients whose product is −1:
m₁ × m₂ = −1, so m₂ is the negative reciprocal of m₁.
If a line has gradient 2, a perpendicular line has gradient −1/2. If it has gradient −3/4, a perpendicular line has gradient 4/3.
Midpoint and length
- Midpoint = the mean of the coordinates:
((x₁+x₂)/2, (y₁+y₂)/2). - Length by Pythagoras:
√((x₂−x₁)² + (y₂−y₁)²).
Think of it like this
The negative reciprocal makes sense physically: turning a slope through 90° swaps how far you go across with how far you go up, and reverses the direction — which is exactly "flip the fraction and change the sign".
Worked examples
Method, step by step
Find the equation of the line passing through (1, 5) and (3, 11).
- 1Gradient m = (11 − 5) / (3 − 1) = 6/2 = 3.
- 2Substitute m = 3 and the point (1, 5) into y = mx + c: 5 = 3(1) + c.
- 3So c = 2.
- 4The equation is y = 3x + 2. Check with (3, 11): 3(3) + 2 = 11 ✓
y = 3x + 2
A line has equation y = 4x − 7. Find the gradient of a line perpendicular to it.
- 1The gradient of the given line is m₁ = 4.
- 2Perpendicular gradients satisfy m₁ × m₂ = −1.
- 3So m₂ = −1/4.
−1/4
Common misconceptions
- Calculating gradient as change in x over change in y. It is always **y over x**.
- Saying perpendicular gradients are just negatives of each other. The gradient perpendicular to 2 is −1/2, not −2.
- Reading the y-intercept off a graph without checking the scale on the axes.
In the exam
- When finding a line through two points, always verify by substituting the *other* point at the end — it should satisfy the equation.
- Rearrange any equation into y = mx + c form before comparing gradients; `2y = 6x + 4` has gradient 3, not 6.