Straight line graphs: y = mx + c, gradient, intercept and parallel and perpendicular lines
TutorAura guide · Updated
Every straight line on a graph can be written as
where is the gradient (how steep it is) and is the y-intercept (where it crosses the y-axis). Read those two numbers off an equation and you can sketch the line; read them off a graph and you can write the equation. This guide covers both directions, plus finding a line through two points and the rules for parallel and perpendicular lines.
Key takeaways
- Gradient m = change in y ÷ change in x (rise over run); c is where the line crosses the y-axis.
- Rearrange to y = mx + c before reading off m and c.
- Parallel lines have the same gradient; perpendicular gradients multiply to −1.
- Equation through two points: find m, then substitute a point to find c.
Reading the gradient and intercept
: gradient 2, y-intercept 3. For every 1 across, the line goes up 2, and it passes through .
: gradient (down 1 for every 2 across), y-intercept 1.
: gradient 4, intercept 0 (through the origin). : gradient 0, a horizontal line. is a vertical line and can't be written as .
Rearranging first
Equations aren't always given in the right form. Rearrange to before reading off anything.
: gradient 3, intercept −2.
: gradient , intercept 3.
Reading the gradient as 3 from is a common error.
Finding the gradient from two points
Through and : .
Keep the order the same on top and bottom. A line going down from left to right has a negative gradient. Our gradient calculator shows the working.
The equation of a line through two points
- Find the gradient .
- Substitute and one point into to find .
- Write the equation.
Through and : . Using : , so . Equation: . Check with the other point: ✓.
Alternatively use : , which rearranges to the same thing. Our line equation calculator does both forms.
Parallel and perpendicular lines
Parallel lines have the same gradient. A line parallel to through is .
Perpendicular lines have gradients that multiply to −1: the perpendicular gradient is the negative reciprocal, .
| Gradient | Perpendicular gradient |
|---|---|
| 2 | |
| 1 | −1 |
A line perpendicular to through : gradient , so , , equation .
Plotting a line
Make a table of three -values (three, so a mistake shows up as a point off the line), work out for each, plot and join with a ruler. For : gives .
To sketch quickly, mark the y-intercept, then use the gradient to step to a second point: from , gradient 2 means 1 across and 2 up to .
Practice questions
- State the gradient and y-intercept of .
- Rearrange and state the gradient.
- Find the equation of the line through and .
- Find the equation of the line parallel to through .
- Find the gradient of a line perpendicular to .
Answers: 1. Gradient −3, intercept 5. 2. , gradient . 3. . 4. . 5. .
More practice in our straight line graphs questions.
Frequently asked questions
What do m and c stand for in y = mx + c?
m is the gradient, the steepness of the line (how much y changes for each 1 increase in x). c is the y-intercept, the value of y where the line crosses the y-axis.
How do I find the gradient between two points?
Divide the difference in the y-coordinates by the difference in the x-coordinates, keeping the points in the same order top and bottom.
What is the gradient of a perpendicular line?
The negative reciprocal: flip the fraction and change the sign. Perpendicular to gradient 3 is −1/3, and the two gradients multiply to −1.
Sources
- GCSE mathematics: subject content and assessment objectives. Department for Education.
- Cambridge IGCSE Mathematics 0580 syllabus. Cambridge International.
Keep reading
Straight line graphs (y = mx + c) questions and answers
8 GCSE and IGCSE questions with worked answers, checked as you type.
Equation of a line calculator: y = mx + c
y = mx + c from two points, or a point and the gradient, with the working.
Gradient calculator from two points
The gradient (slope) of the line through two points, with the working shown.
Midpoint and distance formulas: coordinates, gradients and line segments
The midpoint formula, the distance formula from Pythagoras, finding a missing endpoint, and gradients.