Simulation
Boids
Boids are little agents that move like a flock of birds or a school of fish. Nobody leads. Each one only looks at its close neighbors and follows three rules.
Alignment: head the same way. Cohesion: stay close. Separation: don't crowd. Move the sliders to see what each rule does. More on Wikipedia.
Alignment
Head the same way as your neighbors.
Cohesion
Move toward the middle of the group.
Separation
Keep a little personal space.