The Gradient of a Line

25 min
0/4 practice checks

The gradient of a straight line measures its steepness — how much it rises for each step across. Between two points (x1,y1)(x_1, y_1) and (x2,y2)(x_2, y_2):

m=riserun=y2y1x2x1m = \frac{\text{rise}}{\text{run}} = \frac{y_2 - y_1}{x_2 - x_1}

The sign tells the direction:

  • Positive gradient — the line goes up from left to right (uphill).
  • Negative gradient — the line goes down from left to right (downhill).
  • Zero gradient — a flat, horizontal line.
  • Undefined gradient — a vertical line (the run is 0, and we cannot divide by 0).

Worked example. The gradient through (1,2)(1, 2) and (3,8)(3, 8) is m=8231=62=3m = \dfrac{8 - 2}{3 - 1} = \dfrac{6}{2} = 3: the line rises 3 units for every 1 across.

Find the gradient of the line through (0,0)(0, 0) and (2,6)(2, 6).

What is the gradient of a horizontal line?

Find the gradient of the line through (0,5)(0, 5) and (2,1)(2, 1).

A wheelchair ramp rises 2 m over a horizontal run of 8 m. What is its gradient, as a decimal?