Sign in to follow this  
mderdem

Inertia and Rotations When Rolled

Recommended Posts

I have implemented a rigid body dynamics simulation from Barrafs paper. I am having some problems related to rotations. In a world with gravity=0, I have two objects (Object A&B). My coordinate system is y forward, x on right, z up. There are no forces acting on them, but only a torque acts on each of them. Torque Vec in body coordinate system is [0,0,1] which is supposed to turn the object to left or right (heading). Both are positioned in the scene with a roll angle of 45 degrees. Object A has Ixx=Iyy=Izz=1 Object B has Ixx=5, Iyy=Izz=1 Both defined in body coord. system. I have expected both objects to turn in the same way but obj B slower due to lager Ixx. However object B follows a completely different turning path while object A turns around its own Z axis nicely. Could anybody tell me if this is an expected behaviour ? It is also not clear to me in which coordinate system Baraff defines the torques acting the body. Any hints would be appreciated. Thanks, MDE

Share this post


Link to post
Share on other sites
I'm not familiar with the specific paper, but it is weird, indeed...
No matter how you calculate the angular velocity (either from integration of acceleration, or directly from the angular momentum) you have to use the inverse inertia matrix somewhere. Since it depends on the actual orientation, could it be that there's something wrong with it? How exactly do you calculate it?

Do you get realistic results -otherwise- with what you've got so far?

Share this post


Link to post
Share on other sites
Hi again,

I was preparing to describe the Baraff's paper. But I have realized an issue with Baraff's paper. Could anybody confirms this error ?

He describes:
w(t) = I(t)L(t)         (2-42, page G15)

where
   w: angular velocity
I: inertia tensor (in world CS)
L: angular momentum

The example C code writes:
   w(t) = IInv(t) L(t)   (page G17)

The example code seems to be correct since angular momentum is defined as:
   L = I x w

hence
   IInv * L = w

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this