|void||svdcmp (mat A, int M, int N, vect W, mat V)|
|Computes the singular value decomposition of A. |
|#define false 0|
|#define true 1|
Computes the singular value decomposition of A.
Give a matrix A, dimensions M by N, this routine computes its singular value decomposition, A = U * W * transpose V. The matrix U replaces A on output. The diagonal matrix of singular values, W, is output as a vector W. The matrix V (not the transpose of V) is output as V. M must be greater or equal to N. If it is smaller then A should be filled up to square with zero rows.