Class NEDKinematicsEstimatorTest
java.lang.Object
com.irurueta.navigation.inertial.estimators.NEDKinematicsEstimatorTest
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleprivate static final doubleThreshold used by the navigator of the round-trip test to accept the navigated body-to-NED matrix as a rotation.private static final double[]Angular rate (x, y, z) navigated in the round-trip test, expressed in radians per second (rad/s).private static final doubleTolerance of the navigator round-trip test for tau = 1 s, for both specific force (m/s^2) and angular rate (rad/s).private static final doubleLongest time interval of the navigator round-trip test, expressed in seconds (s).private static final double[]Old body attitude (roll, pitch, yaw) of the navigator round-trip test, expressed in degrees.private static final double[]Old NED velocity (north, east, down) of the navigator round-trip test, expressed in meters per second (m/s).private static final doubleTolerance of the navigator round-trip test for tau = 0.1 s, for both specific force (m/s^2) and angular rate (rad/s).private static final doubleShortest time interval of the navigator round-trip test, expressed in seconds (s).private static final double[]Specific force (x, y, z) navigated in the round-trip test, expressed in meters per squared second (m/s^2).private static final doubleprivate static final doubleprivate static final int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static voidassertNavigatorRoundTrip(double timeInterval, double absoluteError) Navigates one epoch of the given duration from the fixed old frame of the round-trip test and asserts that the kinematics estimated back from the old and navigated frames, using the old latitude and height, match the navigated ones.private static com.irurueta.navigation.frames.NEDFramecreateNewNedFrame(com.irurueta.navigation.frames.NEDFrame oldFrame) private static com.irurueta.navigation.frames.NEDFrameprivate static BodyKinematicsestimateKinematics(double timeInterval, com.irurueta.navigation.frames.CoordinateTransformation c, com.irurueta.navigation.frames.CoordinateTransformation oldC, double vn, double ve, double vd, double oldVn, double oldVe, double oldVd, double latitude, double height, double oldLatitude, double oldHeight) (package private) void(package private) void(package private) void(package private) void(package private) void(package private) void(package private) void(package private) void(package private) void(package private) voidNavigates one epoch withNEDInertialNavigator(Groves'Nav_equations_NED) from a fixed, rotating old frame and checks thatNEDKinematicsEstimator(Groves'Kinematics_NED), fed with the old latitude and height, recovers the body kinematics that were navigated, for time intervals of 0.1 s and 1 s.
-
Field Details
-
TIME_INTERVAL_SECONDS
private static final double TIME_INTERVAL_SECONDS- See Also:
-
LATITUDE_DEGREES
private static final double LATITUDE_DEGREES- See Also:
-
LONGITUDE_DEGREES
private static final double LONGITUDE_DEGREES- See Also:
-
HEIGHT
private static final double HEIGHT- See Also:
-
MIN_ANGLE_DEGREES
private static final double MIN_ANGLE_DEGREES- See Also:
-
MAX_ANGLE_DEGREES
private static final double MAX_ANGLE_DEGREES- See Also:
-
MIN_VELOCITY_VALUE
private static final double MIN_VELOCITY_VALUE- See Also:
-
MAX_VELOCITY_VALUE
private static final double MAX_VELOCITY_VALUE- See Also:
-
MIN_ANGLE_VARIATION_DEGREES
private static final double MIN_ANGLE_VARIATION_DEGREES- See Also:
-
MAX_ANGLE_VARIATION_DEGREES
private static final double MAX_ANGLE_VARIATION_DEGREES- See Also:
-
MIN_POSITION_VARIATION_DEGREES
private static final double MIN_POSITION_VARIATION_DEGREES- See Also:
-
MAX_POSITION_VARIATION_DEGREES
private static final double MAX_POSITION_VARIATION_DEGREES- See Also:
-
MIN_HEIGHT_VARIATION
private static final double MIN_HEIGHT_VARIATION- See Also:
-
MAX_HEIGHT_VARIATION
private static final double MAX_HEIGHT_VARIATION- See Also:
-
MIN_VELOCITY_VARIATION
private static final double MIN_VELOCITY_VARIATION- See Also:
-
MAX_VELOCITY_VARIATION
private static final double MAX_VELOCITY_VARIATION- See Also:
-
SCALING_THRESHOLD
private static final double SCALING_THRESHOLD- See Also:
-
ALPHA_THRESHOLD
private static final double ALPHA_THRESHOLD- See Also:
-
ABSOLUTE_ERROR
private static final double ABSOLUTE_ERROR- See Also:
-
LARGE_ABSOLUTE_ERROR
private static final double LARGE_ABSOLUTE_ERROR- See Also:
-
TIMES
private static final int TIMES- See Also:
-
ROUND_TRIP_SHORT_TIME_INTERVAL_SECONDS
private static final double ROUND_TRIP_SHORT_TIME_INTERVAL_SECONDSShortest time interval of the navigator round-trip test, expressed in seconds (s).- See Also:
-
ROUND_TRIP_LONG_TIME_INTERVAL_SECONDS
private static final double ROUND_TRIP_LONG_TIME_INTERVAL_SECONDSLongest time interval of the navigator round-trip test, expressed in seconds (s).- See Also:
-
ROUND_TRIP_OLD_VELOCITY
private static final double[] ROUND_TRIP_OLD_VELOCITYOld NED velocity (north, east, down) of the navigator round-trip test, expressed in meters per second (m/s). -
ROUND_TRIP_OLD_ATTITUDE_DEGREES
private static final double[] ROUND_TRIP_OLD_ATTITUDE_DEGREESOld body attitude (roll, pitch, yaw) of the navigator round-trip test, expressed in degrees. -
ROUND_TRIP_SPECIFIC_FORCE
private static final double[] ROUND_TRIP_SPECIFIC_FORCESpecific force (x, y, z) navigated in the round-trip test, expressed in meters per squared second (m/s^2). -
ROUND_TRIP_ANGULAR_RATE
private static final double[] ROUND_TRIP_ANGULAR_RATEAngular rate (x, y, z) navigated in the round-trip test, expressed in radians per second (rad/s). -
ROUND_TRIP_ACCURACY_THRESHOLD
private static final double ROUND_TRIP_ACCURACY_THRESHOLDThreshold used by the navigator of the round-trip test to accept the navigated body-to-NED matrix as a rotation. Nav_equations_NED updates attitude with the first-order factor (I - tau * skew(omega_in^n)) of eq. (5.77), which is not orthonormal: for these inputs the measured Frobenius norm of (C' * C - I) is 8.4e-11 for tau = 0.1 s and 8.6e-9 for tau = 1 s (it grows as (omega_in * tau)^2), so the default threshold of 1e-11 rejects both and the smallest passing power of ten is 1e-8 for tau = 1 s. 1e-7 leaves one order of magnitude of margin over that.- See Also:
-
ROUND_TRIP_SHORT_INTERVAL_ABSOLUTE_ERROR
private static final double ROUND_TRIP_SHORT_INTERVAL_ABSOLUTE_ERRORTolerance of the navigator round-trip test for tau = 0.1 s, for both specific force (m/s^2) and angular rate (rad/s). Derived from the measured round-trip error of the current (correct) implementation: the largest component error is 4.0e-12 m/s^2 in specific force and 1.9e-11 rad/s in angular rate, caused by the first-order attitude terms of eq. (5.46)-(5.54) and (5.77). 1e-9 is about 50 times the largest measured error, and still 280 times below the 2.8e-7 m/s^2 gravity change produced by using the new height (0.09 m away) instead of the old one.- See Also:
-
ROUND_TRIP_LONG_INTERVAL_ABSOLUTE_ERROR
private static final double ROUND_TRIP_LONG_INTERVAL_ABSOLUTE_ERRORTolerance of the navigator round-trip test for tau = 1 s, for both specific force (m/s^2) and angular rate (rad/s). Derived from the measured round-trip error of the current (correct) implementation: the largest component error is 6.9e-9 m/s^2 in specific force and 1.9e-9 rad/s in angular rate (the first-order error grows as tau^2 with respect to the 0.1 s case). 1e-7 is about 15 times the largest measured error, and still 10 times below the 1.0e-6 m/s^2 gravity change produced by using the new height (0.32 m away) instead of the old one.- See Also:
-
-
Constructor Details
-
NEDKinematicsEstimatorTest
NEDKinematicsEstimatorTest()
-
-
Method Details
-
testEstimate
@Test void testEstimate() throws com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeException, com.irurueta.geometry.InvalidRotationMatrixException- Throws:
com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeExceptioncom.irurueta.geometry.InvalidRotationMatrixException
-
testEstimateAndReturnNew
@Test void testEstimateAndReturnNew() throws com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeException, com.irurueta.geometry.InvalidRotationMatrixException- Throws:
com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeExceptioncom.irurueta.geometry.InvalidRotationMatrixException
-
testEstimateKinematics
@Test void testEstimateKinematics() throws com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeException, com.irurueta.geometry.InvalidRotationMatrixException, com.irurueta.algebra.WrongSizeException, com.irurueta.algebra.RankDeficientMatrixException, com.irurueta.algebra.DecomposerException- Throws:
com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeExceptioncom.irurueta.geometry.InvalidRotationMatrixExceptioncom.irurueta.algebra.WrongSizeExceptioncom.irurueta.algebra.RankDeficientMatrixExceptioncom.irurueta.algebra.DecomposerException
-
testEstimateKinematicsAndReturnNew
@Test void testEstimateKinematicsAndReturnNew() throws com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeException, com.irurueta.geometry.InvalidRotationMatrixException, com.irurueta.algebra.WrongSizeException, com.irurueta.algebra.RankDeficientMatrixException, com.irurueta.algebra.DecomposerException- Throws:
com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeExceptioncom.irurueta.geometry.InvalidRotationMatrixExceptioncom.irurueta.algebra.WrongSizeExceptioncom.irurueta.algebra.RankDeficientMatrixExceptioncom.irurueta.algebra.DecomposerException
-
testEstimateKinematicsWhenNegativeIntervalThrowsIllegalArgumentException
@Test void testEstimateKinematicsWhenNegativeIntervalThrowsIllegalArgumentException() throws com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeException, com.irurueta.geometry.InvalidRotationMatrixException- Throws:
com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeExceptioncom.irurueta.geometry.InvalidRotationMatrixException
-
testEstimateKinematicsWhenInvalidCoordinateTransformationThrowsIllegalArgumentException
@Test void testEstimateKinematicsWhenInvalidCoordinateTransformationThrowsIllegalArgumentException() throws com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeException, com.irurueta.geometry.InvalidRotationMatrixException- Throws:
com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeExceptioncom.irurueta.geometry.InvalidRotationMatrixException
-
testEstimateKinematicsWhenInvalidOldCoordinateTransformationThrowsIllegalArgumentException
@Test void testEstimateKinematicsWhenInvalidOldCoordinateTransformationThrowsIllegalArgumentException() throws com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeException, com.irurueta.geometry.InvalidRotationMatrixException- Throws:
com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeExceptioncom.irurueta.geometry.InvalidRotationMatrixException
-
testEstimateKinematicsWhenZeroTimeIntervalReturnsZeroValues
@Test void testEstimateKinematicsWhenZeroTimeIntervalReturnsZeroValues() throws com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeException, com.irurueta.geometry.InvalidRotationMatrixException, com.irurueta.algebra.WrongSizeException, com.irurueta.algebra.RankDeficientMatrixException, com.irurueta.algebra.DecomposerException- Throws:
com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeExceptioncom.irurueta.geometry.InvalidRotationMatrixExceptioncom.irurueta.algebra.WrongSizeExceptioncom.irurueta.algebra.RankDeficientMatrixExceptioncom.irurueta.algebra.DecomposerException
-
testCompareKinematics
@Test void testCompareKinematics() throws com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeException, com.irurueta.geometry.InvalidRotationMatrixException- Throws:
com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeExceptioncom.irurueta.geometry.InvalidRotationMatrixException
-
createOldNedFrame
private static com.irurueta.navigation.frames.NEDFrame createOldNedFrame() throws com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeException, com.irurueta.geometry.InvalidRotationMatrixException- Throws:
com.irurueta.navigation.frames.InvalidSourceAndDestinationFrameTypeExceptioncom.irurueta.geometry.InvalidRotationMatrixException
-