com.kuka.math.physics
Class Inertia

java.lang.Object
  extended by com.kuka.math.physics.Inertia

public final class Inertia
extends Object

Represents the inertia of a physical object along its main inertia axes. The SI unit of inertia is kg * m^2.


Field Summary
static Inertia ZERO
          Immutable Inertia instance representing zero inertia.
 
Method Summary
 boolean equals(Object obj)
           
 double getJX()
          Gets the inertia of the object around the X axis.
 double getJY()
          Gets the inertia of the object around the Y axis.
 double getJZ()
          Gets the inertia of the object around the Z axis.
 int hashCode()
           
static Inertia of(double jX, double jY, double jZ)
          Creates a new immutable instance of this class, with the given values of inertia along the X, Y and Z axes of an object's mass centroid.
static Inertia of(Vector3D values)
          Creates a new immutable instance of this class, with the given values of inertia along the X, Y and Z axes of an object's mass centroid.
 String toString()
          Returns a textual description of the inertia.
 Vector3D toVector()
          Creates a Vector3D of the inertia's values.
 Inertia withJX(double value)
          Returns a new Inertia instance with the X inertia set to the given value.
 Inertia withJY(double value)
          Returns a new Inertia instance with the Y inertia set to the given value.
 Inertia withJZ(double value)
          Returns a new Inertia instance with the Z inertia set to the given value.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

ZERO

public static final Inertia ZERO
Immutable Inertia instance representing zero inertia.

Method Detail

of

public static Inertia of(double jX,
                         double jY,
                         double jZ)
Creates a new immutable instance of this class, with the given values of inertia along the X, Y and Z axes of an object's mass centroid.

Parameters:
jX - The inertia along the X axis of an object's mass centroid in [kg * m^2].
jY - The inertia along the Y axis of an object's mass centroid in [kg * m^2].
jZ - The inertia along the Z axis of an object's mass centroid in [kg * m^2].
Returns:
the new immutable instance

of

public static Inertia of(Vector3D values)
Creates a new immutable instance of this class, with the given values of inertia along the X, Y and Z axes of an object's mass centroid.

Parameters:
values - A Vector3D with the values of the inertia along the axes of an object's mass centroid in [kg * m^2].
Returns:
the new immutable instance

getJX

public double getJX()
Gets the inertia of the object around the X axis.

Returns:
The inertia of the object around the X axis in [kg * m^2].

getJY

public double getJY()
Gets the inertia of the object around the Y axis.

Returns:
The inertia of the object around the Y axis in [kg * m^2].

getJZ

public double getJZ()
Gets the inertia of the object around the Z axis.

Returns:
The inertia of the object around the Z axis in [kg * m^2].

withJX

public Inertia withJX(double value)
Returns a new Inertia instance with the X inertia set to the given value.

Parameters:
value - The new value in [kg * m^2].
Returns:
a new immutable instance of Inertia

withJY

public Inertia withJY(double value)
Returns a new Inertia instance with the Y inertia set to the given value.

Parameters:
value - The new value in [kg * m^2].
Returns:
a new immutable instance of Inertia

withJZ

public Inertia withJZ(double value)
Returns a new Inertia instance with the Z inertia set to the given value.

Parameters:
value - The new value in [kg * m^2].
Returns:
a new immutable instance of Inertia

toVector

public Vector3D toVector()
Creates a Vector3D of the inertia's values.

Returns:
a new vector containing the inertia's values

toString

public String toString()
Returns a textual description of the inertia. The representation is subject to change. The following string can be regarded as typical:

"[1.23, 300.00, -20.20]"

Overrides:
toString in class Object
Returns:
a brief description of the inertia

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object


Copyright © 2019. All rights reserved.