James Ashton MathsFREE MATHEMATICS. OPEN TO EVERYONE.
HomeIB DiplomaA levelAbout
IB Diploma › Maths AI SL › Geometry & trigonometry › Voronoi diagrams

Perpendicular bisectors & Voronoi diagrams

A Voronoi diagram splits a map into regions, each containing the points nearest to one site: the nearest hospital, phone mast or weather station. The boundaries are perpendicular bisectors, so this page starts with those, then covers cells, adding a site, nearest-neighbour interpolation and the "toxic waste dump" problem.

SL 3.5SL 3.6Paper 1Paper 2GDC allowed≈ 50 min to work through
Before you start: midpoints, gradients and perpendicular lines (Straight lines).

1What you need to know

Tick these off as you go. By the end of the page you should be able to do all of them without notes.

  • Find the equation of the perpendicular bisector of two pointsSL 3.5
  • Use the words site, cell, edge and vertexSL 3.6
  • Identify the site closest to a point, and estimate a value by nearest-neighbour interpolationSL 3.6
  • Describe how a Voronoi diagram changes when a site is addedSL 3.6
  • Solve the toxic waste dump problem: the point furthest from all sites, at a vertexSL 3.6
  • Find the area of a cell by splitting it into simple shapesSL 3.6

2Notes & worked examples

Each idea is followed by a worked example. Try the question yourself first, then reveal the solution one step at a time.

The big idea

Every point on the perpendicular bisector of A and B is the same distance from A as from B. So the perpendicular bisector is the border between "closer to A" and "closer to B". A Voronoi diagram is just these borders for many points at once: each region (cell) holds every point that is closer to its own site than to any other.

2.1 The perpendicular bisector

To find the perpendicular bisector of A and B: find the midpoint of AB, find the gradient of AB and take the perpendicular gradient −1m, then write the line through the midpoint.

Worked example 1Paper 1
Find the equation of the perpendicular bisector of A(2,1) and B(6,9).
Midpoint: (4,5)
Gradient of AB: 9−16−2=2, so the perpendicular gradient is −12
y−5=−12(x−4)⇒y=−0.5x+7

2.2 The language of Voronoi diagrams

WordMeaning
Siteone of the given points (a town, a school, a weather station)
Cellthe region of points closer to that site than to any other
Edgea boundary between two cells: part of the perpendicular bisector of their sites
Vertexa point where three (or more) edges meet: it is the same distance from three sites

Nearest-neighbour interpolation: to estimate a value (rainfall, temperature) at a point with no measurement, find the cell the point lies in and use the value at that cell’s site.

Worked example 2Paper 1
Weather stations P, Q and R recorded 12 mm, 18 mm and 9 mm of rain. The town T lies inside the cell of Q. Estimate the rainfall at T.
18 mm
Every point in a cell is given the value of its site.

2.3 Adding a site

To add a new site to a diagram: (1) find the cell the new site lies in; draw the perpendicular bisector between the new site and that cell’s site, as far as the edges of the cell. (2) Where it meets an edge, move into the neighbouring cell and draw the bisector between the new site and that cell’s site. (3) Continue until you return to the start (or reach the edge of the diagram). (4) Remove the parts of the old edges that are now inside the new cell. In exams, the coordinates for any bisector equations are always given.

2.4 The toxic waste dump problem

Where should something unwanted (a waste dump, a noisy factory) go so that it is as far as possible from the nearest site? Within the region, the best point is at a vertex of the Voronoi diagram, because a vertex is equally far from three sites. Find the vertices, work out the distance from each to its sites, and choose the largest.

Worked example 3Paper 2
Three towns are at A(0,0), B(8,0) and C(2,6), in km. Find the point equidistant from all three towns, and its distance from them.
Perpendicular bisector of AB: x=4
AB is horizontal, so its perpendicular bisector is vertical, through the midpoint (4, 0).
Perpendicular bisector of AC: midpoint (1,3), gradient of AC=3, so y−3=−13(x−1)
At x=4: y=3−1=2. The vertex is (4,2).
Or graph the two lines on the GDC and use Intersection.
Distance: 42+22=4.47 km. (Check: from B, 42+22; from C, 22+42.)

2.5 Areas of cells

Worked example 4Paper 1
A square park has corners (0,0), (10,0), (10,10) and (0,10). The edge between the two cells is y=−0.5x+7. Find the area of the cell below this edge.
The edge meets x=0 at y=7 and x=10 at y=2.
The cell is a trapezium with parallel sides 7 and 2 and width 10.
Split cells into rectangles, triangles and trapezia.
Area =12(7+2)(10)=45 km2
Worked example 5 (faded)Paper 1
Find the perpendicular bisector of P(1,2) and Q(5,4).
Midpoint = (3, 3)  ← you work this out
Perpendicular gradient = −2  ← you work this out
y= −2x + 9  ← you work this out
On your TI-Nspire Calculator tricks →

To find a vertex, graph two perpendicular bisectors on a Graphs page and use menu → Analyze Graph → Intersection. A vertical bisector such as x=4 cannot be typed as f(x): substitute x=4 into the other line instead. Distances: type (x1−x2)2+(y1−y2)2 in one line.

