[ODE] Performance with multiple cars

Jeroen Schmitz Jeroen Schmitz" <ode at q12.org
Wed Mar 12 03:04:02 2003


I have a simulation with a car, much in the same way most ode car
simulations are built: a box for the carbody, 4 spheres for the wheels
that are connected to the body with hinge-2 joints. The car is driving
on a surface that is made using the tri-collider and the sides of the
road are also defined using the tri collider (you could see that as
walls).
Now this works quite well if I only have one car driving around and it
also works fairly good if I add a second car to the simulation (if you
hit the second car with the first one, everything acts like you would
expect).
However, I have also tried my simulation with 8 cars in total. This also
works, until you make the cars collide altoghether. For instance, I have
set the 8 cars in a straight line behind each other and then I use the
last car to hit into the back of the car in front of them, sorta like a
train effect. The simulation becomes very slow then, probably because
all cars are colliding with each other, and eventually the program
crashes if you try to hit the cars for a while in this way.

Is this behaviour to be expected in such a case or should the
performance of ODE still be usable in this case and am I doing something
wrong here? Note that the simulation works quite well with the 8 cars,
as long as not too many cars collide with each other!

Jeroen