fr.cnes.sirius.patrius.assembly.models
Class InertiaComputedModel

java.lang.Object
  extended by fr.cnes.sirius.patrius.assembly.models.InertiaComputedModel
All Implemented Interfaces:
IInertiaModel, Cloneable, MassProvider

public class InertiaComputedModel
extends Object
implements IInertiaModel

This class is an inertia model computed from the inertia properties of each parts of an Assembly object.

Note : when using this model within a propagation, it is necessary to feed the additional equations to the propagator. This has to be done prior to any propagation, to allow this model to account mass variations (i.e. due to maneuvers), using the method org.orekit.propagation.numerical.NumericalPropagator#addMassProviderEquation which will register the additional equation and initialize the initial additional state.

Since:
1.2
Version:
$Id: InertiaComputedModel.java 16763 2016-10-10 09:31:17Z bignon $
Author:
Thomas Trapier
See Also:
IInertiaModel
Concurrency :
not thread-safe
Concurrency comment :
the direct use of a not thread-safe Assembly makes this class not thread-safe itself

Field Summary
 
Fields inherited from interface org.orekit.propagation.MassProvider
MASS
 
Constructor Summary
InertiaComputedModel(Assembly assembly)
          Constructor for the computed inertia model.
 
Method Summary
 void addMassDerivative(String partName, double flowRate)
          Add the mass derivate of the given part.
 AdditionalEquations getAdditionalEquation(String name)
          Get the mass equation related to the part.
 List<String> getAllPartsNames()
          Get the list of the name of the parts.
 Matrix3D getInertiaMatrix(Frame frame, AbsoluteDate date)
          Getter for the inertia matrix of the spacecraft, expressed with respect to the MASS CENTER in a given frame.
 Matrix3D getInertiaMatrix(Frame frame, AbsoluteDate date, Vector3D inertiaReferencePoint)
          Getter for the inertia matrix of the spacecraft, once expressed with respect to a point that can be different from the mass center.
 double getMass(String partName)
          Return the mass of the given part.
 Vector3D getMassCenter(Frame frame, AbsoluteDate date)
          Getter for the mass center.
 double getTotalMass()
          Return the mass of the spacecraft.
 double getTotalMass(SpacecraftState state)
          Return the mass of the spacecraft following the order.
 void setMassDerivativeZero(String partName)
          Set mass derivative to zero.
 void updateMass(String partName, double mass)
          Update the mass of the given part.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InertiaComputedModel

public InertiaComputedModel(Assembly assembly)
Constructor for the computed inertia model.

Parameters:
assembly - the considered assembly
Method Detail

getMassCenter

public Vector3D getMassCenter(Frame frame,
                              AbsoluteDate date)
                       throws OrekitException
Getter for the mass center.

Specified by:
getMassCenter in interface IInertiaModel
Parameters:
frame - the expression frame of the mass center position
date - the current date (unused for simple the model)
Returns:
the mass center position vector
Throws:
OrekitException - if a problem occurs during frames transformations

getInertiaMatrix

public Matrix3D getInertiaMatrix(Frame frame,
                                 AbsoluteDate date)
                          throws OrekitException
Getter for the inertia matrix of the spacecraft, expressed with respect to the MASS CENTER in a given frame.

Specified by:
getInertiaMatrix in interface IInertiaModel
Parameters:
frame - the expression frame of the inertia matrix
date - the current date (unused for simple the model)
Returns:
the inertia matrix
Throws:
OrekitException - if a problem occurs during frames transformations

getInertiaMatrix

public Matrix3D getInertiaMatrix(Frame frame,
                                 AbsoluteDate date,
                                 Vector3D inertiaReferencePoint)
                          throws OrekitException
Getter for the inertia matrix of the spacecraft, once expressed with respect to a point that can be different from the mass center. This point must be defined in the reference frame of expression of the matrix.

Specified by:
getInertiaMatrix in interface IInertiaModel
Parameters:
frame - the expression frame of the inertia matrix
date - the current date (unused for simple the model)
inertiaReferencePoint - the point with respect to the inertia matrix is expressed (in the reference frame)
Returns:
the inertia matrix
Throws:
OrekitException - if a problem occurs during frames transformations

addMassDerivative

public void addMassDerivative(String partName,
                              double flowRate)
Add the mass derivate of the given part.

Specified by:
addMassDerivative in interface MassProvider
Parameters:
partName - name of part subject to mass variation
flowRate - flow rate of specified part

setMassDerivativeZero

public void setMassDerivativeZero(String partName)
Set mass derivative to zero.

Specified by:
setMassDerivativeZero in interface MassProvider
Parameters:
partName - name of part whose mass derivative is set to zero

updateMass

public void updateMass(String partName,
                       double mass)
                throws OrekitException
Update the mass of the given part.

Specified by:
updateMass in interface MassProvider
Parameters:
partName - given part
mass - mass of the given part
Throws:
OrekitException - thrown if the mass becomes negative (OrekitMessages.SPACECRAFT_MASS_BECOMES_NEGATIVE)

getMass

public double getMass(String partName)
Return the mass of the given part.

Specified by:
getMass in interface MassProvider
Parameters:
partName - given part
Returns:
mass of part

getTotalMass

public double getTotalMass()
Return the mass of the spacecraft.

Specified by:
getTotalMass in interface MassProvider
Returns:
spacecraft mass

getTotalMass

public double getTotalMass(SpacecraftState state)
Return the mass of the spacecraft following the order.

Specified by:
getTotalMass in interface MassProvider
Parameters:
state - spacecraft state
Returns:
spacecraft mass

getAdditionalEquation

public AdditionalEquations getAdditionalEquation(String name)
Get the mass equation related to the part.

Specified by:
getAdditionalEquation in interface MassProvider
Parameters:
name - part name
Returns:
the associated mass equation

getAllPartsNames

public List<String> getAllPartsNames()
Get the list of the name of the parts.

Specified by:
getAllPartsNames in interface MassProvider
Returns:
the list of the spacecraft parts name.


Copyright © 2016 CNES. All Rights Reserved.