Nature's complex web of life never fails to amaze, particularly when it comes to the concept of collective intelligence. Whether it's the formations by a bustling ant colony or the synchronised flight of a flock of birds, nature demonstrates the art of collaboration and harmony. This exhibition of collective behaviour has inspired scientists and researchers to delve into the mysteries of swarm intelligence. Through their endeavours, revolutionary findings and inventive approaches to problem-solving have emerged, pushing the limits of our understanding.
Swarm intelligence are decentralised or self-organised systems inspired by the collective behaviour observed in nature. It ranges from social insects, herd/flocking behaviour, social interactions and even evolution. Because of its decentralised specialty, swarms are more robust, adaptable and scalable in dynamic environments.
Emergence of swarms describes the spontaneous formation of behaviours from the interactions between individual agents. Like the demo in the title banner, the little white dots were not explicitly programmed to surround the mouse pointer but it naturally emerges as they interact individually. These naturally-occurring phenomenons are studied by scientist to come up with computational solutions in practical problems. One of them is using it as an optimisation method, Particle Swarm Optimisation (PSO) to solve complex mathematical problems.
Particle Swarm Optimisation (PSO), Conceived by Dr. James Kennedy and Dr. Russell Eberhart in 1995, PSO mimics the social behaviour of bird flocks and fish schools to efficiently explore and exploit search spaces in pursuit of optimal solutions. At its heart, PSO embodies the essence of cooperation and competition, as particles navigate the solution space guided by their own experiences and those of their neighbours.
Update according to the formula:
Variables:
Pi means the position of the ith particle.
Vi means the velocity of the ith particle.
t means the current time, whereas t+1 means the next second.
w is the inertia weight, controlling the particle's tendency to continue in its current direction.
c1 and c2 are acceleration coefficients that control the influence of personal and social components, respectively.
best(i) is the best value of the ith particle.
bestglobal is the best value from all particles.
Repeat step 2 until reach a satisfactory solution or exceeding a maximum number of iterations.
The results can either be plotted as a line graph from start to finish or output the the optimised result.
It is also possible to visualise the process on a 3D graph. The individual blog posts explores the performance of PSO on a 3D graph.
Take example of the PSO on an Ackley function. Feel free to Try PSO by clicking the buttons in order!