Biologists often use computer models to simulate behaviour of animals. Computer models are specific descriptions of behaviour that can be implemented in a computer program. The programs can be run to test assumptions against real data and used to generate new hypotheses that can be tested experimentally.
In Individual-Based Models, many individual animals are simulated separately. Our model will simulate (let's say) Zebras grazing.
The zebra's (rectangular) range will be divided into a grid of small habitats. Each zebra will be in one of the habitats.
In each time unit, a zebra can move to an adjacent square in one of the four compass directions (north, south, east, west), but can't move off the edge of the grid.
In each of the habitats, there is a certain amount of food (grass). Of course, as zebras eat the grass, it disappears. The grass does slowly regrow as time passes.
When zebras eat, they gain "energy". If they don't eat for long enough, they burn all of their energy reserves and starve to death.
Zebras decide which direction to move (or to stay where they are) based on the amount of food available, and the number of other zebras in that it will have to share the food in that location with. The zebra always makes the best decision based on what it can see in the adjacent habitats.
As with any model, there will be many parameters that can be adjusted to tune the way the system works. For example, the amount of grass that a single zebra eats. It may be necessary to change these values frequently, so the design should allow for this.
Answer these questions using that problem statement.
When you're done, create a ZIP file containing all of the files you created for this lab and submit it with the submission server. Remember to include an additional class for testing your work.