test_hingedRigidBodyDynamics
Conservation and analytical response checks for a spacecraft with two hinged panels.
- test_hingedRigidBodyDynamics.test_hinged_body_conservation(case)[source]
Check energy and momentum histories with gravity, in free flight, and with damping.
Both undamped cases conserve orbital and rotational energy and angular momentum. The damped case conserves orbital energy and both angular momenta, while the loss of rotational energy agrees with the integral of hinge damping power.
- test_hingedRigidBodyDynamics.test_hinged_body_frequency_and_amplitude()[source]
Measure Basilisk hinge periods and amplitudes before and after thrust removal.
For symmetric panel motion the small-angle equations reduce to \(J_{\mathrm{eff}}\ddot\theta + k\theta = -m d F/M\), where \(J_{\mathrm{eff}} = I_{yy} + m d^2 - 2 (m d)^2/M\). This gives the frequency, forced peak deflection, and free amplitude after a known thrust duration independently of either simulated trajectory. All measured peaks and periods come from Basilisk’s hinge output messages. Check every extremum, require enough cycles for each phase duration, and compare the full angle and rate histories so a stalled final partial cycle also fails.
- test_hingedRigidBodyDynamics.test_hinged_body_steady_state_deflection()[source]
Compare both damped hinge angles with the nonlinear static torque balance.
Under constant force \(F\), the system acceleration is \(F/M\) and each hinge satisfies \(k\theta + m d (F/M)\cos\theta = 0\). Check the complete final settling window, including hinge rates, rather than a single endpoint.