VR-Link API Documentation for DIS
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes

Instances of DtExponentialSmoother are used to provide approximated position and orientation information for entities. More...

+ Inheritance diagram for DtExponentialSmoother:
+ Collaboration diagram for DtExponentialSmoother:

Public Member Functions

 DtExponentialSmoother ()
 constructor More...
 
virtual ~DtExponentialSmoother ()
 destructor More...
 
 DtExponentialSmoother (const DtExponentialSmoother &orig)
 copy constructor More...
 
DtExponentialSmootheroperator= (const DtExponentialSmoother &orig)
 assignment operator More...
 
virtual DtApproximatorclone () const
 Create a copy of this object. More...
 
virtual void setAll (const DtVector &loc, const DtVector32 &vel, const DtTaitBryan &ori, const DtVector32 &acc, const DtVector32 &rotVel, DtTime t)
 Coherently set all DR parameters, thus avoiding DR computations associated with a partial set. More...
 
virtual void setLocation (const DtVector &loc, DtTime t)
 Set absolute location. More...
 
virtual const DtVectorapproxLocation (DtTime t) const
 Get the approximated location at the specified time. More...
 
virtual void setVelocity (const DtVector32 &vel, DtTime t)
 Set absolute velocity. More...
 
virtual const DtVector32approxVelocity (DtTime t) const
 Get the approximated velocity at the specified time. More...
 
virtual void setOrientation (const DtTaitBryan &ori, DtTime t)
 Set absolute orientation. More...
 
virtual const DtTaitBryanapproxEuler (DtTime t) const
 Get approximated orientation (Euler angles) at the specified time. More...
 
virtual void setAcceleration (const DtVector32 &acc, DtTime t)
 Set/Get absolute acceleration. More...
 
virtual const DtVector32acceleration (DtTime t) const
 
virtual void setRotationalVelocity (const DtVector32 &vel, DtTime t)
 Set/Get absolute rotational velocity. More...
 
virtual const DtVector32rotationalVelocity (DtTime t) const
 
virtual const DtDcmapproxBodyToGeoc (DtTime t) const
 Get the approximated data body to geocentric coordinate matrix. More...
 
virtual void setSmoothEnable (bool on)
 Set/Get the individual smoothing switch. More...
 
virtual bool smoothEnable () const
 
virtual void setSmoothPeriod (DtTime smoothPeriod)
 Set/Get smoothing period - the amount of time over which smoothing takes place. More...
 
virtual DtTime smoothPeriod () const
 
virtual void reset ()
 resets the smoothers. More...
 
virtual void setFrozen (bool frozen)
 Set/Get whether the dead-reckoner is frozen. More...
 
- Public Member Functions inherited from DtTrigonometricSmoother
 DtTrigonometricSmoother ()
 Default constructor. More...
 
virtual ~DtTrigonometricSmoother ()
 Destructor. More...
 
 DtTrigonometricSmoother (const DtTrigonometricSmoother &src)
 Copy constructor. More...
 
DtTrigonometricSmootheroperator= (const DtTrigonometricSmoother &src)
 Assignment operator. More...
 
bool operator== (const DtTrigonometricSmoother &orig) const
 equality Operator. More...
 
const DtVector32approxUnsmoothedVelocity (DtTime curTime) const
 Get the approximated velocity at the specified time without taking into account smoothing. More...
 
virtual void setOriSmoothPeriod (DtTime t)
 Set/Get orientation smoothing period - the amount of time, in seconds, over which orientation smoothing takes place. More...
 
virtual DtTime oriSmoothPeriod () const
 
- Public Member Functions inherited from DtDeadReckoner
 DtDeadReckoner ()
 Default CTOR. More...
 
 DtDeadReckoner (const DtDeadReckoner &orig)
 Copy CTOR. More...
 
virtual ~DtDeadReckoner ()
 Virtual DTOR. More...
 
DtDeadReckoneroperator= (const DtDeadReckoner &orig)
 Assignment Operator. More...
 
bool operator== (const DtDeadReckoner &orig) const
 equality Operator. More...
 
virtual const DtVectordeadReckonedLocation (DtTime curTime) const
 Get the dead-reckoned location at the specified time. More...
 
virtual const DtVector32deadReckonedVelocity (DtTime curTime) const
 Get the dead-reckoned velocity at the specified time. More...
 
virtual const DtTaitBryandeadReckonedEuler (DtTime curTime) const
 Get dead-reckoned orientation (Euler angles) at the specified time. More...
 
virtual const DtTimelocationUpdateTime () const
 Get the last update time of the absolute location. More...
 
