Giter VIP home page Giter VIP logo

evolution-simulation's Introduction

Evolution-Simulation

Evolution Simulation is a fun project to visualise how organisms evolve according to their environment over a period of time. We have made a simple set of rules as to how the organism may travel, eat, reproduce or die. Every generation has some random variation and the traits of organisms alive are plotted. The Zoo directory contains multiple such environments with variations in rules and organisms type. For instance, the Prey-Predator directory has organisms which are either prey or predator and the graph of their populations over time resembles the corresponding differential equations. More such simulations with different rules are to be added.

Motivation

This project was inspired by the Evolution playlist by Primer on Youtube.

Tech Used

Present code is written in Python 3 and pygames is used to visualize simulation and Matplotlib is used to plot graphs.

Libraries used

  • numpy
  • pygame
  • matplotlib
  • os (to simplify testing)

Running the code

$ git clone https://github.com/Tanmay-Kumar-Sinha/Evolution-Simulation.git
$ cd Evolution-Simulation
$ cd Zoo/
$ ls

Now select which simulation you want to run. Let's choose Simple_Ecosystem.

$ cd Simple_Ecosystem/
$ python3 simulation.py

A pygame window will pop up and the simulation begins. Many variables that can be tweaked are present in simulation.py. Feel free to modify and experiment with them. Each simulation has certain features that we are plotting w.r.t. time and the details can be found in their corresponding folders.

Contribute

We will be glad to receive support and new ideas from our visitors. If you find any problem/bug in the code, feel free to raise an issue and/or a pull request after resolving it. Given that this is a fun project, all creative ideas are welcome. A few major things in our minds are

  • Code optimization
  • Visualize using unity
  • Better Graphs
  • Making more simulations with different rules and organisms

Team

License

MIT License

evolution-simulation's People

Contributors

kharyal avatar anomandaris-irake avatar y5yash avatar tanmaysinha18 avatar

Watchers

James Cloos 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.