Altruistic Zipper Effect

This is written entirely in HTML and Javascript (verging on Parallel Processing!). The goal wasn't a nice UI, but an example of complex code (a nicer UI can come later if I get time).

This was a theory I had re drivers being altruistic in the sense of keeping left when possible allowing faster traffic free flow (phase 1).
A later addition was to "move to the right" if someone to the left was being held up (making space). This significantly reduced the number of "red lights" / "boxing in" (phase 2).
Legally in the UK, it is not a traffic violation to "undertake" if you haven't changed lane, but it is a traffic violation to "weave" or change lane to then undertake (however, how long is "reasonable" before you can then undertake having changed lane?). So a later addition was also included to see if "allowing weaving" would make any significant difference to traffic flow (phase 3).

Of course all of this fails when the traffic volume is simply too high (such as during rush hours). Here are the running results, there is also an explanation of the rationale and calculation criteria which I could do with someone reviewing please: Results.

Altruistic: 0% 25% 50% 75% 100% Boxing Weaving
Presets: Sleepy Fifty-Fifty Three-Quarter Legal No No
Selfish Wakey-Wakey Half-n-Half Optimistic Altruistic Yes No
Thoughtless Pessimistic Expected Almost-There Pushy No Yes
Rude Over-Half Getting-There Free-for-All Yes Yes

  Lanes:   Cars:   Frame Delay:      
ALTRUISM SETTINGS:         

Red Lights / Held Up
Preset Lanes Cars Road
Stretch
Frames % Likely
Altruistic
Avoid
Boxing?
Weaving
is OK?
Average %
Braking
Lowest % Median % Highest % Avg Speed
(mph)
Bespoke