# calculating inertia tensors for non-symmetrical volumes

This topic is 4802 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Hello! I'm in the process of creating a simple vehicle simulator, and i'm approximating the volumes of the vehicles with a cubiod, with the centre of mass slap-bang in the centre of the cuboid. this is resulting in crap handling (feels like a truck) and i can only attribute this to the symetrical inertia tesnor i am using, as most vehicles (cars specifically) (should) have a centre of mass that is near the gear stick. so, i was wondering, how do i calculate an inertia tensor that reflects an offset centre of mass (along a maximum of 2 axis)? im assuming of course that changing the location of the centre of mass would change the inertia tensor? if anyone could help clarify this for me i would be very grateful :) thanks for reading!

##### Share on other sites
use monte carlo integration. saying the center of mass is offset by X isn't enough. I depends on more then the position center of mass. what I'm saying is there are many I's such that this is true. what you sould do is define a density function throught your solid and integrate. it seems reasonable that in the density would change very little in the horizontal directions and vary with the vertical. that is to say if I cut the car in half(front to back) the two pices would be symmetric with respect to mass distribution. but if I cut it in half the other way, obviously the side of the car with the engin weighs more. you could mess around with a few functions to vary the density with respect to the vertical. like guassian or something like that. the cubiod has an easy paramaterization so it may be that monte calro integration isn't the best choice, in fact you could probably analitically integreate it provided your density fucntion is analitical.

Tim

##### Share on other sites
i see, thanks for that timw. i was kinda hoping i could just nudge the inertia tensor along an axis and all would be good. how naive i am :(

##### Share on other sites
An easy way to move the center of mass is to just move your collision geometry with respect to the rigid body it's attached too.

I don't know how your physics pipeline is setup, but if your collision primitive class has a local to world transform matrix which you update from your rigid body's local to world transform matrix, just tinker with it there.

I've found in the past that making the center of mass be closer to the bottom of the cars box collision, will make it harder to tip over and so it will handle more like race car.

-Steve.

##### Share on other sites
yea, thanks for that Steve, i was thinking the same thing too, but wouldnt the offset collision volume result in a nonsymmetrical inertia tensor for the volume :)

##### Share on other sites
Quote:
 Original post by Fusi0nyea, thanks for that Steve, i was thinking the same thing too, but wouldnt the offset collision volume result in a nonsymmetrical inertia tensor for the volume :)

I'm not sure exactly what it does mathematically to the inertia tensor, but I wouldn't worry about it for a simple game vehicle. Moving the collision volume so the center of mass is lower to the ground will make your vehicle handle much better. Try it and you'll see.

##### Share on other sites
Some inertia tensor stuff here, including pseudocode.

##### Share on other sites
You can calcualte shifted inertia tensors using the Parallel Axis Theorem.
(see: wolfram - Parallel Axis Theorem and hyperphysics - pat)

Also, a more general approach for calcuating the inertia tensors for any volume is described in "A Symbolic Method for Calculating the Integral Properties of Arbitrary Nonconvex Polyhedra". - October 1984, CG&A. (I dont think you can get it online, so you might have to wander to your local uni. library)

1. 1
Rutin
22
2. 2
3. 3
4. 4
5. 5

• 9
• 9
• 9
• 14
• 12
• ### Forum Statistics

• Total Topics
633308
• Total Posts
3011293
• ### Who's Online (See full list)

There are no registered users currently online

×