This commit is contained in:
Steven G. Johnson 2023-02-19 13:48:55 -05:00
parent 261c79ed71
commit 8d9752bc84
2 changed files with 64 additions and 1 deletions

View File

@ -116,6 +116,6 @@ The *nice* case of diagonalization is when you have **orthonormal eigenvectors**
* SVD and eigenvalues: U and V as eigenvectors of AAᵀ and AᵀA, respectively, and σₖ² as the positive eigenvalues.
* Deriving the SVD from eigenvalues: the key step is showing that AAᵀ and AᵀA share the same positive eigenvalues, and λₖ=σₖ², with eigenvectors related by a factor of A. From there you can work backwards to the SVD.
* [pset 1 solutions](psets/pset1sol.ipynb)
* pset 2: coming soon
* [pset 2](psets/pset2.ipynb): Due March 3 at 1pm
**Further reading**: [OCW lecture 6](https://ocw.mit.edu/courses/18-065-matrix-methods-in-data-analysis-signal-processing-and-machine-learning-spring-2018/resources/lecture-6-singular-value-decomposition-svd/) and textbook section I.8. The [Wikipedia SVD article](https://en.wikipedia.org/wiki/Singular_value_decomposition).

63
psets/pset2.ipynb Normal file
View File

@ -0,0 +1,63 @@
{
"cells": [
{
"cell_type": "markdown",
"id": "0f2a9965",
"metadata": {},
"source": [
"# 18.085 Problem Set 2\n",
"\n",
"Due Friday **March 3** at 1pm."
]
},
{
"cell_type": "markdown",
"id": "d9e8ae37",
"metadata": {},
"source": [
"## Problem 1\n",
"\n",
"**(a)** The eigenvalues of a real *anti-Hermitian* matrix $A = -A^T$ must be \\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_\\_. Derive this by considering $\\overline{x^T} A x$ for an eigenvector $Ax = \\lambda x$, and demonstrate it numerically by constructing a random anti-Hermitian matrix `A = randn(n,n); A = A - A'` in Julia and looking at its eigenvalues `using LinearAlgebra; eigvals(A)` for `n=4` and `n=5`. (You might want to try the numerical experiment first if you aren't sure what the answer is.)\n",
"\n",
"**(b)** Suppose $A$ is a $3 \\times 3$ real-symmetric matrix with eigenvalues $\\lambda_1 = -2$, $\\lambda_2 = 3$, and $\\lambda_3 = -1$, with corresponding orthonormal eigenvectors $q_1, q_2, q_3$. In terms of these quantities, give the (full) SVD of $A$.\n",
"\n",
"**(c)** Construct a random $5 \\times 3$ matrix `A = randn(5, 3)` and form a related *real-symmetric* matrix `B = [ 0I A; A' 0I ]`, corresponding to\n",
"$$\n",
"B = \\begin{pmatrix} 0 & A \\\\ A^T & 0 \\end{pmatrix} .\n",
"$$\n",
"Compare the eigenvalues of $B$ (`eigvals(B)`) to the singular values of $A$ (`svdvals(A)`). What do you notice? Explain it by using the SVD $A = U \\Sigma V^T$ to construct eigenvalues and eigenvectors of $B$."
]
},
{
"cell_type": "markdown",
"id": "88ac965b",
"metadata": {},
"source": [
"## Problems 2, 3, etc: coming soon"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "e1fca19a",
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Julia 1.8.0",
"language": "julia",
"name": "julia-1.8"
},
"language_info": {
"file_extension": ".jl",
"mimetype": "application/julia",
"name": "julia",
"version": "1.8.2"
}
},
"nbformat": 4,
"nbformat_minor": 5
}