This mechanism consists of three major steps:
initialization, which prepares alternative populations for the next steps;
identifying seven nearest neighbors;
and orientation change which adjusts velocity and position of particles based on those neighbors and selects the best alternative.