Parking Lot
Shoppers walk from parked cars to a store entrance while cars drive the aisles and brake for them.
- Walker
- Moving car
- Braking for a walker
- Braking for the car ahead
- Parked car
- Store entrance
- Wall
- Driving loop
Shoppers step out of their parked cars and walk to the green store entrance; a moving car turns red while it brakes for someone in its path and amber while it brakes for the car ahead. Drag with Wall to draw walls, or with Erase to remove walls and parked cars; Rerun starts again with the lot as drawn.
How is Parking Lot working for you?
About Parking Lot
Parking Lot simulates shoppers walking from their parked cars to a store entrance while other cars drive through the lot. Each person steps out at the end of a parked car and walks to the door with the social force model of Dirk Helbing and Péter Molnár: they steer along the shortest route that a person fits through, keep a distance from others, from parked cars and from moving cars, and look one second ahead to step aside.
Moving cars drive a loop through the aisles at the speed you set. A driver who sees someone in the stretch the car needs to stop, one second of reaction plus braking at 3 m/s², brakes and waits; the car turns red while it brakes for a person, and amber while it brakes to keep its distance behind the car ahead. Each time a car has to brake for a person counts as one conflict, the measure that traffic-conflict studies use as an early sign of risk, as in the framework of Aliaksei Laureshyn, Åse Svensson and Christer Hydén (2010).
Compare aisles that lead toward the store, rows along the store that people have to cross, and rows along the store with a walkway to the door. Set how many people arrive per minute, turn moving cars on or off, set how many drive and how fast, draw walls or erase parked cars, and read the mean walking time and the number of conflicts.
How to use Parking Lot
- Pick a layout. Aisles toward the store run straight to the entrance; Aisles along the store make people walk across the aisles; Walkway to the door leaves out one column of spaces so people can walk straight to the door. Busy Saturday sends 45 people a minute into the lot with six cars driving.
- Set the arrivals. Arriving sets how many shoppers step out of a parked car per minute. Each walks to the green entrance in the store wall at the top.
- Add traffic. Moving cars turns the driving cars on or off. Cars driving sets how many circle the lot, and Car speed how fast they drive when the way is clear; the thin line shows their loop. A car turns red while it brakes for a person and amber while it brakes for the car ahead.
- Read the results. The readout gives how many people are walking and have reached the door, their mean walking time over the last 50, the conflicts so far and how many cars are braking. The charts follow the walking time and the conflicts per minute.
- Compare runs. At 300 s each run adds a row to the Runs table: the mean walking time of everyone who reached the door, the conflicts and the number of people at the door, with the settings that differ between rows. Reset clears the table.
- Change the lot. With Pointer set to Wall, draw walls or curbs; with Erase, rub out parked cars or walls. Routes update when you release. Rerun starts the same arrivals again from t = 0 in the lot as drawn; Restart clears your walls and erasing and starts the layout again; Reset also returns every setting to its default.
- Export. Save a PNG or record a video or GIF. Record 30 s from the start runs the same lot again from the beginning and records its first 30 seconds, frame by frame. The CSV holds the walking time and the conflicts per minute every second since t = 0, and the Runs table. A share link carries the walls you drew and the cars you erased.
Frequently asked questions
What counts as a conflict?
A conflict is counted when a moving car has to brake because a person is in the stretch it needs to stop: one second of driving before the driver reacts, plus the braking distance at 3 m/s², plus a meter. Each car counts each person once, however long it waits. Nobody is hit in the simulation; conflicts measure how often drivers and walkers have to sort out who goes first.
Which layout gives the fewest conflicts?
In the simulation, aisles that lead toward the store let people walk along an aisle instead of crossing several, so they meet fewer cars, and their walks are shortest. A walkway to the door shortens the walk from rows along the store, and everyone then crosses the aisles at the same place. Try each layout with the same arrivals and cars and compare the readouts.
How far does a car need to stop?
At 10 km/h a car covers 2.8 m during a one-second reaction and about 1.3 m more while braking at 3 m/s², about 4 m in all. At 20 km/h that grows to about 10.7 m, because the braking distance grows with the square of the speed. Raise Car speed to see the conflicts rise.
Why don't people walk between the parked cars?
They do where there is room. Routes keep 30 cm from cars and walls, so a gap narrower than about 60 cm is left out, and people step out at the end of their car where the aisle is.
Is this a real traffic safety tool?
It is an educational simulation. Real parking design uses measured traffic, sight lines and design guidance. For crowds in buildings, see Mall Entrance and Crowd Evacuation, and for cars on a road, Traffic Jam.
References
- Helbing, D., & Molnár, P. (1995). Social force model for pedestrian dynamics. Physical Review E 51(5), 4282–4286.
- Helbing, D., Farkas, I., & Vicsek, T. (2000). Simulating dynamical features of escape panic. Nature 407, 487–490.
- Laureshyn, A., Svensson, Å., & Hydén, C. (2010). Evaluation of traffic safety, based on micro-level behavioural data: theoretical framework and first implementation. Accident Analysis & Prevention 42(6), 1637–1646.
- Zanlungo, F., Ikeda, T., & Kanda, T. (2011). Social force model with explicit collision prediction. EPL 93, 68005.





