is local_inertia_tensor intentionally too much?

Discuss any questions about BEPUphysics or problems encountered.
Post Reply
Posts: 18
Joined: Sun Oct 04, 2015 4:41 pm

is local_inertia_tensor intentionally too much?

Post by yanbo2u » Mon Apr 17, 2017 5:57 am

for a standard box with L meter for every edge and m kg for mass, the inertia_tensor in x,y,z should be m*l*l / 6.

but when I check the value of box.LocalInertiaTensor matrix, the variable value seems to be 2.5 times of m*l*l/6.

Is it intentional or I misinterpret the value ?

Site Admin
Posts: 4437
Joined: Tue Jul 04, 2006 4:45 am

Re: is local_inertia_tensor intentionally too much?

Post by Norbo » Tue Apr 18, 2017 5:16 pm

Yup- higher inertia tends to help stability by reducing some oscillation. It's a total hack, but it's usually a good choice since most people don't notice "hey that box is behaving as if its mass is actually compressed to its outer edge rather than being a uniform distribution!" :)

The hack is controlled by the InertiaHelper.InertiaTensorScale, which does indeed default to 2.5. Changing that property only affects inertias calculated after the change; it doesn't do any retroactive updates.

Post Reply

Who is online

Users browsing this forum: Google [Bot] and 1 guest