Flocking Behaviour
Flocking behaviour is an example of emergent phenomenon, wherein a simple set of interactions can give rise to complex, coordinated behaviour.
Number of boids:
Kinetic parameters
Speed of boids:
Noise amplitude:
Social interactions
Radius of interaction:
Orientation weight:
Attraction weight:
Description
There are three types of interactions: Repulsion, Orientation and Attraction:
- Repulsion: If boid(s) are present within radii \(R_r\) of a boid (indicated by red colored circle), then the boid moves in a direction away from the average direction of approach of other boid(s).
- Orientation: Every boid tries to orient itself along the average direction of motion of the boids present in it's circular neighbourhood \(R_i\) (indicated by blue colored circle).
- Attraction: Every boid tries to move towards the centre of mass of the group of boids present in the same circular neighbourhood as above (\(R_i\)) (indicated by blue colored circle).
Orientation and Attraction operate only in the absence of repulsion, and they operate together. Their effects combine in a weighted manner, described by parameters \(\omega_o\) and \(\omega_a\). Additionally, a noise component is introduced to the intended direction of every boid's motion. This representes the errors in their perception and motion.
The speed of the boids, the radius of interaction \(R_i\), the noise amplitude, the orientation weight \(\omega_o\) and the attraction weight \(\omega_a\) can be modified in real-time. For demonstration purposes. The radius of repulsion \(R_r\) (depicted by a red circle) and the circular neighbourhood of interaction (depicted by a blue circle) are shown for a single boid.
Note:
- This simulation was developed under the guidance of Prof. Vishwesha Guttal (Lab webpage).
- This simulation implements the model described in "Predatory Fish Select for Coordinated Collective Motion in Virtual Prey" by C. C. Ioannou, V. Guttal, I. D. Couzin (https://doi.org/10.1126/science.1218919).
- For considering cross-border interactions, the landscape is repeated in the eight cardinal directions. Hence, this simulation is computationally expensive and may lag on lower-end devices. It is not recommended to have 100+ boids.
- The sum of orientation weight and the attraction weight are constrained to be between 0 and 1.
Developed by ChanRT | Fork me at GitHub