Study materials · photonresources.comClasses with our teachers · Photon AcademyFor IB Diploma students worldwide

Maths IA · Modelling · topic 94 of 97

Exam timetables: how few sessions are needed? · IB Maths IA idea: guide, sample graph and step-by-step plan

clash = edge, session = colour

Two subjects cannot sit in the same exam session if a single student takes both. How few sessions can a whole school get away with? You're going to find a lower bound, an upper bound, and close the gap.

Difficulty●●● Stretch
KitAnonymised or simulated subject choices, a spreadsheet or Python, your GDC
TimeAbout 15 hours
FitsAA SL0 of 3AA HL1 of 3AI SL1 of 3AI HL2 of 3
  • ✓ you like scheduling puzzles with a hidden structure
  • ✓ you are happy learning a new idea and explaining it fully
  • ✓ you can get anonymised or simulated subject-choice data

The big idea

Make each subject a vertex and join two subjects whenever some student takes both. A timetable is then a colouring: give each vertex a colour (a session) so joined vertices differ. The fewest colours is the chromatic number. Graph colouring is not in either course, so you must explain it from scratch, building on the graph vocabulary of AI HL. A group of subjects that all clash with each other forces that many sessions, which gives a lower bound; a greedy method gives an upper bound. The method is routine. The marks come from closing the gap: when does greedy fail, how does the order of subjects matter, and how close do the bounds get on real or simulated data?

Make it yours: pick one twist

Copying a classic won't show your choices. Pick one of these (or invent your own) and your IA becomes yours.

Swipe for more twists →

Build the conflict graph

Turn a table of students and their subjects into an adjacency matrix, and check it against the table for a few students.

→ A matrix built from data. Explain what a high-degree vertex means for the timetable.
Find a lower bound

Find the largest group of subjects that all clash with each other (a clique) and explain why that many sessions are needed.

→ A proof by counting. Check whether the lower bound is also enough, and what it means if it is not.
Compare greedy and Welsh-Powell

Colour with the greedy method in different orders, then in order of decreasing degree (Welsh-Powell), and compare the number of sessions.

→ An algorithm whose answer depends on the order. Count how many orders give the best colouring.
Prove an upper bound

Show that greedy never needs more than one more colour than the largest degree, and that Welsh-Powell gives a sharper bound.

→ A proof that uses the greedy method's rule. Compare each bound with the colouring you actually found.
Add constraints

Limit how many papers fit in a session, or add a room-capacity rule, and see how the answer changes.

→ A harder problem than colouring alone. Say why the earlier bounds no longer apply.
Use real or realistic choices

Use anonymised subject choices from a school, or simulate a cohort with realistic subject popularity.

→ Real data is denser than a textbook example. Check how the number of sessions grows with cohort size.

Your Maths IA research question: run the check

real, anonymised or simulated?

Write your own question first. Then make sure it ticks every box:

  • Names the cohort, the number of subjects and students, and where the choices come from (real, anonymised or simulated).
  • Says what a session is, and what counts as a clash.
  • Names the quantity found: the fewest sessions, or the gap between a bound and an algorithm.
  • Says how you will know the answer is the fewest: a matching lower bound or an exhaustive check.
  • States what is left out: room sizes, exam lengths and special arrangements.
Stuck on your question?Get an RQ Check: each question is scored on 5 points, with what to fix. Your first one is free.
Get an RQ Check

The model

Subject choices become clashes, and clashes become a graph to colour. Draw the conflict graph of your own cohort and colour it.

Who takes whatStudent 1: Maths, PhysicsStudent 2: Physics, ArtStudent 3: Maths, EconomicsMaPhArEcConflict graphtwo subjects share a student: an edgeclash = edgeColour = exam session, and joined subjects need different coloursSession 1: Maths, ArtSession 2: Physics, Economicsfewest colours = fewest sessionsa clique sets the minimum

How your Maths IA could be laid out

The usual order for a topic like this, what each part needs to show, and roughly how much of your 12 to 20 pages it takes. The words are all yours.

Aim and context~1 page
The timetabling problem, why fewer sessions matter and a prediction before any method.
From choices to a graph~2 pages
Vertices, edges and the adjacency matrix, with your data summarised and its source explained.
Colourings and bounds~2 pages
Chromatic number, cliques and the lower bound, each explained from first principles.
Greedy and Welsh-Powell~2.5 pages
Both methods run on a small case and on your data, with the number of sessions for each.
Closing the gap~2.5 pages
A proof that the bounds hold and an exhaustive check on a small graph.
Larger cohorts~1.5 pages
How the number of sessions grows as you add students or subjects.
Conclusion~1 page
Back to your aim: the fewest sessions found, and how sure you are it is the fewest.
Evaluation~2 pages, the biggest part!
Real exam rules, room sizes and fairness to students. Say which constraint would change the answer most.
Bibliographynot counted
Where the algorithms, bounds and data came from.

