pub struct OrbitalState {
pub position: [f64; 2],
pub velocity: [f64; 2],
pub time: f64,
pub energy: f64,
pub angular_momentum: f64,
pub step_count: u64,
}Expand description
Orbital state snapshot.
This is THE state that gets compared for TUI/WASM parity.
It MUST be PartialEq for the probar tests.
Fields§
§position: [f64; 2]Position vector (m).
velocity: [f64; 2]Velocity vector (m/s).
time: f64Current simulation time (s).
energy: f64Specific orbital energy (J/kg).
angular_momentum: f64Angular momentum magnitude (m²/s).
step_count: u64Step count.
Implementations§
Source§impl OrbitalState
impl OrbitalState
Sourcepub fn compute_hash(&self) -> u64
pub fn compute_hash(&self) -> u64
Compute hash for quick comparison.
Trait Implementations§
Source§impl Clone for OrbitalState
impl Clone for OrbitalState
Source§fn clone(&self) -> OrbitalState
fn clone(&self) -> OrbitalState
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for OrbitalState
impl Debug for OrbitalState
Source§impl<'de> Deserialize<'de> for OrbitalState
impl<'de> Deserialize<'de> for OrbitalState
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for OrbitalState
impl PartialEq for OrbitalState
Source§impl Serialize for OrbitalState
impl Serialize for OrbitalState
impl StructuralPartialEq for OrbitalState
Auto Trait Implementations§
impl Freeze for OrbitalState
impl RefUnwindSafe for OrbitalState
impl Send for OrbitalState
impl Sync for OrbitalState
impl Unpin for OrbitalState
impl UnsafeUnpin for OrbitalState
impl UnwindSafe for OrbitalState
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more