Skip to main content
Codepiko
TR
All activities

To save a PDF, choose "Save as PDF" as the destination in the print window.

Graph colouring: map colouring

The big idea

On a map, two countries that share a border are never given the same colour. If we think of each country as a point (a node) and each shared border as a line (an edge), the map becomes a graph; computer science calls this graph colouring. The real question is: how few colours will do? Countries that touch only at a corner are not neighbours. Mathematicians have proved that four colours are always enough for any flat map (the four colour theorem).

Where do we meet it?

When a school plans its exam timetable, it never puts two exams taken by the same pupil on the same day: the exams are nodes and the days are colours. Radio stations and phone masts that are close together get different frequencies so they do not interfere. Class timetables and meeting times are planned the same way.

40 minutes in classFor teachers

  1. 5 minGetting attentionFour countriesDraw a country on the board with three countries around it, and make the three outer countries touch each other too. Ask the class: “Neighbours must not share a colour. How many colours do we need?” Let a few pupils try with chalk, then talk about why three colours are not enough.
  2. 12 minLessonA map on the tablePairs colour the map on the sheet. First they write colour names next to the letters in pencil and test them, then they colour. Write on the board how many colours each pair used; the pair with the fewest explains how they used countries that touch only at a corner.
  3. 15 minLessonA string graphSix pupils become the six clubs and pin the club names to their jumpers. For each line on the sheet, stretch a piece of string between two pupils: the clubs at the two ends of a string cannot meet on the same day. The class gives each pupil a day card (coloured paper); if both ends of a string have the same colour, swap a card. Then everyone solves the club task on the sheet; those who finish move on to the Map Colouring game.
  4. 8 minAssessmentHow few colours?Explain the four colour theorem: four colours are always enough for a flat map, and sometimes fewer will do. Exit card: “Five countries form a ring around one country, and each country in the ring touches the next one. How many colours are needed, and why?” (Answer: 4. A ring of five countries needs 3 colours, and the country in the middle needs a fourth.)

Codepiko · Computer science: Graph colouring: map colouring

Fewest colours

Goal: Colour the map and the club days with as few colours as you can, without any neighbours clashing.

Time: 30 min · You need: Coloured pencils (at least four colours), pencil

Name:
Class:
Date:

1. Colour the map

Colour each country. Two countries that share a border cannot have the same colour; countries that touch only at a corner can. Use as few colours as you can and write how many you used.

ABCDEFGHIJ

Number of colours you used:

2. Club days

Each school club meets one day a week. Two clubs joined by a line share a member, so they cannot meet on the same day. Write a day number in each circle. How few days are needed?

ChessRoboticsMusicArtFootballDrama

Fewest days:

3. Think

Write short answers.

Can two countries that touch only at a corner have the same colour? Why?

How are the club days like colouring a map?

codepiko.com