ademakdogan / swarm_behaviour

Several swarm behavior approaches have been coded

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

SwarmBehaviour

Several swarm behavior approaches have been coded. The coding of this project was inspired by here. The basic swarm model consists of three simple steering behaviors which describe how an individual member maneuvers based on the positions and velocities its nearby member

  • Separation: steer to avoid crowding local members
  • Alignment: steer towards the average heading of local members
  • Cohesion: steer to move toward the average position of local members

Each member in the swarm has position, velocity and acceleration vectors. Apart from these, there are also a few forces applied to the members. By changing the effects of these forces or removing them completely, the effects of other forces can be seen more clearly. The swarm can be observed below under the influence of different forces.


  • Alignment


  • Separation + Alignment


  • Cohesion


  • Cohesion + Alignment


  • Separation + Alignment + Cohesion


How to run code ?

  make install

and then;

  python main.py

References

About

Several swarm behavior approaches have been coded


Languages

Language:Python 98.0%Language:Makefile 2.0%