virtual const DtTimevelocityUpdateTime () const
 Get the last update time of the absolute velocity. More...
 
virtual const DtTimeorientationUpdateTime () const
 Get the last update time of the absolute orientation. More...
 
virtual const DtDcmdeadReckonedBodyToGeoc (DtTime curTime) const
 Get the dead-reckoned body to geocentric coordinate matrix. More...
 
virtual void setAlgorithm (DtDeadReckonTypes alg)
 Set/Get the dead reckoning algorithm used for generating the approximated values from the absolute values. More...
 
virtual DtDeadReckonTypes algorithm () const
 
virtual int isRotational () const
 Returns 1 if the dead reckoning algorithm is a rotational one, 0 otherwise. More...
 
virtual void deadReckonPosition (DtTime dt, const DtVector &oldPos, const DtVector32 &oldVel, const DtVector32 &oldAccel, DtVector32 &newVel, DtVector &newPos) const
 Calculate the dead reckon position information based on the algorithm type. More...
 
virtual void deadReckonOrientation (DtTime dt, const DtDcm &old_b2w, const DtDirectedRotRate &drr, DtDcm &new_b2w) const
 Calculate the orientation matrix based on the algorithm type. More...
 
- Public Member Functions inherited from DtApproximator
virtual ~DtApproximator ()
 Virtual DTOR. More...
 
DtApproximatoroperator= (const DtApproximator &orig)
 Assignment operator. More...
 
virtual bool isFrozen () const
 

Static Public Member Functions

static void setDfltSmoothPeriod (DtTime smoothPeriod)
 Set/Get the default smoothing period. More...
 
static DtTime dfltSmoothPeriod ()
 
static void setMasterSmoothEnable (bool onOff)
 Set/Get the value of the "master" smoothing-enabled switch. More...
 
static bool masterSmoothEnable ()
 
- Static Public Member Functions inherited from DtTrigonometricSmoother
static void setDfltSmoothPeriod (DtTime smoothPeriod)
 Set/Get the default smoothing period. More...
 
static DtTime dfltSmoothPeriod ()
 
static void setMasterSmoothEnable (bool onOff)
 Set/Get the value of the "master" smoothing-enabled switch. More...
 
static bool masterSmoothEnable ()
 
static void rotAngleAndAxisFromRotMatrix (DtVector &n, double &phi, const DtDcm &m)
 
static void rotMatrixFromRotRatesAndTime (DtDcm &m, DtDcm &o, DtVector &n, double &w, const DtVector32 &r, double t)
 
- Static Public Member Functions inherited from DtDeadReckoner
static int isRotational (DtDeadReckonTypes algorithm)
 Returns 1 if the dead reckoning algorithm is a rotational one, 0 otherwise. More...
 
static void deadReckonPosition (DtTime dt, DtDeadReckonTypes algorithm, const DtVector &oldPos, const DtVector32 &oldVel, const DtVector32 &oldAccel, DtVector32 &newVel, DtVector &newPos)
 Calculate the dead reckon position information. More...
 
static void deadReckonOrientation (DtTime dt, DtDeadReckonTypes algorithm, const DtDcm &old_b2w, const DtDirectedRotRate &drr, DtDcm &new_b2w)
 Calculate the orientation matrix. More...
 

Protected Member Functions

virtual void feedSmoothing ()
 Provide inputs to the actual smoothing algorithm. More...
 
DtExponentialSmootherself () const
 Get rid of const-ness on the "this" pointer in order to access non-const functions from const member functions (such as simple accessors). More...
 
- Protected Member Functions inherited from DtTrigonometricSmoother
virtual void resetPosSmoother (DtTime t)
 
virtual void resetOriSmoother (DtTime t)
 
virtual const DtVectorsmoothPosition (DtTime t)
 
virtual const DtVector32smoothVelocity (DtTime t)
 
virtual const DtDcmsmoothBodyToGeoc (DtTime t)
 
virtual void initSmootherParams ()
 
virtual void initSmoothOriParams ()
 
DtTrigonometricSmootherself () const
 Get rid of constness on the "this" pointer in order to access non-const functions from const member functions (such as simple accessors). More...
 
- Protected Member Functions inherited from DtDeadReckoner
virtual void deadReckonLoc (DtTime curTime) const
 If the last dead reckoned position is not valid for the specified time, recalculate it and update the time at which this value is valid. More...
 
virtual void deadReckonBodyToGeoc (DtTime curTime) const
 If the last dead reckoned body to geocentric coordinate matrix is not valid for the specified time, recalculate it and update the time at which this value is valid. More...
 
virtual void deadReckonEuler (DtTime curTime) const
 If the last dead reckoned orientation (Euler angles) is not valid for the specified time, recalculate it and update the time at which this value is valid. More...
 
- Protected Member Functions inherited from DtApproximator
 DtApproximator ()
 Default CTOR. More...
 
 DtApproximator (const DtApproximator &orig)
 Copy CTOR. More...
 

Protected Attributes

DtSmoothPosWithDr mySpos
 
DtSmoothOriWithDr mySorient
 
DtTaitBryan myApproxEuler
 
DtVector32 myRealVelocity
 
- Protected Attributes inherited from DtTrigonometricSmoother
DtVector myLastDrPos
 
DtVector32 myLastDrVel
 
DtVector mySmoothPos
 
DtVector32 mySmoothVel
 
DtVector myX1
 
DtVector myV1
 
DtVector myA1
 
DtVector myA2
 
DtTime myTau
 
DtTime myTau2
 
DtTime myTau2Inv
 
DtTime myTauSq4
 
DtTime myTauSq4Inv
 
DtTime myLastSetTime
 
DtTime myPostSmoothTime
 
DtTime myHalfSmoothTime
 
DtTime myOriTau
 
DtTime myLastSetOriTime
 
DtTime myPostSmoothOriTime
 
DtTime myLastSmoothOriTime
 
DtTime myLastSmoothTbTime
 
double mySmoothRotRate
 
DtDcm myLastDrOri
 
DtDcm mySmoothOri
 
DtDcm mySmoothOmegaMx
 
DtVector mySmoothRotAxis
 
DtTaitBryan mySmoothTb
 
bool myIsDirty
 
bool myOriIsDirty
 
bool myTbIsDirty
 
bool mySmoothEnable
 
- Protected Attributes inherited from DtDeadReckoner
DtVector myLocAtTimeOfValidity
 
DtVector32 myVelAtTimeOfValidity
 
DtTime mySimTimePosDataValid
 
DtDcm myBodyToGeocAtTimeOfValidity
 
DtTime mySimTimeOrientDataValid
 
DtVector myDRLoc
 
DtVector32 myDRVel
 
DtTime myDRPosTime
 
DtDcm myDRBodyToGeoc
 
DtTime myDRBodyToGeocTime
 
DtTaitBryan myDREuler
 
DtTime myDREulerTime
 
DtDirectedRotRate myDirectedRotRate
 
DtDeadReckonTypes myAlgorithm
 
DtVector32 myAccel
 
DtBodyRates myRotVel
 
- Protected Attributes inherited from DtApproximator
bool myFrozenFlag
 

Additional Inherited Members

- Static Protected Attributes inherited from DtTrigonometricSmoother
static double theTimeTolerance
 
static bool theMasterSmoothEnable
 
static DtTime theDfltSmoothPeriod
 

Detailed Description

Instances of DtExponentialSmoother are used to provide approximated position and orientation information for entities.

Position and orientation information is approximated over time from the last set absolute (non-approximated) information. When a new position is set, the current position moves smoothly to reflect the new information, rather than jumping to the new absolute position.

This smoother uses an exponential line to approach the new absolute position. Under most circumstances, this is the best smoother currently provided. For a different approach of smoothing, one could try the DtTrigonometricSmoother.

Constructor & Destructor Documentation

DtExponentialSmoother::DtExponentialSmoother ( )

constructor

virtual DtExponentialSmoother::~DtExponentialSmoother ( )
virtual

destructor

DtExponentialSmoother::DtExponentialSmoother ( const DtExponentialSmoother orig)

copy constructor

Member Function Documentation

virtual const DtVector32& DtExponentialSmoother::acceleration ( DtTime  t) const
virtual

Reimplemented from DtTrigonometricSmoother.

virtual const DtDcm& DtExponentialSmoother::approxBodyToGeoc ( DtTime  t) const
virtual

Get the approximated data body to geocentric coordinate matrix.

Reimplemented from DtTrigonometricSmoother.

virtual const DtTaitBryan& DtExponentialSmoother::approxEuler ( DtTime  t) const
virtual

Get approximated orientation (Euler angles) at the specified time.

Reimplemented from DtTrigonometricSmoother.

virtual const DtVector& DtExponentialSmoother::approxLocation ( DtTime  t) const
virtual

Get the approximated location at the specified time.

Reimplemented from DtTrigonometricSmoother.

virtual const DtVector32& DtExponentialSmoother::approxVelocity ( DtTime  t) const
virtual

Get the approximated velocity at the specified time.

Reimplemented from DtTrigonometricSmoother.

virtual DtApproximator* DtExponentialSmoother::clone ( ) const
virtual

Create a copy of this object.

