GithubHelp home page GithubHelp logo

snow's Introduction

Snow

Arctic predator-prey simulation

Simulates a biotop in the Arctic, containing prey (rabbit) and predator (fox). It contains a simulation based on the properties of the animals set in their classes. The world is a two-dimensional int-Array. Every animal is simulated for its own. By using the method initialize(), the program tires to place the requested amount of animals. Every tick, foxes can hunt (find and replace rabbits in their surroundings) or move, rabbits can move (they can't see foxes, so movement is random), new animals can be born if there is space (animals can only reproduce after serveral ticks. If mulitiple trys to place a child failed, it will not be born (simulation of stress). Foxes have to eat rabbits to survive, rabbits have a chance to find food every turn. You can enable the mutation of the genome of every animal and simulate evolution by this, but be aware that this can quickly lead to instable systems. The GUI contains a complete control panel, with infos, a pause button and the possiblity to start the game with a fixed amount of animals. There are also two visualizations: A two dimensional world map with every animals drawn in and a long term graphic showing the amount of animals of each species.

Note: The best results are achieved by a starting amount of 2000 foxes and 4000 rabbits without mutations. As this is a Monte-Carlo-simulation, results are stochastic.

Disclaimer: This is a toy program. Treat it as a demonstration of a simple predator-prey simulation.

snow's People

Contributors

ngoetz avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.