Teaching objectives
What do a rumour, a virus, and a wildfire have in common? How can we model their behaviour? We'll see that graphs and cellular automata create plausible mathematical models for studying and predicting the behaviour of spreading phenomena. And we'll end by making strategic decisions to save a village from fire!
What you'll learn
Students model real-world phenomena — epidemics, wildfires, rumours — using graphs, grids, and simulation, building intuition for why small changes in connectivity and density can have enormous consequences.
- Students predict before simulating and compare their intuition with the results: first with exponential growth (3 × 2¹⁰), then with graphs where nodes are repeated.
- They explore Erdős-Rényi networks and discover that the starting node matters: beginning at a hub sends contagion soaring compared to starting at an isolated node.
- They compare three topologies (ring, random, scale-free) and learn that the structure of the network determines the speed of spreading.
- They practise the hub vaccination strategy: with just 7 vaccines, who should be immunised to stop the epidemic?
- They discover percolation on square, hexagonal, and triangular grids: there is a critical density threshold (≈ 0.59 on a square grid) below which the fire stops spreading across the grid.
- They investigate the effect of wind on grid propagation, and in the final room manage a budget of 400 coins to place firebreaks, firefighters, and helicopters before the fire reaches the village.
Key mathematical ideas
- Unconstrained spreading follows exponential growth, though the graph structure matters.
- A contact network is a graph: people = nodes, contacts = edges; the graph's structure governs the speed of contagion.
- Hubs (high-degree nodes) act as amplifiers; vaccinating them first is far more effective than random vaccination.
- Percolation studies the connectivity of a random system; there is a critical threshold p_c (which varies by geometry: ≈ 0.59 for square, ≈ 0.70 for hexagonal, = 0.50 for triangular) where global connectivity appears or disappears abruptly.
- The number of neighbours of each cell determines the threshold: more neighbours → lower threshold → fire spreads with fewer trees.
Room-by-room contents
Room 1 · The secret that leaks out
Animated introductory room presenting the core idea of the lab: some things spread (a rumour, a song, a virus, a fire) and sometimes they stay in one corner, sometimes they take over everything.
Student tasks
- Read the introduction and click the button to start the adventure.
Room 2 · Predict the size
Pure exponential growth scenario: 3 people know a secret and each tells 2 new people every day for 10 days. The student predicts how many people will know at the end (answer: 3 × 2¹⁰ = 3 072) before finding out why that model is too optimistic.
Student tasks
- Choose the numerical range that estimates how many people know after 10 days.
- Reflect on whether the assumption that "no one is told twice" is realistic.
Room 3 · Your first graph
Random 30-node graph (Erdős-Rényi) with one initially infected node (yellow halo). A slider controls the contagion probability p at each step, and the student observes how the resulting epidemic varies.
Student tasks
- Move the probability slider p and run several simulations.
- Identify the range of p in which the contagion spreads to almost all nodes.
Room 4 · Does the first node matter?
The same Erdős-Rényi graph, but now the contagion can start from the "popular" node (many connections), the "intermediate" one, or the "loner". The student first predicts which starting node spreads the contagion furthest, then verifies experimentally.
Student tasks
- Predict which starting node spreads the most.
- Run the three experiments and compare the results with the prediction.
Room 5 · Three different worlds
Three panels show three different network topologies (regular, random, and small-world). Before simulating, the student assigns labels based on which network they think will spread fastest, then the simulations reveal the answer.
Student tasks
- Assign a predictive label (fastest / medium / slowest) to each panel.
- Run the simulations and verify the prediction.
Room 6 · The vaccine trick
The student is given 7 vaccines and must decide which 7 nodes of the graph to immunise before a random epidemic strikes. The room introduces the strategy of vaccinating hubs (highly connected nodes) versus random selection.
Student tasks
- Click the 7 nodes to immunise.
- Launch the epidemic and evaluate whether the contagion spiralled out of control or was contained.
Room 7 · The magic jump
A square grid representing a random forest: green = tree, grey = gap. The student reduces tree density and looks for the threshold below which fire stops crossing from one side to the other (percolation, p_c ≈ 0.59).
Student tasks
- Try several tree densities.
- Find the percentage below which fire can no longer cross the forest.
Room 8 · The number 59
Automatic sweep of densities with many simulations per value: a curve of crossing probability versus density is plotted. The sharp transition around 59 % (p_c ≈ 0.59) becomes visible in the graph.
Student tasks
- Launch the sweep and observe the resulting curve.
- Read from the graph the density value at which the transition occurs.
Room 9 · Hexagonal cells
The forest switches from a square grid to a hexagonal mesh (each cell has 6 neighbours). The student searches for the percolation threshold again and checks whether it differs from the square grid.
Student tasks
- Explore different densities on the hexagonal mesh.
- Estimate the new percolation threshold and compare it with the previous 59 %.
Room 10 · Triangular cells
Now the grid is triangular: each cell shares a side with only 3 neighbours. With fewer connections, the percolation threshold rises. The student predicts the direction of change and verifies it experimentally.
Student tasks
- Predict whether the threshold will rise, fall, or stay the same compared to the hexagonal mesh.
- Find the threshold on the triangular grid and compare with the prediction.
Room 11 · The wind takes charge
Back to the square grid, but now the wind blows: two sliders control tree density and wind speed. A graph records each experiment. The student looks for the wind speed above which fire becomes catastrophic.
Student tasks
- Move the density and wind-speed sliders.
- Start a fire at the centre and observe the spread pattern.
- Identify the wind-speed threshold that makes the fire catastrophic.
Room 12 · Save the village
Real-time strategy game: a fire starts in the north-west and the wind blows towards the village. With 400 coins and 30 turns, the student must place firebreaks, firefighters, a helicopter, or (as a last resort) artificial rain so that no house burns.
Student tasks
- Distribute the budget among the four available tools.
- Simulate the fire and adjust the strategy until the whole village is protected.
Rooms to project
The most striking ones to show and discuss in class.