pub struct GlobalDiagnostics {Show 15 fields
pub time: f64,
pub total_energy: f64,
pub kinetic_energy: f64,
pub potential_energy: f64,
pub virial_ratio: f64,
pub total_momentum: [f64; 3],
pub total_angular_momentum: [f64; 3],
pub casimir_c2: f64,
pub entropy: f64,
pub mass_in_box: f64,
pub casimir_c2_pre_lomac: Option<f64>,
pub casimir_c2_post_lomac: Option<f64>,
pub near_field_correction_magnitude: Option<f64>,
pub coarse_grained_entropy: Option<f64>,
pub symplecticity_error: Option<f64>,
}Expand description
One row of the global time-series output.
Fields§
§time: f64Simulation time at this diagnostic snapshot.
total_energy: f64Total energy E = T + W (kinetic + potential).
kinetic_energy: f64Kinetic energy T = (1/2) integral f v^2 dx^3 dv^3.
potential_energy: f64Potential energy W = (1/2) integral rho Phi dx^3.
virial_ratio: f64Virial ratio 2T/|W|. Equals 1.0 in virial equilibrium.
total_momentum: [f64; 3][px, py, pz]: total momentum components.
total_angular_momentum: [f64; 3][Lx, Ly, Lz]: total angular momentum components.
casimir_c2: f64Casimir invariant C2 = integral f^2 dx^3 dv^3.
entropy: f64Boltzmann entropy S = -integral f ln(f) dx^3 dv^3.
mass_in_box: f64Total mass in the domain: M = integral f dx^3 dv^3.
casimir_c2_pre_lomac: Option<f64>Casimir C₂ measured before LoMaC projection (None if LoMaC inactive).
casimir_c2_post_lomac: Option<f64>Casimir C₂ measured after LoMaC projection (None if LoMaC inactive).
near_field_correction_magnitude: Option<f64>L2 norm of the near-field correction applied during Poisson solve (None if not applicable).
coarse_grained_entropy: Option<f64>Coarse-grained entropy S_bar = -Sum f_bar ln(f_bar) dV (None if not computed).
symplecticity_error: Option<f64>Per-step symplecticity error estimated from Casimir C₂ drift.
For a symplectic integrator the Casimir invariants are exactly conserved
(absent truncation). This field stores |ΔC₂/C₂| for the most recent step,
or None if no previous step exists yet.
Trait Implementations§
Source§impl Clone for GlobalDiagnostics
impl Clone for GlobalDiagnostics
Source§fn clone(&self) -> GlobalDiagnostics
fn clone(&self) -> GlobalDiagnostics
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for GlobalDiagnostics
impl Debug for GlobalDiagnostics
Source§impl Serialize for GlobalDiagnostics
impl Serialize for GlobalDiagnostics
impl Copy for GlobalDiagnostics
Auto Trait Implementations§
impl Freeze for GlobalDiagnostics
impl RefUnwindSafe for GlobalDiagnostics
impl Send for GlobalDiagnostics
impl Sync for GlobalDiagnostics
impl Unpin for GlobalDiagnostics
impl UnsafeUnpin for GlobalDiagnostics
impl UnwindSafe for GlobalDiagnostics
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> DistributionExt for Twhere
T: ?Sized,
impl<T> DistributionExt for Twhere
T: ?Sized,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more