Infection

Some notes

This is just a simulation, a quick model, not reality. Just balls, not people. This simularion can give different results with different screen sizes as well as the randomness of infections, movements, and so.

Balls can get infected by a custom virus. These balls has several states:

The virus can infect other balls with certain probability, if some ill balls hit each other the viral load increases, increasing probabilites of fatal ending.

We can mitigate the effects stopping balls population, as you may imagine stopping all balls would be the better case. Infected balls can't touch any other ball so ill balls can heal or die without contagion. But we can choose 90% of stopped balls to see some results.

There are many things this thing doesn't do:

Inspiration

This is just a fast and tiny project inspired by: Washington Post's Corona Simulator. Using some hysics notes when I came across BallsBallsBalls to mitigate the overlapping problem, could not fix it but found some things to improve movement and collisions. Also started using some code from Bouncing balls from MDN.

Find me

You can visit my blog Poesia Binaria in Spanish, about programming, security and system administration. I also have a little website with some projects. You can also find me on: Fork me on GitHub