Struct ElasticStressVelocityRecord
pub struct ElasticStressVelocityRecord {
pub velocity_m_s: [f32; 3],
pub material_ref: u32,
pub stress_xx_yy_zz_xy_yz_xz_pa: [f32; 6],
pub displacement_m: [f32; 3],
pub validity_bits: u32,
}Expand description
Mode 0x0001 (elastic_stress_velocity_continuum) 64-byte wire record.
Fields§
§velocity_m_s: [f32; 3]Particle velocity vector in $\text{m}\cdot\text{s}^{-1}$ (0..12).
material_ref: u32Material reference ID (12..16).
stress_xx_yy_zz_xy_yz_xz_pa: [f32; 6]Six-component Cauchy stress [xx, yy, zz, xy, yz, xz] in Pa (16..40).
displacement_m: [f32; 3]Particle displacement vector in metres (40..52).
validity_bits: u32Validity bitmask (52..56).
Implementations§
§impl ElasticStressVelocityRecord
impl ElasticStressVelocityRecord
pub fn validate(&self) -> Result<(), NumericalError>
pub fn validate(&self) -> Result<(), NumericalError>
Validate finiteness, validity bits, and C02-C01 invalid-lane zeroing.
pub fn mechanical_pressure_pa(&self) -> f64
pub fn mechanical_pressure_pa(&self) -> f64
Mechanical pressure $p = -\operatorname{tr}(\boldsymbol{\sigma})/3$ in Pa.
pub fn to_wire_bytes(&self) -> Result<[u8; 64], NumericalError>
pub fn to_wire_bytes(&self) -> Result<[u8; 64], NumericalError>
Encode to exact 64-byte little-endian wire layout.
pub fn from_wire_bytes(
bytes: &[u8],
) -> Result<ElasticStressVelocityRecord, NumericalError>
pub fn from_wire_bytes( bytes: &[u8], ) -> Result<ElasticStressVelocityRecord, NumericalError>
Decode from exact 64-byte little-endian wire layout.
Trait Implementations§
§impl Clone for ElasticStressVelocityRecord
impl Clone for ElasticStressVelocityRecord
§fn clone(&self) -> ElasticStressVelocityRecord
fn clone(&self) -> ElasticStressVelocityRecord
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for ElasticStressVelocityRecord
§impl Debug for ElasticStressVelocityRecord
impl Debug for ElasticStressVelocityRecord
§impl PartialEq for ElasticStressVelocityRecord
impl PartialEq for ElasticStressVelocityRecord
impl StructuralPartialEq for ElasticStressVelocityRecord
Auto Trait Implementations§
impl Freeze for ElasticStressVelocityRecord
impl RefUnwindSafe for ElasticStressVelocityRecord
impl Send for ElasticStressVelocityRecord
impl Sync for ElasticStressVelocityRecord
impl Unpin for ElasticStressVelocityRecord
impl UnsafeUnpin for ElasticStressVelocityRecord
impl UnwindSafe for ElasticStressVelocityRecord
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