Trait peroxide::traits::matrix::MatrixTrait

source ·
pub trait MatrixTrait:
    Sized
    + Index<(usize, usize), Output = Self::Scalar>
    + IndexMut<(usize, usize)> {
    type Scalar;

Show 19 methods // Required methods fn ptr(&self) -> *const Self::Scalar; fn mut_ptr(&mut self) -> *mut Self::Scalar; fn as_slice(&self) -> &[Self::Scalar]; fn as_mut_slice(&mut self) -> &mut [Self::Scalar]; fn change_shape(&self) -> Self; fn change_shape_mut(&mut self); fn spread(&self) -> String; fn col(&self, index: usize) -> Vec<Self::Scalar>; fn row(&self, index: usize) -> Vec<Self::Scalar>; fn diag(&self) -> Vec<Self::Scalar>; fn transpose(&self) -> Self; fn subs_col(&mut self, idx: usize, v: &[Self::Scalar]); fn subs_row(&mut self, idx: usize, v: &[Self::Scalar]); fn from_index<F, G>(f: F, size: (usize, usize)) -> Self where F: Fn(usize, usize) -> G + Copy, G: Into<Self::Scalar>; fn to_vec(&self) -> Vec<Vec<Self::Scalar>>; fn to_diag(&self) -> Self; fn submat(&self, start: (usize, usize), end: (usize, usize)) -> Self; fn subs_mat(&mut self, start: (usize, usize), end: (usize, usize), m: &Self); // Provided method fn t(&self) -> Self { ... }
}

Required Associated Types§

Required Methods§

source

fn ptr(&self) -> *const Self::Scalar

source

fn mut_ptr(&mut self) -> *mut Self::Scalar

source

fn as_slice(&self) -> &[Self::Scalar]

source

fn as_mut_slice(&mut self) -> &mut [Self::Scalar]

source

fn change_shape(&self) -> Self

source

fn change_shape_mut(&mut self)

source

fn spread(&self) -> String

source

fn col(&self, index: usize) -> Vec<Self::Scalar>

source

fn row(&self, index: usize) -> Vec<Self::Scalar>

source

fn diag(&self) -> Vec<Self::Scalar>

source

fn transpose(&self) -> Self

source

fn subs_col(&mut self, idx: usize, v: &[Self::Scalar])

source

fn subs_row(&mut self, idx: usize, v: &[Self::Scalar])

source

fn from_index<F, G>(f: F, size: (usize, usize)) -> Self
where F: Fn(usize, usize) -> G + Copy, G: Into<Self::Scalar>,

source

fn to_vec(&self) -> Vec<Vec<Self::Scalar>>

source

fn to_diag(&self) -> Self

source

fn submat(&self, start: (usize, usize), end: (usize, usize)) -> Self

source

fn subs_mat(&mut self, start: (usize, usize), end: (usize, usize), m: &Self)

Provided Methods§

source

fn t(&self) -> Self

Object Safety§

This trait is not object safe.

Implementors§