pub struct IdentityView {
pub n: usize,
}Expand description
The n x n identity, applied without storage.
Fields§
§n: usizeThe dimension n.
Implementations§
Source§impl IdentityView
impl IdentityView
Sourcepub fn matvec<S: Semiring>(&self, v: &[S]) -> Result<Vec<S>, AlgebraError>
pub fn matvec<S: Semiring>(&self, v: &[S]) -> Result<Vec<S>, AlgebraError>
Apply to a vector: returns a clone of v.
Sourcepub fn materialize<S: Semiring>(
&self,
limits: AlgebraLimits,
) -> Result<Matrix<S>, AlgebraError>
pub fn materialize<S: Semiring>( &self, limits: AlgebraLimits, ) -> Result<Matrix<S>, AlgebraError>
Materialize as a dense identity, guarded by limits.
Trait Implementations§
Source§impl Clone for IdentityView
impl Clone for IdentityView
Source§fn clone(&self) -> IdentityView
fn clone(&self) -> IdentityView
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 moreimpl Copy for IdentityView
Source§impl Debug for IdentityView
impl Debug for IdentityView
impl Eq for IdentityView
Source§impl PartialEq for IdentityView
impl PartialEq for IdentityView
impl StructuralPartialEq for IdentityView
Auto Trait Implementations§
impl Freeze for IdentityView
impl RefUnwindSafe for IdentityView
impl Send for IdentityView
impl Sync for IdentityView
impl Unpin for IdentityView
impl UnsafeUnpin for IdentityView
impl UnwindSafe for IdentityView
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