s = svd(M)
[U, S, V] = svd(M)
[U, S, V] = svd(M, 0)
[U, S, V] = svd(M, 'econ')
| Parameter | Description |
|---|---|
| M | a numeric value: matrix (double or single) |
| Parameter | Description |
|---|---|
| s | real vector (singular values) by descending order. |
| U | left singular values. |
| S | real diagonal matrix (singular values) |
| V | right singular values. |
svd computes the Singular Value Decomposition of a matrix.
For an
$$m \times n$$matrix M, the SVD is:
$$M = U\Sigma V^T$$where:
unitary matrix (left singular vectors)
diagonal matrix with non-negative real numbers (singular values)
unitary matrix (right singular vectors)
The singular values
$$\sigma_i$$are arranged in decreasing order:
$$\sigma_1 \geq \sigma_2 \geq \ldots \geq 0$$X = eye(3, 3);
s = svd(X)
[U, S, V] = svd(X)
| Version | Description |
|---|---|
| 1.0.0 | initial version |