Function rgsl::linear_algebra::SV_decomp
source · [−]pub fn SV_decomp(
a: &mut MatrixF64,
v: &mut MatrixF64,
s: &mut VectorF64,
work: &mut VectorF64
) -> Value
Expand description
This function factorizes the M-by-N matrix A into the singular value decomposition A = U S V^T for M >= N. On output the matrix A is replaced by U. The diagonal elements of the singular value matrix S are stored in the vector S. The singular values are non-negative and form a non-increasing sequence from S_1 to S_N. The matrix V contains the elements of V in untransposed form. To form the product U S V^T it is necessary to take the transpose of V. A workspace of length N is required in work.
This routine uses the Golub-Reinsch SVD algorithm.