3Build a Voronoi diagram

Tap or click inside the box to add a site; each colour is one cell. Turn on "largest empty circle" to see the best place for a toxic waste dump: the vertex furthest from its nearest sites.

Tap or click to add a site (up to 10).

4Common mistakes & exam tips

Common mistakes

  • Using the gradient of AB instead of the perpendicular gradient.
  • Drawing the bisector through one of the sites instead of through the midpoint.
  • Placing the toxic waste dump at the centre of the map instead of at a vertex.
  • In interpolation, using the value of the nearest edge or vertex rather than the cell’s site.
  • Forgetting to remove old edges inside a new cell when adding a site.

Exam tips

  • Exam questions give you the coordinates; you will not have to draw bisectors with compasses.
  • A vertex is equidistant from three sites: check your answer by finding all three distances.
  • For the area of a cell, split it into shapes whose areas you know, and show each one.
  • Words matter: "site", "cell", "edge" and "vertex" each have one meaning here.

5Practice

Fluency questions build the basics. Problem-solving questions make you think about which method to use.

FluencyP1
Find the perpendicular bisector of (0,0) and (6,0).
x=3
FluencyP2
Find the perpendicular bisector of (1,1) and (5,3).
Midpoint (3,2); gradient −2: y=−2x+8
FluencyP3
Which of A(0,0) and B(6,4) is closer to (4,1)?
A: 17; B: 13. B is closer.
FluencyP4
In a Voronoi diagram, what is true of every point on the edge between the cells of P and Q?
It is the same distance from P and from Q.
Problem solvingP5
Sites A(0,0), B(10,0) and C(4,8). Find the vertex equidistant from all three and its distance from them.
(5,2.5); 31.25=5.59
Problem solvingP6
A new site is added inside the cell of site P. Describe the first step in updating the diagram.
Draw the perpendicular bisector of the new site and P, within the cell of P.

6Exam-style questions

Original questions in the style of the IB Maths AI SL exam, with full markschemes. Your GDC is allowed throughout: use it, but write down what you entered and what it gave you. Give yourself about 1 minute per mark.

Question 1Paper 1[6 marks]

Two schools are at P(2,8) and Q(10,4). Children attend the school nearest to their home.

  • (a)Find the midpoint of PQ.[1]
  • (b)Find the gradient of the perpendicular bisector of PQ.[2]
  • (c)Find the equation of the perpendicular bisector.[1]
  • (d)A child lives at (5,3). Determine which school the child attends.[2]
(a)
(6,6)A1
(b)
gradient of PQ=−0.5(A1)
2A1
(c)
y=2x−6A1
(d)
distances 34=5.83 and 26=5.10, or (5,3) is on Q’s side of the line(M1)
school QA1
Question 2Paper 2[7 marks]

Three villages are at A(0,0), B(10,0) and C(4,8), in km. A recycling plant is to be built as far as possible from the nearest village, at the vertex of the Voronoi diagram of the three villages.

  • (a)Write down the equation of the perpendicular bisector of AB.[1]
  • (b)Find the equation of the perpendicular bisector of AC.[3]
  • (c)Find the coordinates of the vertex.[1]
  • (d)Find the distance from the plant to each village.[2]
(a)
x=5A1
(b)
midpoint (2,4)(A1)
perpendicular gradient −0.5(A1)
y=−0.5x+5A1
(c)
(5, 2.5)A1
(d)
52+2.52(M1)
5.59 kmA1
Question 3Paper 1[5 marks]

A square nature reserve has corners (0,0), (10,0), (10,10) and (0,10), in km. Two ranger stations are at P(3,2) and Q(7,8). The edge of their Voronoi cells is y=−23x+253.

  • (a)Find where the edge meets x=0 and x=10.[2]
  • (b)Find the area of the cell containing P.[2]
  • (c)Rainfall of 21 mm is measured at P and 34 mm at Q. Estimate the rainfall at (2,6).[1]
(a)
(0,253)A1
(10,53)A1
(b)
12(253+53)(10)(M1)
50 km2A1
(c)
at x=2 the edge is at y=7>6, so (2,6) is in P’s cell: 21 mmA1

7Check yourself

Six quick questions, marked instantly. Aim for 6/6 before moving on. Fractions like 3/2 are accepted.

8Past-paper practice

Once you're scoring well above, try these real IB Maths AI SL questions. Your school or teacher will have the papers.

PaperQuestionFocusDifficulty
May 2025 · TZ2 · Paper 1Q7Six-site diagram: an edge equation, a vertex and its distance★★★
May 2025 · TZ1 · Paper 2Q5Fire stations: edge equation, nearest station, equidistant point, cell area★★★
May 2024 · TZ1 · Paper 1Q6Three points: bisector equation, the vertex, edges of the diagram★★☆
May 2023 · TZ2 · Paper 1Q7Four cafés: perpendicular bisector, complete the diagram★★☆
Spotted a mistake on this page?Tell me and I'll fix it. The button opens an email with this page already named, or write to jamesashtonmaths@gmail.com.
Report a mistake