[ODE] Problem with Hanging Objects under gravity
Jon Watte (ODE)
hplus-ode at mindcontrol.org
Tue Aug 1 08:23:54 MST 2006
> This model is not succesfull as within a short span of time, due to gravity ,
> the ropes start swinging, and fnally become unstable.
> Please suggest me on where am i making a mistake.
> Thanking you,
You need to introduce velocity and rotational velocity dampening to your
bodies in each step. Else the force added by gravity may add energy to
the system. Each step, for each body, do something like (from memory):
vel *= -0.01; vel *= -0.01; vel *= 0.01;
vel *= -0.03; vel *= -0.03; vel *= -0.03;
The multiplied numbers will of course need to change based on your
simulation and time step size.
Also make sure that the boxes don't actually touch in the default
configuration -- you have to leave a little bit of clearance. For this
reason, I prefer to use ccylinders (capsules) for ropes.
More information about the ODE