singular value decomposition

[[concept]]

[!themes] Topics

Evaluation Error: SyntaxError: Unexpected token '>'

at DataviewInlineApi.eval (plugin:dataview:19027:21)
at evalInContext (plugin:dataview:19028:7)
at asyncEvalInContext (plugin:dataview:19038:32)
at DataviewJSRenderer.render (plugin:dataview:19064:19)
at DataviewJSRenderer.onload (plugin:dataview:18606:14)
at DataviewJSRenderer.load (app://obsidian.md/app.js:1:1182416)
at DataviewApi.executeJs (plugin:dataview:19607:18)
at DataviewCompiler.eval (plugin:digitalgarden:10763:23)
at Generator.next (<anonymous>)
at eval (plugin:digitalgarden:90:61)

Definitions

Theorem (Matrix Analysis 1)

Theorem (Matrix Analysis 2)

Theorem (Singular Value Decomposition)

For any A∈Mm,n, there exists U∈Mm, V∈Mn both unitary and Σ∈Mm,n "diagonal" with min{m,n} real, nonnegative, nonincreasing, entries such that

A=UΣV∗

Further, if A is real-valued, we can take each of U,Σ,V to be real.

(we take "diagonal" to mean that the only entries that can be nonzero have the same row and column index)

Note

  • We can think of this as a generalization of diagonalization/spectral decomposition, but where the loss is that U and V are distinct.
  • if A is positive semidefinite, then the diagonalization is the singular value decomposition since we have that A=UΣU∗ for some unitary U and nonnegative Σ all real.

Proof

If m≤n, then by the previous definition here we have A=UΣW where U∈Mn unitary, Σ∈Mm diagonal, and W∈Mm,n with orthogonal columns. Since m≤n, we add n−m columns of zeros to Σ to make it size m×n. Then we can append n−m orthogonal rows to W with Gram-Schmidt to get a V∗

If n>m, then A∗=UΣV∗ is SVD by the above case. But then A=VΣTU∗ is an SVD of A!

Another Definition (Data Science)

X=UΣV∗

Where U∈Cn×n,V∈Cm×m are unitary and orthonormal. A unitary matrix U is one such that U∗U=UU∗=I. The columns of U are called the left singular vectors of X, and the columns of V are called the right singular vectors. The entries of Σ are called the singular values

Notes on SVD

Say A∈Mm,n and A∈UΣV∗ its SVD. Suppose there are k non-negative singular values call them σ1,…,σk. Denote u1,…um the columns of U and v1∗,…,vn∗ the rows of V∗. Then

  1. A=UΣV∗=∑i=1kσiuivi∗
  2. rank(A)=rank(Σ)=k
  3. range(A)=span{u1,…,uk} - easy to see from (1)
  4. null(A)=span(vk+1,…,vn) - easy to see from (1)
  5. range(A∗)=span{v1,…,vk}
  6. null(A∗)=span{uk+1,…,um}
  7. For any A∈Mm,n, we have ||A||2,2:=maxx∈Cn≠0||Ax||2||x||2=σ1
  8. ||A||F2=||UΣV∗||F2=||Σ||F2=∑i=1kσi

To see (5) and (6) , recall that A∗=VΣTU∗ and we simply apply (3) and (4) in this case.

To see (7), note that

||A||2,22=maxx≠0||Ax||2||x||2=maxx∗A∗Axx∗x=∗,∗∗σ12

References

References

See Also

Mentions

Mentions

const modules = await cJS()

const COLUMNS = [  
	{ id: "Name", value: page => page.$link },  
	{ id: "Last Modified", value: page => modules.dateTime.getLastMod(page) },
];  
  
return function View() {  
	const current = dc.useCurrentFile();
// Selecting `#game` pages, for example. 
	let queryString = `@page and linksto(${current.$link})`;
	let pages = dc.useQuery(queryString);
	
	// check types
	pages = pages.filter( (p) => !modules.typeCheck.checkAll(p, current) ).sort()
	
	
	return <dc.Table columns={COLUMNS} rows={pages} paging={20}/>;  
}  

const { dateTime } = await cJS()

return function View() {
	const file = dc.useCurrentFile();
	return <p class="dv-modified">Created {dateTime.getCreated(file)}     ֍     Last Modified {dateTime.getLastMod(file)}</p>
}