Trait alga::linear::FiniteDimVectorSpace [] [src]

pub trait FiniteDimVectorSpace: VectorSpace {
    fn dimension() -> usize;
    fn canonical_basis<F: FnOnce(&[Self])>(f: F);
    fn component(&self, i: usize) -> Self::Field;
    unsafe fn component_unchecked(&self, i: usize) -> Self::Field;
}

A finite-dimensional vector space.

Required Methods

The vector space dimension.

The vector space canonical basis.

Retrieves the i-th component of Self wrt. some basis.

As usual, indexing starts with 0. The actual choice of basis is usually context-dependent and is not specified to this method. It is up to the user to assume the provided component will by wrt. the suitable basis for his application.

Same as .component(i) but without bound-checking.

Implementors