Computer Science Virus Propagation Validated

Virus Propagation

Visualize how epidemics spread through populations

Susceptible 0
Exposed 0
Infected 0
Recovered 0
Dead 0
Preset

SIR Epidemiological Model

The SIR model divides a population into three compartments to simulate disease dynamics.

States:

  • Susceptible (S): Healthy individuals who can be infected
  • Infected (I): Contagious individuals spreading the disease
  • Recovered (R): Immune individuals (or deceased)

Parameters:

  • Infection Rate: Probability of transmission on contact
  • Recovery Time: Duration before an infected person recovers
  • Mortality Rate: Chance of death instead of recovery
  • Vaccination: Percentage of population initially immune

Interventions:

  • Social Distancing: Reduces agent movement speed
  • Vaccination: Creates initial immunity in the population

Basic Reproduction Number (R0): The average number of secondary infections from one case. When R0 > 1, the epidemic spreads; when R0 < 1, it dies out.

S E I R D
© 2013 - 2026 Cylian 🤖 Claude
About

Generation Prompt

Page: Virus Propagation - Epidemic Simulation
Slogan: "Visualize how epidemics spread through populations"

Structure:
- Widget before:title -> h1 + p.slogan centered
- Main -> Canvas in .card.full.ratio-16-9 (HD via devicePixelRatio)
- Widget after:algorithm -> SIR model explanation
- Widget modal:claude -> Documentation

Agent States:
- Healthy/Susceptible: Green circles, can be infected
- Infected: Red circles, spread disease on contact
- Recovered: Blue circles, immune to reinfection
- Dead: Gray circles, stationary

Simulation Parameters:
- Population size: Number of agents (50-500)
- Infection radius: Distance for transmission
- Infection rate: Probability per contact (0-100%)
- Recovery time: Frames until recovery (100-500)
- Mortality rate: Chance of death (0-50%)

Controls:
- Start/Pause: Toggle simulation
- Reset: Restart with new population
- Vaccination slider: Initial immune percentage
- Social distancing toggle: Reduce movement speed

Visualization:
- Main canvas: Agent-based 2D simulation
- Chart area: Real-time SIR curves (S=green, I=red, R=blue)

Physics:
- Agents move with random velocity
- Bounce off boundaries
- Collision detection for infection spread