Sunday, 2 February 2014

Programming swarm intelligence

Incidentally, exploring swarm intelligence isn't terribly difficult if you know a bit of programming... when I was experimenting with it, I just used VBA and Excel.  The trick is knowing object oriented programming and using it to create multiple entities that can interact in a virtual environment - e.g., by position on a 2 dimensional matrix.  Excel's main advantage is that its easy to dump the results out into a worksheet to examine and graph, though I wouldn't use it for any computationally heavy project.  Because the behavior of your entities is based on simple rules, the programming can be as basic as checking if the block in an array at the position ahead or behind is occupied, and then altering behavior accordingly... or assessing the values of the other members of the swarm and modifying its status in response. 

It would be nice if I could point to a bespoke programming environment for programming and experimenting with these concepts... I suspect with some looking I could find one, but it would probably be locked away in some university comp sci lab. I did find reference to this book which has a chapter on swarm intelligence and some pseudocode to start people out with however.

No comments:

Post a Comment