IB Maths AI HL Geometry Toolkit Paper 1 & 2 Midpoint, distance, gradient ~8 min read

Coordinate Geometry

Three formulas do almost all the work in 2D coordinate problems: midpoint (average the coordinates), distance (Pythagoras on the gaps), gradient (rise over run). All three are in the formula booklet, so memorising them isn’t the issue — choosing the right one and applying it carefully is.

📘 What you need to know

The three formulas in one picture

Picture two points A and B on a coordinate grid. Draw the line segment between them, and complete a right-angled triangle by going horizontally then vertically. The horizontal side has length |x2x1| (the “run”), the vertical side |y2y1| (the “rise”), and the hypotenuse is the distance AB. Pythagoras turns the two side lengths into the distance formula. The gradient is just rise ÷ run with signs preserved. The midpoint sits exactly halfway along the hypotenuse, with coordinates that are the averages of the endpoints’.

Three formulas in one diagram: midpoint, distance, gradient x y 1 3 5 7 9 1 5 9 run = x₂ − x₁ = 6 rise = y₂ − y₁ = 8 d = √(6² + 8²) = 10 A(1, 1) B(7, 9) C(7, 1) M(4, 5) midpoint gradient m = rise/run = 8/6 = 4/3
A right-angled triangle with run 6 and rise 8 gives hypotenuse 10 by Pythagoras — the (6, 8, 10) Pythagorean triple. The midpoint sits halfway along the hypotenuse.
The three formulas midpoint: ((x1+x2)/2, (y1+y2)/2)  ·  distance: √((x1x2)2+(y1y2)2) gradient: (y2y1)/(x2x1) — rise over run

Reverse problems and collinearity

Many problems flip a formula. Given the midpoint and one endpoint, find the other: set up the midpoint equation in each coordinate and solve. Given the distance and one endpoint plus a constraint (like “on the x-axis”), find the unknown coordinates: square the distance formula to remove the root, then solve. To prove three points are collinear (on a single straight line), compute pairs of gradients and check they’re equal: if the gradients from one point to each of the others match, the points lie on the same line.

Squaring trick for distance: equations involving d are often easier after squaring both sides, since d2 is a polynomial expression with no surds. Just remember d itself is the non-negative root at the end.

🧭 Recipe — coordinate geometry

  1. Identify the formula from the question: midpoint (average), distance (Pythagoras), gradient (rise/run).
  2. Label coordinates: write (x1, y1) and (x2, y2) above the points to avoid sign errors.
  3. Substitute carefully, paying attention to negatives.
  4. Simplify: factor or recognise a Pythagorean triple for a clean answer.
  5. For reverse problems, set up an equation in the unknown and solve.

Worked examples

WE 1

All three formulas on one pair of points

Points C(2, 5) and D(8, −3). Find: (a) the midpoint of [CD]; (b) the distance CD; (c) the gradient of the line through C and D.

(a) average each coordinate M = ((2+8)/2, (5+(−3))/2) M = (5, 1) (b) distance via Pythagoras d = √((2−8)² + (5−(−3))²) = √(36 + 64) = √100 d = 10 units (c) gradient = (y₂ − y₁)/(x₂ − x₁) m = (−3 − 5)/(8 − 2) = −8/6 m = −4/3 (6, 8, 10) Pythagorean triple — clean distance ✓
WE 2

Exact-form distance

Points P(−1, 3) and Q(4, 7). Find: (a) the distance PQ in exact form; (b) the gradient of PQ.

(a) compute the gaps Δx = 4 − (−1) = 5; Δy = 7 − 3 = 4 d = √(5² + 4²) = √(25 + 16) = √41 d = √41 units (b) gradient m = 4/5 m = 4/5 no Pythagorean triple here — leave as √41.
WE 3

Reverse: find an endpoint from the midpoint

The midpoint of [AB] is M(3, −2). Point A has coordinates (−1, 5). Find the coordinates of B.

midpoint equations (−1 + Bx)/2 = 3 ⇒ Bx = 7 (5 + By)/2 = −2 ⇒ By = −9 B = (7, −9) general rule: B = 2M − A coordinate-wise.
WE 4

Reverse: find a point with given distance

Point R lies on the x-axis. The distance from R to S(2, 3) is 5. Find the possible coordinates of R.

let R = (x, 0); distance equation √((x − 2)² + (0 − 3)²) = 5 square both sides (x − 2)² + 9 = 25 (x − 2)² = 16 x − 2 = ±4 ⇒ x = 6 or x = −2 R = (6, 0) or R = (−2, 0) two solutions — both equidistant from S.
WE 5

Collinearity via gradients

Show that the points A(1, 2), B(4, 8), and C(−2, −4) are collinear.

compute each pairwise gradient m(AB) = (8 − 2)/(4 − 1) = 6/3 = 2 m(BC) = (−4 − 8)/(−2 − 4) = −12/−6 = 2 m(AC) = (−4 − 2)/(−2 − 1) = −6/−3 = 2 all gradients equal A, B, C are collinear (common gradient 2) two equal gradients sharing a point is enough — three confirms it.
WE 6

Applied: surveying a field

A surveyor maps a tree T at coordinates (4, 7) and a well W at (16, 2), measured in metres from a corner of the field. Find: (a) the location for a marker post at the midpoint of [TW]; (b) the distance TW; (c) the gradient of the line TW.

(a) midpoint M = ((4 + 16)/2, (7 + 2)/2) M = (10, 4.5) (b) distance d = √((4 − 16)² + (7 − 2)²) = √(144 + 25) = √169 d = 13 m (c) gradient m = (2 − 7)/(16 − 4) = −5/12 m = −5/12 (5, 12, 13) Pythagorean triple — recognising it gives the clean answer instantly.

💡 Top tips

⚠ Common mistakes

Next up: Perpendicular Bisectors — combining all three formulas into one classic problem: the line that cuts a segment in half at a right angle.

Need help with Coordinate Geometry?

Get 1-on-1 help from an IB examiner who knows exactly what Paper 1 & 2 are looking for.

Book Free Session →