Skip to main content

ElevatedPositionTable

Struct ElevatedPositionTable 

Source
pub struct ElevatedPositionTable { /* private fields */ }
Expand description

Certified positions of an elevated or banked curve over an intrinsic or a chain plan, in plan distance, read in any order: the plan from an IntrinsicPositionTable or a ChainPositionTable, the height and the pivot in closed form.

Implementations§

Source§

impl ElevatedPositionTable

Source

pub fn new(curve: &Curve3, error: Scalar, end: Scalar) -> Option<Self>

The table of curve over [0, end], its plan points within about error (IntrinsicPositionTable::new2, ChainPositionTable::new). Some only for an elevated or banked curve whose plan is an intrinsic curve or a chain a ChainPositionTable covers, whose profile is closed form (no intrinsic profile), and for a banked curve whose cant and pivot laws are well formed with no held-rail piece in the cant; None otherwise, for an error or an end that is not finite and positive, or an end past the plan’s length.

Source

pub fn point3(&self, d: Scalar) -> Option<(Point3, Scalar)>

The point at plan distance d and a certified bound on its distance from the exact point: the plan table’s error at d, with the closed-form height (and pivot) exact. None outside [0, end] or where the profile or the pivot has no value.

Source

pub fn point3_on(&self, d: Scalar, side: SeamSide) -> Option<(Point3, Scalar)>

Self::point3 on side of a join of a chain plan (the side makes no difference over an intrinsic plan, or off a join).

Source

pub fn jet3_on(&self, d: Scalar, side: SeamSide) -> Option<(Point3, Vec3, Vec3)>

The point, the derivative and the second derivative at plan distance d on side of a join, (c, c', c''): over a chain plan the plan parts (p', p'') from the chain table and the profile’s and the pivot’s in closed form; over an intrinsic plan the curve’s own closed-form derivatives, bit for bit. Self::jet_errors bounds their distances from the exact ones.

Source

pub fn jet_errors(&self) -> [Scalar; 3]

Certified bounds, uniform over the table, on how far a point, a derivative and a second derivative it returns are from the exact ones: [e0, e1, e2]. The plan’s max_error, max_tangent_error and max_curvature_error over a chain plan (the closed-form profile adds none); [max_error, 0, 0] over an intrinsic plan, whose derivatives are exact closed forms of the heading.

Source

pub fn max_error(&self) -> Scalar

A certified bound on the error of every point the table returns: the max_error of its plan’s table.

Trait Implementations§

Source§

impl Clone for ElevatedPositionTable

Source§

fn clone(&self) -> ElevatedPositionTable

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for ElevatedPositionTable

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.