Watch the agents simulate an approximation of the paths traced by slime moulds to map efficient transport networks.
This simulation models the behaviour of Physarum polycephalum a single-celled organism capable of solving complex network optimisation problems. It famously reproduced the Tokyo rail network when placed on a map with oats at major cities.
Each agent follows three simple steps every frame:
Agents are drawn to existing trails and reinforce them by depositing their own. This positive feedback loop causes sparse random paths to consolidate into dense, branching networks, the same mechanism Physarum uses to build efficient transport networks between food sources in nature.
Like boids, this simulation shows that sophisticated collective behaviour needs no central coordination. The slime mold has no brain, no map and no plan, it only utilises local rules operating on local information. Yet the outcome is a globally efficient network. Engineers now study Physarum to design better road and rail systems. It's also being studied as inspiration to build more robust, non-linear computing systems due to its ability to solve the Travelling Salesman Problem with astonishing efficiency.