In this demonstration, 30 vehicles exhibit unaligned collision avoidance behavior. They try to steer a collision-free path, threading through the crowd while attempting to stay on the yellow region. The avoidance of the gray obstacle is accomplished with the technique used by the green vehicle in the containment demonstration. Collision avoidance is obtained for a vehicle by considering each of the other vehicles, and determining (based on current velocities) when and where the two will make their nearest approach. A potential for collision exists if that nearest approach is in the future, and if the distance between the vehicles at nearest approach is small enough. The nearest of these potential collisions, if any, is determined. The vehicle then steers to avoid the site of the predicted collision. The vehicle will steer laterally to turn away from the potential collision. It will also accelerate forward or decelerate backwards to get to the indicate site before or after the predicted collision. In the diagram above, a white line is drawn between two vehicles which are steering to avoid a potential collision. A failure of collision avoidance is indicated by a vehicle's color changing to red when it touches another vehicle. (In this demonstration, each vehicle averages about 5 such failures per 1000 simulation steps.)
When the vehicles in a group are aligned a less complicated collision avoidance strategy can be used which is based solely on relative position. An example of this separation behavior can be seen in the crowd path following demonstration.