2021-01-20

Boids

Classic Steering Forces

Align Force

Range

Power

Separate Force

Range

Power

Cohere Force

Range

Power

Predator Interactions

Predators

Range

Population

Boid predator avoidance

Range

Power

Boids

The boids algorithm is an artificial life simulation discovered by Craig Reynolds that models the coordinated movements of animal groups like flocks of birds and schools of fish.

The movement of each individual "boid" is governed by a few simple rules. From these simple local rules emerges complex and organized behavior at the group level, making the boids algorithm a beautiful example of emergent complexity.

In this implementation you can play around with the range and magnitude of the steering forces and observe the impact on group behavior and boid survival.

The code is available here.

Steering Forces

There are 3 classic steering forces, to which I added a predator force as well. Here is a description of the classic forces from Craig Reynold's own site.

steering-forces.png