A computer model for the flocking behaviour of birds, basically. It was developed by Craig Reynolds in 1986.
This particular implementation uses P5, an accessible JavaScript computer graphics library. The P5 website also contains a slightly different implementation of the same flocking model.
Download the minified p5 source from http://p5js.org/download/ and place it in the same folder with the rest of the code.
Open the file index.html
in your favourite browser, (enable JavaScript if not
already enabled), and admire the birds until you first start feeling drowsy and finally fall asleep on your keyboard. 😴