Discrete Event Simulation Competition - 1st place

The Competition

The competition objective was to write an interesting Discrete Event Simulation application and was open to all Department of Computing First year students in Spring 2004. The submitted programs were judged by Tony Field.

My winning entry models arbitrary population of predator and prey based within a 'lake'. My Model uses particles to model individuals, and you can see that primitive instinct such as that for food and procreation recreates an emergent behaviour on a parallel with real animals, such as that of fish shoals, and prey dispersion.


The Verdict

Senior Lecturer Tony Field (who judged the competition), described the simulation;

"Steven Lovegrove: Steven set up a variation of the classical predator/prey problem. The archetypal model is a mathematical model where the predator and prey populations are expressed in the form of coupled differential equations (the Lotka-Volterra equations - see for example http://www.ento.vt.edu/~sharov/PopEcol/lec10/lotka.html). Steven built a more elaborate model using explicit particles to model individual members of an arbitrary (i.e. specifiable) number of predator species. The BIG problem with the Lotka Volterra model is that it is only stable for very specific parameterisations - if you change the parameters slightly one species dies out, for example. Particle-based models can be much more stable, although this is not proven for Steven's model (a lot to ask!) - we know that it is very hard indeed to achieve stable ecosystem models with more than two levels in the food chain."

Running the FISH simulation

The Java program has been placed into a simple JAR file, so your Operating system may know how to execute it automatically. If this fails, open a command line window (or shell) in the same directory, and type "java FishSim".


See the usage for command line parameters by adding the switch 'help'. Enter no parameters to see a simulation with a default parameter list of 3 groups of fish. The program is entirely non-deterministic, so a species that entirely dies out in one trial may thrive in the next.

Simulation Description

This simulation is designed to show the interaction between predator and prey. Using the command line switches, any number of levels of predator can be created, and displayed in a window by colour. The first fish specified is prey ONLY, and does not require food. It simply breeds, and tries to keep out of trouble. Predator are able to eat other fish that are significantly smaller in weight (and that it can catch up with ).

A group of fish are distinguished by colour, and they themselves distinguish each other by weight, and will try to breed with similar size fish, and eat those that are smaller. All fish will eventually expire! Predator are designed to be smarter, analysing whether they should focus on breading or hunting based on hunger. As time progresses, a predator will decrease in weight, and must eat to re-establish itself to a healthy level. Fish cannot breed until they are sexually active. They have an offspring bearing time, and fertility.

This simulation helps to demonstrate the ratios that build up between predator and prey, and the cyclic nature in which they effect each other! The 'lake' display is showing the current state of the simulation, and is not designed to be real time. The simulation is running on discrete events and how quickly it progresses depends on the computation required.

Description of symbols

Dot male
Plus female
Ring pregnant


by Steven Lovegrove Jump to top