org.vizzini.math
Interface IDynamicState

All Superinterfaces:
Cloneable, IState, Serializable
All Known Implementing Classes:
DynamicState

public interface IDynamicState
extends IState

Defines methods required by a dynamic state of an object. The orientation and position relate object coordinates to world coordinates. Units should be consistent: mass, length, time. Typically acelerations are the only inputs, both for position and orientation, using the addXAcceleration() methods.

Since:
v0.2
Version:
v0.3
Author:
Jeffrey M. Thompson

Method Summary
 void addAcceleration(Vector acceleration)
          Add a positional acceleration.
 void addAngularAcceleration(Quaternion angularAcceleration)
          Add an angular acceleration.
 void addMassAcceleration(double massAcceleration)
          Add a mass velocity rate of change.
 void applyForce(Vector force)
          Apply the given force through the center of mass to this object.
 void applyForce(Vector force, Vector position)
          Apply the given force at the given position to this object.
 void applyForceLocal(Vector force, Vector position)
          Apply the given force at the given position to this object where these vectors are expressed in local coordinates.
 Vector getAcceleration()
          Return the acceleration in length time^-2 units.
 Quaternion getAngularAcceleration()
          Return the angular acceleration in radians time^-2 units.
 Quaternion getAngularVelocity()
          Return the angular velocity in radians time^-1 units.
 double getMass()
          Return the mass in mass units.
 double getMassAcceleration()
          Return the mass velocity rate of change in mass time^-2 units.
 double getMassVelocity()
          Return the mass rate of change in mass time^-1 units.
 double[] getMomentOfInertia()
          Return the moment of inertia in mass length^2 units.
 Vector getVelocity()
          Return the velocity in length time^-1 units.
 void setAcceleration(Vector acceleration)
          Set the acceleration.
 void setAngularAcceleration(Quaternion angularAcceleration)
          Set the angular acceleration.
 void setAngularVelocity(Quaternion angularVelocity)
          Set the angular velocity.
 void setMass(double mass)
          Set the mass.
 void setMassAcceleration(double massAcceleration)
          Set the mass velocity rate of change.
 void setMassVelocity(double massVelocity)
          Set the mass rate of change.
 void setMomentOfInertia(double[] momentOfInertia)
          Set the moment of inertia.
 void setVelocity(Vector velocity)
          Set the velocity.
 String toString()
          Return a string representation of this object.
 void zeroAcceleration()
          Zero the acceleration.
 void zeroAngularAcceleration()
          Zero the angular acceleration.
 void zeroAngularMotion()
          Zero all angular motion.
 void zeroMassAcceleration()
          Zero the mass acceleration.
 void zeroMotion()
          Zero all motion.
 void zeroTranslationalMotion()
          Zero all translational motion.
 
Methods inherited from interface org.vizzini.math.IState
clone, convertLocalToWorld, convertWorldToLocal, getOrientation, getPosition, getPreviousPosition, move, orientLocalToWorld, orientWorldToLocal, rotate, setOrientation, setPosition
 

Method Detail

addAcceleration

void addAcceleration(Vector acceleration)
Add a positional acceleration.

Parameters:
acceleration - Acceleration vector in length time^-2 units.
Since:
v0.2

addAngularAcceleration

void addAngularAcceleration(Quaternion angularAcceleration)
Add an angular acceleration.

Parameters:
angularAcceleration - Angular acceleration in radians time^-2 units.
Since:
v0.2

addMassAcceleration

void addMassAcceleration(double massAcceleration)
Add a mass velocity rate of change.

Parameters:
massAcceleration - Mass acceleration in mass time^-2 units.
Since:
v0.3

applyForce

void applyForce(Vector force)
Apply the given force through the center of mass to this object.

Parameters:
force - Force vector in world coordinates in mass length time^-2 units.
Since:
v0.2

applyForce

void applyForce(Vector force,
                Vector position)
Apply the given force at the given position to this object.

Parameters:
force - Force vector in world coordinates in mass length time^-2 units.
position - Position of applied force relative to the center of mass in world coordinates in length units.
Since:
v0.2

applyForceLocal

void applyForceLocal(Vector force,
                     Vector position)
Apply the given force at the given position to this object where these vectors are expressed in local coordinates.

Parameters:
force - Force vector in local coordinates in mass length time^-2 units.
position - Position of applied force relative to the center of mass in local coordinates in length units.
Since:
v0.2

getAcceleration

Vector getAcceleration()
Return the acceleration in length time^-2 units.

Since:
v0.2

getAngularAcceleration

Quaternion getAngularAcceleration()
Return the angular acceleration in radians time^-2 units.

Since:
v0.2

getAngularVelocity

Quaternion getAngularVelocity()
Return the angular velocity in radians time^-1 units.

Since:
v0.2

getMass

double getMass()
Return the mass in mass units.

Since:
v0.2

getMassAcceleration

double getMassAcceleration()
Return the mass velocity rate of change in mass time^-2 units.

Since:
v0.3

getMassVelocity

double getMassVelocity()
Return the mass rate of change in mass time^-1 units.

Since:
v0.2

getMomentOfInertia

double[] getMomentOfInertia()
Return the moment of inertia in mass length^2 units.

Since:
v0.2

getVelocity

Vector getVelocity()
Return the velocity in length time^-1 units.

Since:
v0.2

setAcceleration

void setAcceleration(Vector acceleration)
Set the acceleration.

Parameters:
acceleration - Acceleration vector in length time^-2 units.
Since:
v0.2

setAngularAcceleration

void setAngularAcceleration(Quaternion angularAcceleration)
Set the angular acceleration.

Parameters:
angularAcceleration - Angular acceleration in radians time^-2 units.
Since:
v0.2

setAngularVelocity

void setAngularVelocity(Quaternion angularVelocity)
Set the angular velocity.

Parameters:
angularVelocity - Angular velocity in radians time^-1 units.
Since:
v0.2

setMass

void setMass(double mass)
Set the mass.

Parameters:
mass - Mass in mass units.
Since:
v0.2

setMassAcceleration

void setMassAcceleration(double massAcceleration)
Set the mass velocity rate of change.

Parameters:
massAcceleration - Mass velocity rate of change in mass time^-2 units.
Since:
v0.3

setMassVelocity

void setMassVelocity(double massVelocity)
Set the mass rate of change.

Parameters:
massVelocity - Mass velocity in mass time^-1 units.
Since:
v0.2

setMomentOfInertia

void setMomentOfInertia(double[] momentOfInertia)
Set the moment of inertia.

Parameters:
momentOfInertia - Moment of intertia in mass length^2 units.
Since:
v0.2

setVelocity

void setVelocity(Vector velocity)
Set the velocity.

Parameters:
velocity - Velocity vector in length time^-1 units.
Since:
v0.2

toString

String toString()
Return a string representation of this object.

Overrides:
toString in class Object
Since:
v0.2

zeroAcceleration

void zeroAcceleration()
Zero the acceleration.

Since:
v0.3

zeroAngularAcceleration

void zeroAngularAcceleration()
Zero the angular acceleration.

Since:
v0.3

zeroAngularMotion

void zeroAngularMotion()
Zero all angular motion.

Since:
v0.2

zeroMassAcceleration

void zeroMassAcceleration()
Zero the mass acceleration.

Since:
v0.3

zeroMotion

void zeroMotion()
Zero all motion.

Since:
v0.2

zeroTranslationalMotion

void zeroTranslationalMotion()
Zero all translational motion.

Since:
v0.2


Copyright © 2007 Vizzini.org. All Rights Reserved. 2007.12.25.03.00.02