btMultiBody unstability problems when using colliders

Post Reply
taesoobear
Posts: 3
Joined: Mon Sep 12, 2016 3:19 am

btMultiBody unstability problems when using colliders

Post by taesoobear »

I am a researcher working with motion capture data and complex multi-body characters having 50+ DOFs.

Recently, I tried to port my characters to use the btMultiBody class,
and it worked well until I added colliders to some links.
Without using colliders, the simulation worked perfectly.
Also, the simulation works well for simple models (<10DOFs) which have colliders.

However, it does not when I use more complex models. The simulation simply explodes.
Strangely, this stability issue appear even when non of the colliders actually collide.
For example, a 56DOF ragdoll free-falled well when I attached no collider.
But if I attach a small box to a foot of the ragdoll, the ragdoll simulation explodes within a few hundreds frames even though the ragdoll is falling from very high above the ground, and there there was no contacts involved.

I googled about this issue, and I found one technical paper which reports the same problem.
https://homes.cs.washington.edu/~todoro ... ICRA15.pdf
"We implemented a comparison instance that uses the new Featherstone functionality in Bullet, but this functionality is not yet fully debugged and exhibits unexpected behavior
in some simulations, so we were able to use this new functionality only in tests without contact."

Is this a known problem for the bullet team? Is there any easy way to fix it?
benelot
Posts: 350
Joined: Sat Jul 04, 2015 10:33 am
Location: Bern, Switzerland
Contact:

Re: btMultiBody unstability problems when using colliders

Post by benelot »

I never had any issues with the multibodies. I am not sure anymore, but you may know: Can you disable collisions between linked bodies? How do you know that you have no collisions? This sounds strange..
User avatar
Erwin Coumans
Site Admin
Posts: 4221
Joined: Sun Jun 26, 2005 6:43 pm
Location: California, USA
Contact:

Re: btMultiBody unstability problems when using colliders

Post by Erwin Coumans »

There should be no problem using btMultiBody, it has been used to simulate many robots with many dofs. Ignore that out-of-date paper reference, it was written by MuJoCo developers a few years ago.

Do the collision issues exist when you disable self-collision?

Do you have a URDF or SDF file you can share? Latest Bullet can load them, so we can easier track down your issue.
benelot
Posts: 350
Joined: Sat Jul 04, 2015 10:33 am
Location: Bern, Switzerland
Contact:

Re: btMultiBody unstability problems when using colliders

Post by benelot »

Or if you find yourself more in the situation that you can build a minimal example of your issue within the bullet example browser, that can help too. We then can easily plug the example into our own browser to debug the issue.
taesoobear
Posts: 3
Joined: Mon Sep 12, 2016 3:19 am

Re: btMultiBody unstability problems when using colliders

Post by taesoobear »

This thread is very old, but I finally had time to build a minimal example of my issue.
I cannot make the human character start with zero velocities unless I remove all multibody colliders.
Also, the box flies, unlike the MultiDofDemo.cpp which this example is based on.
To disable self-collision tests, I tried combinations of following.
pMultiBody->setHasSelfCollision(false); // disable self collision
world->addMultiBody(pMultiBody, 1<<igrp, ~(1<<igrp) );
world->addCollisionObject(col, 1<<igrp, ~(1<<igrp) );
bool disableParentCollision=true
but none of these seem to remove the initial instability problem. When using btRigidBody instances or other simulators instead of btMultiBody, there is no such problem. The attached file contains very simple source codes that reproduce this problem.
Attachments
hyunwoodemo.zip
(5.22 KiB) Downloaded 185 times
taesoobear
Posts: 3
Joined: Mon Sep 12, 2016 3:19 am

Re: btMultiBody unstability problems when using colliders

Post by taesoobear »

I did some more tests, and it gets even stranger.
After downloading the hyunwoodemo.zip attached above,
I gradually increased the initial height of the box.

startTransform.setOrigin(btVector3(
btScalar(0.0),
0.31, // here
btScalar(0.0)));

When the box height is higher than 0.32 there is no problem.
Otherwise, the box starts with a strong initial velocity although it does not collide with anything.
Post Reply