The singular value decomposition of an m x n matrix A (where m >= n) is a decomposition
A = U * D * V.t()where U is m x n with U.t() * U equalling the identity, D is an n x n diagonal matrix and V is an n x n orthogonal matrix.
Singular value decompositions are useful for understanding the structure of ill-conditioned matrices, solving least squares problems, and for finding the eigenvalues of A.t() * A.
To calculate the singular value decomposition of A (with m >= n) use one of
SVD(A, D, U, V); // U (= A is OK) SVD(A, D); SVD(A, D, U); // U (= A is OK) SVD(A, D, U, FALSE); // U (can = A) for workspace only SVD(A, D, U, V, FALSE); // U (can = A) for workspace onlyThe values of A are not changed unless A is also inserted as the third argument.