## Class MomentsOfInertia

• ```public class MomentsOfInertia
extends Object```
The moment of inertia, otherwise known as the angular mass or rotational inertia, of a rigid body determines the torque needed for a desired angular acceleration about a rotational axis. It depends on the body's mass distribution and the axis chosen, with larger moments requiring more torque to change the body's rotation.

More in https://en.wikipedia.org/wiki/Moment_of_inertia.

Author:
Peter Rose, Aleix Lafita
• ### Nested Class Summary

Nested Classes
Modifier and Type Class Description
`static class ` `MomentsOfInertia.SymmetryClass`
• ### Constructor Summary

Constructors
Constructor Description
`MomentsOfInertia()`
Creates a new empty instance of MomentsOfInertia
• ### Method Summary

All Methods
Modifier and Type Method Description
`void` ```addPoint​(javax.vecmath.Point3d point, double mass)```
`double` `getAsymmetryParameter​(double threshold)`
`javax.vecmath.Point3d` `getCenterOfMass()`
`double[]` `getElipsisRadii()`
The effective value of this distance for a certain body is known as its radius of / gyration with respect to the given axis.
`double[][]` `getInertiaTensor()`
`javax.vecmath.Matrix3d` `getOrientationMatrix()`
The orientation Matrix is a 3x3 Matrix with a column for each principal axis.
`javax.vecmath.Vector3d[]` `getPrincipalAxes()`
The principal axes of intertia
`double[]` `getPrincipalMomentsOfInertia()`
`double` `getRadiusOfGyration()`
`MomentsOfInertia.SymmetryClass` `getSymmetryClass​(double threshold)`
`double` `symmetryCoefficient()`
• ### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`
• ### Constructor Detail

• #### MomentsOfInertia

`public MomentsOfInertia()`
Creates a new empty instance of MomentsOfInertia
• ### Method Detail

```public void addPoint​(javax.vecmath.Point3d point,
double mass)```
• #### getCenterOfMass

`public javax.vecmath.Point3d getCenterOfMass()`
• #### getPrincipalMomentsOfInertia

`public double[] getPrincipalMomentsOfInertia()`
• #### getPrincipalAxes

`public javax.vecmath.Vector3d[] getPrincipalAxes()`
The principal axes of intertia
Returns:
• #### getOrientationMatrix

`public javax.vecmath.Matrix3d getOrientationMatrix()`
The orientation Matrix is a 3x3 Matrix with a column for each principal axis. It represents the orientation (rotation) of the principal axes with respect to the axes of the coordinate system (unit vectors [1,0,0], [0,1,0] and [0,0,1]).

The orientation matrix indicates the rotation to bring the coordinate axes to the principal axes, in this direction.

Returns:
the orientation Matrix as a Matrix3d object

`public double[] getElipsisRadii()`
The effective value of this distance for a certain body is known as its radius of / gyration with respect to the given axis. The radius of gyration corresponding to Ijj / is defined as / http://www.eng.auburn.edu/~marghitu/MECH2110/C_4.pdf / radius of gyration k(j) = sqrt(I(j)/m)

`public double getRadiusOfGyration()`
• #### getSymmetryClass

`public MomentsOfInertia.SymmetryClass getSymmetryClass​(double threshold)`
• #### symmetryCoefficient

`public double symmetryCoefficient()`
• #### getAsymmetryParameter

`public double getAsymmetryParameter​(double threshold)`
• #### getInertiaTensor

`public double[][] getInertiaTensor()`