What your Maths IA graph could look like

plot the lower bound too

Made-up values to show the form of a strong graph: the number of sessions needed as the cohort grows. Yours will look different. example only

04080120160200024681012Students in the cohort (count)Exam sessions needed (count)trendyour cohorts (made-up)growth slows: why?more students, same subjectsILLUSTRATIVE · MADE-UP DATA
  • Sessions needed is a count, so the points should sit at whole numbers, joined or fitted only if you can justify it.
  • A curve is a claim: say what model it comes from and where it should stop.
  • Plot the lower bound from a clique as well, so the gap is visible.
  • Say how many cohorts you simulated for each point.

The maths in action

worked through, not sketched!

The graph above was a sketch with made-up numbers. This figure works the idea through from the model itself, so you can see what a finished figure looks like. The source line under it says where every number comes from.

Left: a graph of 12 subjects coloured with four colours, with a clique of four vertices drawn in red. Right: a timetable of four sessions listing which subjects are in each.
(a) A simulated cohort of 22 students taking 2 optional subjects each gives a conflict graph with 18 edges; the red clique of 4 subjects forces at least 4 sessions. (b) Welsh-Powell finds a timetable of 4 sessions; greedy in list order needs 5.Source: Computed from a simulated cohort of 22 students (made-up choices); no real student data.

Your game plan

Tick steps off as you go. We'll remember on this device.

0 of 10 done

  1. Read and predictFind out what graph colouring is. Before any method, guess how many sessions a small cohort needs.
  2. Get the dataUse anonymised subject choices from a school, or simulate a cohort with realistic popularities and say how you chose them.
  3. Draw the conflict graphMake a vertex per subject and an edge for every clash. Write the adjacency matrix and check it against three students.
  4. Trial run (1 lesson)Colour a graph of 6 vertices by hand, find the fewest colours, and explain how you know it is the fewest.
  5. Find a lower boundFind the largest clique in your graph and explain why that many sessions are needed.
  6. Colour greedilyRun the greedy method in two or three orders, then Welsh-Powell. Compare sessions and show every step.
  7. Go further, with a reasonProve an upper bound, test random cohorts of different sizes, or add a session-size limit. HL: this is where the rigour for criterion E comes from.
  8. Close the gapWhere your bounds differ, check all colourings of a small case or argue that no better colouring exists.
  9. Reflect as you goAfter every result write one line on what it means for a real timetable and what it ignores. These lines become your evaluation.
  10. Cut, check, then sendCheck every graph is labelled, every symbol is defined once and the conclusion answers your aim. Then send your teacher one draft.

The maths you'll use

  • Conflict graph and adjacency matrix – Build if some student takes both subject and subject , and read degrees from the row sums.
  • Lower bound by clique – Find the largest clique and show every colouring needs at least colours.
  • Greedy colouring – Colour vertices in a given order using the smallest colour not used by a neighbour, and count the colours used.
  • Welsh-Powell bound – Order vertices by degree and show that .
  • Simulation – Generate random cohorts with realistic popularities and estimate the mean number of sessions with a confidence interval.

Key equations

Syllabus links

  • 1.15Proof by induction, contradiction and counterexampleHL

Read up first

Data and sources to start from

Use anonymised subject choices from a school (with permission), or simulate students choosing subjects with realistic popularities.

References to cite

  1. Welsh, D. J. A., & Powell, M. B. (1967). An upper bound for the chromatic number of a graph and its application to timetabling problems. The Computer Journal, 10(1), 85-86.
  2. Appel, K., & Haken, W. (1977). Every planar map is four colorable. Part I: Discharging. Illinois Journal of Mathematics, 21(3), 429-490.
  3. Wilson, R. J. (2010). Introduction to graph theory (5th ed.). Pearson.

Cite what you actually use, in your own format, and say where each number came from.

Traps to avoid in this Maths IA

greedy is only an upper bound
  • Calling the greedy answer the chromatic number. It is only an upper bound unless it meets a lower bound.
  • Using real students' names or identifiable subject combinations. Anonymise the data and say how.
  • Joining two subjects when no student takes both. A clash needs at least one shared student.
  • Forgetting that the order of subjects changes the greedy result.
  • Assuming the four colour theorem applies. A conflict graph is usually not planar.
  • Giving a lower bound with no proof that the clique you found is the largest one.

More Maths IA ideas like this

Make sure it's yours

This guide shows how a topic like this is usually approached. It is not an IA. Your question, choices, data, analysis and words must be your own: change something, tell your teacher where the idea came from, and follow your school's rules on outside help.

Get your RQ checked · first one free