singular Value Decomposition(SVD): Difference between revisions

From statwiki
Jump to navigation Jump to search
(Created page with "mmmFor a more in depth reference see: [http://en.wikipedia.org/wiki/Singular_value_decomposition SVD] <math>\ {X}_{d \times n} = {U}_{d \times d}{S}_{d \times d}{V^T}_{d \times ...")
 
(Expanded and restructured this page.)
Line 1: Line 1:
mmmFor a more in depth reference see: [http://en.wikipedia.org/wiki/Singular_value_decomposition SVD]
For a more in depth reference see: [http://en.wikipedia.org/wiki/Singular_value_decomposition SVD]


Any matrix <math>\ X </math> can be decomposed into three matrices:
<math>\ {X}_{d \times n} = {U}_{d \times d}{S}_{d \times d}{V^T}_{d \times n} </math>
<math>\ {X}_{d \times n} = {U}_{d \times d}{S}_{d \times d}{V^T}_{d \times n} </math>


<math>\ {S} = diag(v_1,v_2,...,v_d)</math>
Where <math>\ S </math> is a diagonal matrix and thus, has the following property:
<math>\ S^T = S </math>


<math>\ U^TU=I </math> implying U is an orthonormal matrix
And <math>\ U </math> and <math>\ V </math> are both orthonormal matrices and thus, have the following properties:
<math>\ U^TU=I </math>
<math>\ U^T=U^{-1} </math>


<math>\ U^TV=I </math>
<math>\ V^TV=I </math>
<math>\ V^T=V^{-1} </math>
 
The <math>\ S, U </math> and <math>\ V </math> matrices are constructed in the following manner:
<math>\ S = </math> eigenvalues of <math>\ X^TX </math> = eigenvalues of <math>\ XX^T</math>


<math>\ U</math> represents the left singular vectors of <math>\ X</math>
<math>\ U</math> represents the left singular vectors of <math>\ X</math>
<math>\ V</math> represents the right singular vectors of <math>\ X</math>
<math>\ V</math> represents the right singular vectors of <math>\ X</math>


<math>\ U = </math> eigenvectors of <math>\ X X^T</math>
<math>\ U = </math> eigenvectors of <math>\ X X^T</math>
<math>\ V = </math> eigenvectors of <math>\ X^T X</math>
<math>\ V = </math> eigenvectors of <math>\ X^T X</math>


<math>\ S = </math> eigenvalues of <math>\ X^TX</math> = eigenvalues of <math>\ XX^T</math>
In MATLAB execute:
 
<math>\ U^{-1}=U^T</math>
 
In matlab execute


   [USV] = svd(X)
   [USV] = svd(X)

Revision as of 11:33, 25 September 2011

For a more in depth reference see: SVD

Any matrix [math]\displaystyle{ \ X }[/math] can be decomposed into three matrices: [math]\displaystyle{ \ {X}_{d \times n} = {U}_{d \times d}{S}_{d \times d}{V^T}_{d \times n} }[/math]

Where [math]\displaystyle{ \ S }[/math] is a diagonal matrix and thus, has the following property: [math]\displaystyle{ \ S^T = S }[/math]

And [math]\displaystyle{ \ U }[/math] and [math]\displaystyle{ \ V }[/math] are both orthonormal matrices and thus, have the following properties: [math]\displaystyle{ \ U^TU=I }[/math] [math]\displaystyle{ \ U^T=U^{-1} }[/math]

[math]\displaystyle{ \ V^TV=I }[/math] [math]\displaystyle{ \ V^T=V^{-1} }[/math]

The [math]\displaystyle{ \ S, U }[/math] and [math]\displaystyle{ \ V }[/math] matrices are constructed in the following manner: [math]\displaystyle{ \ S = }[/math] eigenvalues of [math]\displaystyle{ \ X^TX }[/math] = eigenvalues of [math]\displaystyle{ \ XX^T }[/math]

[math]\displaystyle{ \ U }[/math] represents the left singular vectors of [math]\displaystyle{ \ X }[/math] [math]\displaystyle{ \ V }[/math] represents the right singular vectors of [math]\displaystyle{ \ X }[/math]

[math]\displaystyle{ \ U = }[/math] eigenvectors of [math]\displaystyle{ \ X X^T }[/math] [math]\displaystyle{ \ V = }[/math] eigenvectors of [math]\displaystyle{ \ X^T X }[/math]

In MATLAB execute:

 [USV] = svd(X)