pub struct Point {
pub cs: Vec<f64>,
}Fields§
§cs: Vec<f64>Implementations§
Source§impl Point
impl Point
pub fn new_default(dim: usize) -> Self
pub fn new(cs: Vec<f64>) -> Self
pub fn new_random(rng: &mut ThreadRng, dim: usize, rad: f64) -> Self
pub fn coords(&self) -> Vec<f64>
pub fn mul(&self, a: f64) -> Self
pub fn add(&self, other: &Self) -> Self
pub fn sub(&self, other: &Self) -> Self
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Point
impl RefUnwindSafe for Point
impl Send for Point
impl Sync for Point
impl Unpin for Point
impl UnwindSafe for Point
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