[ VIGRA Homepage | Function Index | Class Index | Namespaces | File List | Main Page ]
Solution of linear systems, eigen systems, linear least squares etc. More...
Functions | |
template<class T , class C1 , class C2 , class C3 , class C4 > | |
unsigned int | singularValueDecomposition (MultiArrayView< 2, T, C1 > const &A, MultiArrayView< 2, T, C2 > &U, MultiArrayView< 2, T, C3 > &S, MultiArrayView< 2, T, C4 > &V) |
Solution of linear systems, eigen systems, linear least squares etc.
unsigned int singularValueDecomposition | ( | MultiArrayView< 2, T, C1 > const & | A, |
MultiArrayView< 2, T, C2 > & | U, | ||
MultiArrayView< 2, T, C3 > & | S, | ||
MultiArrayView< 2, T, C4 > & | V | ||
) |
Singular Value Decomposition.
For an m-by-n matrix A with m >= n, the singular value decomposition is an m-by-n orthogonal matrix U, an n-by-n diagonal matrix S, and an n-by-n orthogonal matrix V so that A = U*S*V'.
To save memory, this functions stores the matrix S in a column vector of appropriate length (a diagonal matrix can be obtained by diagonalMatrix(S)
). The singular values, sigma[k] = S(k, 0), are ordered so that sigma[0] >= sigma[1] >= ... >= sigma[n-1].
The singular value decomposition always exists, so this function will never fail (except if the shapes of the argument matrices don't match). The effective numerical rank of A is returned.
(Adapted from JAMA, a Java Matrix Library, developed jointly by the Mathworks and NIST; see http://math.nist.gov/javanumerics/jama).
#include <vigra/singular_value_decomposition.hxx> or
#include <vigra/linear_algebra.hxx>
Namespaces: vigra and vigra::linalg
© Ullrich Köthe (ullrich.koethe@iwr.uni-heidelberg.de) |