pub struct Hyperplane { /* private fields */ }Expand description
An n-dimensional hyperplane represented by coefficients.dot(point) + offset = 0.
Implementations§
Source§impl Hyperplane
impl Hyperplane
Sourcepub fn try_new(
coefficients: Vec<f64>,
offset: f64,
) -> Result<Self, GeometryError>
pub fn try_new( coefficients: Vec<f64>, offset: f64, ) -> Result<Self, GeometryError>
Creates a validated hyperplane from finite coefficients and finite offset.
§Errors
Returns a GeometryError when coefficients are empty, non-finite, all zero,
or when the offset is non-finite.
Sourcepub fn coefficients(&self) -> &[f64]
pub fn coefficients(&self) -> &[f64]
Returns the coefficient vector.
Trait Implementations§
Source§impl Clone for Hyperplane
impl Clone for Hyperplane
Source§fn clone(&self) -> Hyperplane
fn clone(&self) -> Hyperplane
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 moreSource§impl Debug for Hyperplane
impl Debug for Hyperplane
Source§impl PartialEq for Hyperplane
impl PartialEq for Hyperplane
Source§fn eq(&self, other: &Hyperplane) -> bool
fn eq(&self, other: &Hyperplane) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for Hyperplane
Auto Trait Implementations§
impl Freeze for Hyperplane
impl RefUnwindSafe for Hyperplane
impl Send for Hyperplane
impl Sync for Hyperplane
impl Unpin for Hyperplane
impl UnsafeUnpin for Hyperplane
impl UnwindSafe for Hyperplane
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