Mar 2021 · Year 1 Computing coursework, Imperial

🦠 Disease transmission in a fixed domain

A COVID-inspired MATLAB simulation: 100 people wander around a 1000 × 1000 domain, one of them starts out sick, and a live dashboard tracks the outbreak over 10 days.

10 simulated days in 24 seconds. Green: healthy · Orange: infected, no symptoms yet · Red: sick · Blue: recovered

How it works

Every individual gets a random start position, direction and speed, and bounces off the walls of the domain. The simulation steps forward 10 seconds at a time, checks who came close to whom, and updates everyone's health status.

The dashboard redraws every 10 simulated minutes: a map of where everyone is, a bar chart of the current counts, and a history plot of the whole outbreak.

Screenshots

Code on GitHub ↗