Quote:
Originally Posted by Aur
Hi! ...At the moment my favourite idea is a crowd simulator. But I'd be welcome to hear anyother ideas on simulations. Thanks for any help. 
|
Hi! And welcome to Hypography!
Funny you should ask that. I've done quite a bit of simulation over the years as part of my job(s), and one day hoped to find a language I could use to do my own "sims" at home. Obviously, there are many such languages now. But I don't have the time!
The one sim I always wanted to do was to simulate traffic on a multi-lane, limited access highway. Like an interstate. I got the idea while driving on the LBJ Freeway that circles Dallas. I would build a sim of a "circular" interstate loop, with L lanes (where I could set L in the program), and X exit ramps and N entrance ramps.
The "cars" would be the heart of the sim, because it is there I would be able to simulate not just the vehicles, but their DRIVERS.

So, some car parameters would be:
Average driving speed over the posted speed limit, as an average (+ or -);
Average acceleration rate, when accelerating
Average braking rate, when braking
Probability of using turn signals
Average drift rate when changing lanes
Visual knowledge, measured in meters ahead of their own vehicle
Mirror knowledge, measured in meters behind own vehicle
Left knowledge, size of blind spot on the left
Right knowledge, size of blind spot on the right
Closing rate fright (how fast must they be closing on a bumper before they hit brakes)
Closing distance fright (how close must they be to a bumper before they hit brakes)
Probability of urge to change lanes
Drunkenness factor, 0-100, where 100 means random steerage and speed
Probability of responding to turn signal within Visual knowledge
Probability of responding to brake lights within Visual knowledge
Probability of being uncomfortable next to car in next lane
Probability of responding to any urge or discomfort by changing lanes
Probability of urge to go faster
Probability of urge to slow down
Probability of checking blind spots before changing lanes
Separate from the cars, other parameters I would control would be:
Average time between new car entry, at entrance ramp N-sub-a
Average time between car exits, at exit rampt X-sub-a
Lane blockage at position P, lane L-sub-a.
Speed rate X turn rate yielding non-zero probability of loss of control (NZPLOC)
Speed rate X brake rate yielding NZPLOC
You get the idea.
Then I would set up the sim for, maybe 4 lanes, 10 miles around the loop, speed limit of 60 MPH, turn on the entrance ramps until I had a density of about 1 car per 20 meters per lane and see how accidents happen. And how this affects traffic flow.
I also want to see if I could simulate "reverse compression waves" in an otherwise normal flow of traffic. This is where at a specific traffic densities, at one position in the loop, the cars get closer together, slow down, then speed up and get further apart, forming a temporary "clump" -- this clump travels BACKWARDS around the loop, typically at speeds about 1/4 of the forward average traffic flow. These things are REAL, I've been in quite a few of them!