gazebosim / gazebo-classic

Gazebo classic. For the latest version, see https://github.com/gazebosim/gz-sim
http://classic.gazebosim.org/
Other
1.19k stars 480 forks source link

Too large values for explicit joint damping can cause models to fly apart #2554

Open osrf-migration opened 5 years ago

osrf-migration commented 5 years ago

Original report (archived issue) by Shane Loretz (Bitbucket: Shane Loretz, GitHub: sloretz).


The tag applies a force depending on the velocity of the joint. If this value is too large the force will result in a new velocity that's greater than the previous timestep in the opposite direction, which oscillates until the model flies apart.

It would be nice if explicit damping would cap the force applied to the amount needed to stop joint movement, though I'm not sure how feasible getting that number is.

osrf-migration commented 5 years ago

Original comment by Louise Poubel (Bitbucket: chapulina, GitHub: chapulina).


osrf-migration commented 5 years ago

Original comment by Tully Foote (Bitbucket: Tully Foote, GitHub: tfoote).


The world attached to #2558 can reproduce this oscillation. In testing it usually blows up to NaN values in about 61 simulator steps.

osrf-migration commented 5 years ago

Original comment by Rahul Deo (Bitbucket: rahuldeo4).


@Shane: Usually smaller step say 0.0001 should work.

Edit: realised it is very old, however, the solution is valid.

osrf-migration commented 5 years ago

Original comment by Tully Foote (Bitbucket: Tully Foote, GitHub: tfoote).


For a given damping force you can make the step size smaller and consequently the force will not saturate as quickly and cause the oscillation. But that only changes the range of problematic damping forces. And a smaller step size has significant performance implications and there will still be a critical damping force that will cause these oscillations.