2. Homework #2ΒΆ
For all programming assignments, please turn in your code along with your solution. Submissions should be made on Sakai.
Problem 1
Let \(A\in\mathbb R^{n\times n}\) be any matrix, and \(I\) be the \(n\times n\) identity matrix. Show that the matrix \(L_k = I + m_ke_k^T\) is the inverse of the matrix \(M_k = I - m_ke_k^T\), where \(M_k\) is the elimination matrix for the \(k^{th}\) column \(a_k\) of \(A\).
Problem 2
Write a program to compute the LU decomposition of a matrix \(A\) using the concept of elimination matrices. Use it to solve the following system:
Problem 3
Suppose that \(\lVert\cdot\rVert_a\) and \(\lVert\cdot\rVert_b\) are two equivalent vector norms in \(\mathbb R^n\). Thus, by definition, there exist two constants \(c,d>0\) such that for any vector \(x\in\mathbb R^n\), we have
Prove that their induced matrix norms are also equivalent, i.e., there exist two constants \(c',d'>0\) such that for any matrix \(A\in\mathbb R^{n\times n}\)
Problem 4
- Use a single-precision routine for Gaussian elimination to solve the system \(Ax=b\) defined below
- Compute the residual \(r = b - Ax\) using double-precision arithmetic, but storing the final result in a single-precision vector \(r\). (Note that the solution routine may destroy the matrix \(A\), so you may need to save a separate copy for computing the residual.)
- Solve the linear system \(Az=r\) to obtain the “improved” solution \(x+z\). (Note that the matrix \(A\) need not be refactored.)
- Repeat steps \(b)\) and \(c)\) until no further improvement is observed.
Problem 5
Use Gaussian elimination without pivoting to solve the linear system
for \(\varepsilon=10^{-2k}\), where \(k=1,2,\ldots,10\). The exact solution is \(x=(1,1)^T\), independent of the value of \(\varepsilon\). How does the acccuracy of the computed solution behave as the value of \(\varepsilon\) decreases?