Handling large scale data for traffic simulation


We are trying to find the most suited game engine for simulation of large scale data of traffic.

Formerly, I tried a similar simulation to update thousands of objects that belong to pollution and it didn’t work very well. The thing is, the update function would bring the frame rate to 2 fps which wasn’t really optimal.

so the question is, can we use Unity to update car movements (more than 200 cars at a time) while trying to feed around 1,000,000 float numbers to the system for calculation?

Any thoughts on this would be great.

Thank you.

The real question is do you need to do ALL that data every frame? Most games of this kind will be doing a lot of faking behind the scenes.

If even after optimising the code its still too slow (and since you say 1,000,000, I would guess unity [and any game engine] will be too slow), you’ll want to consider making the process yieldable and processing the variables over a series of frames.

If desperate for speed, you might be able to feed the data into a shader and do it on the graphics card, since this sort of computation will probably be very suited to parallelisation.

Updating the positions of 200 cars in real-time, on the other hand, should be trivial.