Goal: determine traffic for Streets and Rail
Given:
-Grid: X * Y (e.g. 100*100)
-Houses (each house is occupied by M people)
-Workplaces (each workplace can employ N people)
-Streets & Rail
Constraints:
-People move from houses to their workplaces and back
-update whole world in approximately every 3-5 seconds. The world doesn’t need to be updated every iteration. every iteration only updates a part of the world
How would I go about to determine the traffic/congestion for each street/rail tile on the grid? I want to simulate people moving from their house to the closest available workplace. I cannot do the calculation for the whole map in a single iteration, so I figured I calculate only part of the map in each iteration, reducing computations.
There is a very easy way calculating traffic by counting the number of people close to a street/rail tile. But that’s not what I want to do. It’s not very realistic.
Suggestions? Algorithms? Do you know of anyone/link showing similar approaches? Similar discussions on the topic?
Thanks! Any ideas/pointers are highly appreciated. Please note, that this is for a city simulation type of game ;D