Struct feanor_math::matrix::dense::DenseMatrix

source ·
pub struct DenseMatrix<R>
where R: ?Sized + RingBase,
{ /* private fields */ }

Implementations§

source§

impl<R> DenseMatrix<R>
where R: ?Sized + RingBase,

source

pub fn new(data: Box<[R::Element]>, col_count: usize) -> Self

source

pub fn data<'a>( &'a self ) -> Submatrix<'a, AsFirstElement<R::Element>, R::Element>

source

pub fn data_mut<'a>( &'a mut self ) -> SubmatrixMut<'a, AsFirstElement<R::Element>, R::Element>

source§

impl<R> DenseMatrix<R>
where R: ?Sized + RingBase,

source

pub fn at(&self, i: usize, j: usize) -> &R::Element

source

pub fn at_mut(&mut self, i: usize, j: usize) -> &mut R::Element

source

pub fn identity<S>(n: usize, ring: S) -> Self
where S: RingStore<Type = R>,

source

pub fn zero<S>(n: usize, m: usize, ring: S) -> Self
where S: RingStore<Type = R>,

source

pub fn clone_matrix<S>(&self, ring: S) -> Self
where S: RingStore<Type = R>,

source

pub fn set_row_count<S>(&mut self, new_count: usize, ring: S)
where S: RingStore<Type = R>,

Trait Implementations§

source§

impl<R> Matrix<R> for DenseMatrix<R>
where R: ?Sized + RingBase,

source§

fn row_count(&self) -> usize

source§

fn col_count(&self) -> usize

source§

fn entry_at(&self, i: usize, j: usize) -> &R::Element

source§

fn format<'a, S>(&'a self, ring: &'a S) -> MatrixDisplayWrapper<'a, R, Self>
where S: RingStore<Type = R>,

source§

fn matrix_eq<M, S>(&self, other: &M, ring: S) -> bool
where M: Matrix<R>, S: RingStore<Type = R>,

Auto Trait Implementations§

§

impl<R> Freeze for DenseMatrix<R>
where R: ?Sized,

§

impl<R> RefUnwindSafe for DenseMatrix<R>
where <R as RingBase>::Element: RefUnwindSafe, R: ?Sized,

§

impl<R> Send for DenseMatrix<R>
where <R as RingBase>::Element: Send, R: ?Sized,

§

impl<R> Sync for DenseMatrix<R>
where <R as RingBase>::Element: Sync, R: ?Sized,

§

impl<R> Unpin for DenseMatrix<R>
where R: ?Sized,

§

impl<R> UnwindSafe for DenseMatrix<R>
where <R as RingBase>::Element: UnwindSafe, R: ?Sized,

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> 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, U> TryFrom<U> for T
where U: Into<T>,

§

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>,

§

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.