Predator-Prey Ecosystem: A Real-Time Agent-Based Simulation

Requires a Wolfram Notebook System
Interact on desktop, mobile and cloud with the free Wolfram Player or other Wolfram Language products.
This Demonstration simulates the dynamics of predators (foxes, in orange) and prey (rabbits, in purple) in a 2D bounded square habitat. An individual of each species is simulated as a particle moving in a random walk. The initial condition is such that there are 100 particles randomly distributed in the space, 10% of which are foxes and the rest rabbits. A rabbit particle can replicate itself at a given growth rate. A fox particle has to eat (i.e., collide into) a rabbit particle in order to replicate itself, and will die if it doesn't eat any rabbit particles for a certain time period. The maximum population of each species is bounded to 500. Depending on the parameter settings, this ecosystem shows several distinct behaviors, including extinction of foxes (or both species), oscillation of populations, and spatial waves of foxes chasing clusters of rabbits. You can stop and restart the real-time simulation using the "run simulation" checkbox.
Contributed by: Hiroki Sayama (March 2011)
Open content licensed under CC BY-NC-SA
Snapshots
Details
detailSectionParagraphPermanent Citation
"Predator-Prey Ecosystem: A Real-Time Agent-Based Simulation"
http://demonstrations.wolfram.com/PredatorPreyEcosystemARealTimeAgentBasedSimulation/
Wolfram Demonstrations Project
Published: March 7 2011