test_gravityRotatingPlanet
Tests that the gravity effector keeps the extrapolated planet orientation a rotation.
- test_gravityRotatingPlanet.test_extrapolated_orientation_is_orthonormal(stepSeconds)[source]
Verify the extrapolated planet orientation remains a proper rotation matrix.
A first-order update of the matrix elements loses orthonormality by about
(omega * dt)^2 / 2, which is a few percent after an hour of extrapolation.
- test_gravityRotatingPlanet.test_point_mass_orbit_is_independent_of_planet_spin(stepSeconds)[source]
Verify a point-mass orbit does not depend on the planet orientation.
The point-mass field is spherically symmetric, so a spinning planet must give the same trajectory as a non-spinning one. A non-orthonormal orientation scales the evaluated field and breaks this.
- test_gravityRotatingPlanet.test_stored_orientation_and_rate_are_consistent(stepSeconds)[source]
Verify the stored planet orientation and rate are [PN] and [PN_dot] of the same epoch.
The planet spins about the inertial z axis and its message is written once at t = 0, so at the final time the orientation is a rotation by
OMEGA_PLANET * SIM_TIMEand the rate satisfiesdcm_dot = -dcm [omega x]with the inertial angular velocityomega.