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

Implementations§

source§

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

source

pub fn new<S>(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 add_col(&mut self, j: usize)

source

pub fn add_cols(&mut self, number: usize)

source

pub fn add_zero_row(&mut self, i: usize)

source

pub fn add_row<I>(&mut self, i: usize, values: I)
where I: Iterator<Item = (usize, R::Element)>,

source

pub fn set(&mut self, i: usize, j: usize, el: R::Element) -> Option<R::Element>

Trait Implementations§

source§

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

source§

fn col_count(&self) -> usize

source§

fn row_count(&self) -> usize

source§

fn 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: ?Sized> RefUnwindSafe for SparseMatrixBuilder<R>

§

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

§

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

§

impl<R: ?Sized> Unpin for SparseMatrixBuilder<R>
where <R as RingBase>::Element: Unpin,

§

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

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.