Flocking behavior, swarm models, and art

Posted on 02/11/2011 by


Seems like swarm algorithms and flocking behavior are pretty popular these days.  Visualizations of those algorithms are pretty sparse, though.  Today I ran across the work of some architecture students, Hyun Chang Cho, Jun Ho Cho, and Eun Ki Kang, all involved in some really cool visualizations.

Another impressive swarm visualization comes from Samuel Brisette (images taken from his site, here–please go there and take a look at his portfolio, it is pretty amazing):
Brisette demonstrates the computational model behind his work:

This is some pretty cool stuff.

So I started looking around at more computational tools for swarmvis.  An impressive tool (that you can actually use yourself now; paper here), it is used for modeling flocking behavior.

Originating in only a few simple rules, the program captures the idea that I have been discussing for the past few days regarding emergent properties of complex systems.  As I argued in a previous post, what the human brain is particularly good at is recognizing patterns.  Once we find patterns in complex systems, we can develop fairly simple rules that can explain these patterns (I also suggested that this is a radical departure from contemporary statistical methods, especially keeping in mind the prevalence of stochastic modelling).  Don Miner and Niels Kasch (site here), authors of swarmvis, work backward to first form a set of simple rules that nonetheless produce quite complex results.

The agents follow the following rules:

  • If a corner, be attracted to the three other corners very slightly.
  • If not a corner, be attracted to the two closest corners with great, but equal, strength. That is, the output force vector of this rule is the sum of two vectors of magnitude f. Note that when an agent is on the line formed by its two closest corners, the forces cancel each other out.
  • Avoid any agents that get too close.

That’s it–and here is the result:

Pretty amazing.  It follows the classical ‘boid rules’ for flocking behavior (after Craig Reynold’s boid creatures), where behavior is determined by three features:

Separation, alignment and cohesion

(From Reynold’s site, here.  Please visit and take a look at the software section: there are some pretty cool flocking programs that you can use at home!)

Credit goes to Miner and Kasch for their work.