2
\$\begingroup\$

If we have an inertia tensor in local coordinates with a basis matrix B and we want to transform it to other local coordinates with basis matrix A, is it right to do the following:

A* inv(B) *Inertia Tensor

Where my idea is to shift the inertia tensor to world coordinates by multiplying it by the inverse of B, then from the world coordinates to the A coordinates by multiplying it with A matrix?

\$\endgroup\$
0

1 Answer 1

1
\$\begingroup\$

I'm sure sure of the practical value of this, but yes.

If you take a 3x3 inertia tensor matrix IB, and multiply it by the inverse of local basis matrix B, the result will be the tensor in the world coordinate system, I

You can then transform it again by the local transform for B which will give you IA:

//Indirect transform
I = inv(B) * IB
IA = A * I
//direct transform
=== IA = A * inv(B) * IB
//Alternatively, store the transform if you need to
=== BA = A * inv(B)
    IA = BA * IB

As I said though, I don't know what the practical value of this is though, as the inertia tensor is supposed to be unique to each collider, though without seeing your implementation I can't say for certain.

\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .