Class Inertial
Defined in File Inertial.hpp
Class Documentation
Provides an inertial mechanization capability with stored state and the ability to reset the position, velocity and attitude data in various formats or applying measurement error corrections.
The class currently supports two methods of mechanization, each drawn from different text sources. Additionally, each of these mechanization algorithms has a ‘native’ format of position, velocity and attitude (PVA) data. We commonly use shorthands taken from author names to refer to either algorithms or the common navigation quantity groupings that appear in their books.
The first group describes position as latitude, longitude and altitude in radians, radians and meters with respect to the WGS84 ellipsoid; velocity is in \(\frac{m}{s}\) in the North, East and Down frame; and attitude is represented as the sensor to NED frame DCM. This grouping is associated with the mechanization_standard function and StandardPosVelAtt class. We refer to this set of algorithms/navigation quantities as ‘Titterton’-style, ‘TW’-style, or occasionally ‘LLH NED’, in reference to ‘Strapdown Inertial Navigation Technology, 2nd Edition’ by D.H. Titterton and J.L. Weston.
The second grouping consists of slightly more complicated quantities- a DCM that encodes latitude, longitude and a wander azimuth angle; a separate altitude value; velocity in the ‘n’ frame (which is like an ENU frame that rotates with the wander angle as opposed to being pegged to North/East); and attitude as a DCM that rotates from the sensor frame to the ‘l’ frame (which is related to the ‘n’ frame as the NED frame is related to ENU). This grouping is associated with the mechanization_wander function and WanderPosVelAtt class. We refer to this set of algorithms/navigation quantities as ‘Savage’-style or sometimes ‘wander frame’, after Strapdown Analytics by Paul G. Savage.
It is highly recommended that you interact with this class using formats that ‘match’ the mechanization function supplied through the constructor.
Public Functions
Constructor.
- Parameters
start_pva – Initial PVA of this inertial. Defaults to whatever the StandardPosVelAtt default constructor generates. If starting PVA is unknown at the time of creation, update it via one of the reset functions prior to mechanizing.
mech_options – Collection of options to pass into the mechanization function.
mech_fun – Function used to perform the actual mechanization. Must accept delta velocity( \(\frac{m}{s}\)), delta rotation (rad), delta time, position, velocity and attitude data at beginning of mechanization, and a MechanizationOptions instance.
Constructor.
- Parameters
mech_class – Pointer to a Mechanization instance that will be used to perform the actual mechanization.
start_pva – Initial PVA of this inertial. Defaults to whatever the StandardPosVelAtt default constructor generates. If starting PVA is unknown at the time of creation, update it via one of the reset functions prior to mechanizing.
mech_options – Collection of options to pass into the mechanization function.
Custom deep-copy constructor.
- Parameters
ins – The Inertial to copy. Pointers held by ins are deep-copied.
Copy assignment.
- Parameters
ins – The Inertial to assign. Pointers held by ins are deep-copied when assigned.
- Returns
*thispopulated with copies of ins members.
Default move constructor.
Default move assign.
- Returns
*this.
Reset the inertial solution to a new value.
- Parameters
new_pva – Position, velocity attitude and time data to set this inertial to.
old_pva – Solution one
dtprior tonew_pva. Needed for some higher-order acceleration integration strategies. If not provided defaults to the same asnew_pva.
Reset the inertial solution to a new value.
- Parameters
new_pva – Position, velocity attitude and time data to set this inertial to.
Reset the inertial solution to a new value.
- Parameters
new_pva – Position, velocity attitude and time data to set this inertial to.
Obtains the current inertial solution, which is the result of the last mechanization (or the initial values if at the start).
- Returns
Current solution.
Returns vector of current set of internally-stored gyro bias values, which are used to correct all incoming gyro measurements.
- Returns
Vector3 of biases for each gyro ( \( \frac{rad}{s} \)), in the inertial sensor frame.
Sets internally-stored gyro bias values, which are used to correct all incoming gyro measurements.
- Parameters
gyro_biases – Vector3 of biases for each gyro axis \( (\frac{rad}{s}) \), in the inertial sensor frame such that \( gyro_{meas} = gyro_{true} + gyro_{bias} \) in the absence of other errors.
Returns vector of current set of internally-stored gyro scale factor values, which are used to correct all incoming gyro measurements.
- Returns
Vector3 of scale factors for each gyro axis (unitless), in the inertial sensor frame.
Sets internally-stored gyro scale factor values, which are used to correct all incoming gyro measurements.
- Parameters
gyro_scale_factors – Vector3 of scale factors for each gyro axis (unitless), in the inertial sensor frame such that \( gyro_{meas} = (1 + gyro_{scale})gyro_{true} \) in the absence of other errors.
Returns vector of current set of internally-stored accel bias values, which are used to correct all incoming accel measurements.
- Returns
Vector3 of biases for each accel axis (m/sec^2), in the inertial sensor frame.
Sets internally-stored accel bias values, which are used to correct all incoming accel measurements.
- Parameters
accel_biases – Vector3 of biases for each accel axis in the inertial sensor frame, (m/sec^2), such that \( accel_{meas} = accel_{true} + accel_{bias} \) in the absence of other errors..
Returns vector of current set of internally-stored accel scale factor values, which are used to correct all incoming accel measurements.
- Returns
Vector3 of scale factors for each accel axis, in the inertial sensor frame (unitless).
Sets internally-stored accel scale factor values, which are used to correct all incoming accel measurements.
- Parameters
accel_scale_factors – Vector3 of scale factors for each accel axis in the inertial sensor frame (unitless), such that \( accel_{meas} = (1 + accel_{scale})accel_{true} \) in the absence of other errors.
Supply all inertial sensor error corrections.
- Parameters
errors – Biases, scale factors, etc.used to correct the raw inertial measurements.
Integrate inertial sensor measurements to obtain an updated PVA solution.
- Parameters
time – Time to integrate to; i.e. the end time of the measurement integration period for
accel_measandgyro_meas.accel_meas – Vector3 of accelerometer measurements in the inertial sensor frame.
gyro_meas – Vector3 of gyro measurements in the inertial sensor frame.
aiding_alt_data – AidingAltData container storing the aiding altitude measurement and required parameters for using altitude aiding during mechanization.
Public Members
The cumulative error resulting from aiding the mechanization with an altitude measurement.