Skip to content

momentOfInertia tensor should be symmTensor, not diagTensor in sixDofRigidBodyMotion class

The moment of inertia is a symmetric tensor, not necessarily diagonal.

This should be reflected in its type in the sixDoFRigidBodyMotion class:

https://develop.openfoam.com/Development/openfoam/-/blob/master/src/sixDoFRigidBodyMotion/sixDoFRigidBodyMotion/sixDoFRigidBodyMotion.H#L111

and in how it is specified in the dynamicFvMeshDict in cases using it.

Indeed, for a symmetric matrix (with all eigenvalues non-zero) one can always find an orthogonal basis in which it is diagonal. This basis, however, often does not coincide with the natural coordinate system of a given simulation case.

Edited by Johan Roenby