Trait linfa_linalg::svd::SVD

source ·
pub trait SVD {
    type U;
    type Vt;
    type Sigma;

    // Required method
    fn svd(
        &self,
        calc_u: bool,
        calc_vt: bool,
    ) -> Result<(Option<Self::U>, Self::Sigma, Option<Self::Vt>)>;
}
Expand description

Compact singular-value decomposition of a non-empty matrix

Required Associated Types§

Required Methods§

source

fn svd( &self, calc_u: bool, calc_vt: bool, ) -> Result<(Option<Self::U>, Self::Sigma, Option<Self::Vt>)>

Calculates the compact SVD of a matrix, consisting of a square non-negative diagonal matrix S and rectangular semi-orthogonal matrices U and Vt, such that U * S * Vt yields the original matrix. Only the diagonal elements of S is returned.

Implementations on Foreign Types§

source§

impl<A: NdFloat, S: Data<Elem = A>> SVD for ArrayBase<S, Ix2>

source§

type U = ArrayBase<OwnedRepr<A>, Dim<[usize; 2]>>

source§

type Vt = ArrayBase<OwnedRepr<A>, Dim<[usize; 2]>>

source§

type Sigma = ArrayBase<OwnedRepr<A>, Dim<[usize; 1]>>

source§

fn svd( &self, calc_u: bool, calc_vt: bool, ) -> Result<(Option<Self::U>, Self::Sigma, Option<Self::Vt>)>

Implementors§