Memory is allocated and it is the responsibility of the caller to free the memory via delete.

Reimplemented from DtTrigonometricSmoother.

static DtTime DtExponentialSmoother::dfltSmoothPeriod ( )
static
virtual void DtExponentialSmoother::feedSmoothing ( )
protectedvirtual

Provide inputs to the actual smoothing algorithm.

static bool DtExponentialSmoother::masterSmoothEnable ( )
static
DtExponentialSmoother& DtExponentialSmoother::operator= ( const DtExponentialSmoother orig)

assignment operator

virtual void DtExponentialSmoother::reset ( )
virtual

resets the smoothers.

This does not change the last updated position or the smoothing period it just clears the smoothing parameters. Calling this function while an entity is being smoothed to a new position may result in a very small jump

virtual const DtVector32& DtExponentialSmoother::rotationalVelocity ( DtTime  t) const
virtual

Reimplemented from DtTrigonometricSmoother.

DtExponentialSmoother * DtExponentialSmoother::self ( ) const
inlineprotected

Get rid of const-ness on the "this" pointer in order to access non-const functions from const member functions (such as simple accessors).

This should be used sparingly since it bypasses the const protection. Note: This is essentially like an operator and is non-virtual, since can't override based on return type. Allows derived classes to also define this member.

virtual void DtExponentialSmoother::setAcceleration ( const DtVector32 acc,
DtTime  t 
)
virtual

Set/Get absolute acceleration.

Reimplemented from DtTrigonometricSmoother.

virtual void DtExponentialSmoother::setAll ( const DtVector loc,
const DtVector32 vel,
const DtTaitBryan ori,
const DtVector32 acc,
const DtVector32 rotVel,
DtTime  t 
)
virtual

Coherently set all DR parameters, thus avoiding DR computations associated with a partial set.

Reimplemented from DtTrigonometricSmoother.

static void DtExponentialSmoother::setDfltSmoothPeriod ( DtTime  smoothPeriod)
static

Set/Get the default smoothing period.

virtual void DtExponentialSmoother::setFrozen ( bool  frozen)
virtual

Set/Get whether the dead-reckoner is frozen.

Freezing the dead-reckoner prevents values from being dead-reckoned.

Reimplemented from DtApproximator.

virtual void DtExponentialSmoother::setLocation ( const DtVector loc,
DtTime  t 
)
virtual

Set absolute location.

Reimplemented from DtTrigonometricSmoother.

static void DtExponentialSmoother::setMasterSmoothEnable ( bool  onOff)
static

Set/Get the value of the "master" smoothing-enabled switch.

Master smoothing switch defaults to on.

virtual void DtExponentialSmoother::setOrientation ( const DtTaitBryan ori,
DtTime  t 
)
virtual

Set absolute orientation.

Reimplemented from DtTrigonometricSmoother.

virtual void DtExponentialSmoother::setRotationalVelocity ( const DtVector32 vel,
DtTime  t 
)
virtual

Set/Get absolute rotational velocity.

Reimplemented from DtTrigonometricSmoother.

virtual void DtExponentialSmoother::setSmoothEnable ( bool  on)
virtual

Set/Get the individual smoothing switch.

In order for smoothing to be enabled, the "master" smoothing-enabled switch must be on, AND the individual smoothing switch (accessed through these functions), must be on. Individual smoothing switch defaults to on.

Reimplemented from DtTrigonometricSmoother.

virtual void DtExponentialSmoother::setSmoothPeriod ( DtTime  smoothPeriod)
virtual

Set/Get smoothing period - the amount of time over which smoothing takes place.

Pass a value of -1 to indicate use of the default smoothing period.

Reimplemented from DtTrigonometricSmoother.

virtual void DtExponentialSmoother::setVelocity ( const DtVector32 vel,
DtTime  t 
)
virtual

Set absolute velocity.

Reimplemented from DtTrigonometricSmoother.

virtual bool DtExponentialSmoother::smoothEnable ( ) const
virtual

Reimplemented from DtTrigonometricSmoother.

virtual DtTime DtExponentialSmoother::smoothPeriod ( ) const
virtual

Reimplemented from DtTrigonometricSmoother.

Member Data Documentation

DtTaitBryan DtExponentialSmoother::myApproxEuler
protected
DtVector32 DtExponentialSmoother::myRealVelocity
protected
DtSmoothOriWithDr DtExponentialSmoother::mySorient
protected
DtSmoothPosWithDr DtExponentialSmoother::mySpos
protected

The documentation for this class was generated from the following file:

Document ID: Generated on Wed Mar 27 02:04:30 EDT 2024 from SVN revision 264570
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)