pub struct Rail {
pub length_m: f64,
pub azimuth_rad: f64,
pub elevation_rad: f64,
pub roll_rad: f64,
pub friction_coefficient: f64,
}Expand description
A launch rail.
Fields§
§length_m: f64The rail’s length from its foot, where the rocket’s aft end starts, to its top, m.
azimuth_rad: f64The heading of the rail, clockwise from true north, rad (frames::LaunchAngles).
elevation_rad: f64The rail’s angle above the horizon, rad (π/2 is vertical).
roll_rad: f64The rocket’s roll on the rail: the turn of x_B about the rail axis, rad.
friction_coefficient: f64The Coulomb friction coefficient between the guides and the rail. There is no default value in the sources; zero means a frictionless rail.
Implementations§
Source§impl Rail
impl Rail
Sourcepub fn validate(&self) -> Result<(), SimError>
pub fn validate(&self) -> Result<(), SimError>
Checks the length, angles and friction.
§Errors
SimError::Domain for a non-positive length, a negative friction coefficient, an
elevation outside (0, π/2] or a non-finite angle.
Sourcepub fn direction_enu(&self) -> DVec3
pub fn direction_enu(&self) -> DVec3
The unit vector along the rail, up, in the launch frame.
Trait Implementations§
impl Copy for Rail
Source§impl<'de> Deserialize<'de> for Rail
impl<'de> Deserialize<'de> for Rail
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
impl StructuralPartialEq for Rail
Auto Trait Implementations§
impl Freeze for Rail
impl RefUnwindSafe for Rail
impl Send for Rail
impl Sync for Rail
impl Unpin for Rail
impl UnsafeUnpin for Rail
impl UnwindSafe for Rail
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