5.2-exam2-2010¶
Quiz 2, 2010 · Section 5.2: Computing and Using Determinants Source: exam2_2.pdf, pp. 5-7
Problem¶
3. (33 points) This problem is about the \(n\) by \(n\) matrix \(A_n\) that has zeros on its main diagonal and all other entries equal to \(-1\). In MATLAB \(A_n = eye(n) - ones(n)\).
(a) Find the determinant of \(A_n\). Here is a suggested approach: start by adding all rows (except the last) to the last row, and then factoring out a constant. (You could check \(n = 3\) to have a start on part b.)
(b) For any invertible matrix \(A\), the \((1, 1)\) entry of \(A^{-1}\) is the ratio of __. So the \((1, 1)\) entry of \(A_4^{-1}\) is __.
(c) Find two orthogonal eigenvectors with \(A_3x = x\). (So \(\lambda = 1\) is a double eigenvalue.)
(d) What is the third eigenvalue of \(A_3\) and a corresponding eigenvector?
Solution
(a) Following the hint, add all of the rows to the last row (which does not change the determinant). The matrix becomes \[ \begin{bmatrix} 0 & -1 & -1 & \cdots & -1 \\ -1 & 0 & -1 & \cdots & -1 \\ -1 & -1 & 0 & \cdots & -1 \\ \vdots & \vdots & \vdots & & \vdots \\ -(n-1) & -(n-1) & -(n-1) & \cdots & -(n-1) \end{bmatrix}. \] Next, pull out the factor of \(-(n-1)\) from the last row. As the determinant is linear in each row separately, we get \[ \begin{vmatrix} 0 & -1 & -1 & \cdots & -1 \\ -1 & 0 & -1 & \cdots & -1 \\ -1 & -1 & 0 & \cdots & -1 \\ \vdots & \vdots & \vdots & & \vdots \\ -(n-1) & -(n-1) & -(n-1) & \cdots & -(n-1) \end{vmatrix} = (1-n) \begin{vmatrix} 0 & -1 & -1 & \cdots & -1 \\ -1 & 0 & -1 & \cdots & -1 \\ -1 & -1 & 0 & \cdots & -1 \\ \vdots & \vdots & \vdots & & \vdots \\ 1 & 1 & 1 & \cdots & 1 \end{vmatrix}. \] Next, add the last row back to each of the other rows (which again keeps the determinant the same). So now we want to find \[ (1-n) \begin{vmatrix} 1 & 0 & 0 & \cdots & 0 \\ 0 & 1 & 0 & \cdots & 0 \\ 0 & 0 & 1 & \cdots & 0 \\ \vdots & \vdots & \vdots & & \vdots \\ 1 & 1 & 1 & \cdots & 1 \end{vmatrix}. \] This matrix is lower triangular, so its determinant is the product of the entries on its diagonal. Thus the above quantity is \((1 - n)\). Alternately, one can find the determinant by finding all the eigenvalues. As \(A_n = I - ones(n)\), we know that \(N(A_n - I) = N(-ones(n))\). The latter nullspace has dimension \(n - 1\). Thus 1 is an eigenvalue of multiplicity \(n - 1\), and the corresponding eigenvectors are all the nonzero vectors whose entries add up to 0. In addition, all of the rows of \(A_n\) add up to \(1 - n\), so \(1 - n\) is an eigenvalue with eigenvector \((1, 1, \dots, 1)\). Thus we have found all of the eigenvectors and eigenvalues. The determinant is the product of the eigenvalues, so it is \(1^{n-1} \cdot (1 - n)\) or \(1 - n\). RUBRIC: 2 points for following the hint, 2 points for pulling out the factor of \((1-n)\) correctly, 2 points for adding the last row to the other rows, 2 points for the correct answer. (b) Cramer's rule gives \(A^{-1} = \frac{1}{|A|} C^T\), where \(C\) is the cofactor matrix, whose \((i, j)\) entry is \((-1)^{i+j}|M_{ij}|\), with \(M_{ij}\) the submatrix obtained by deleting row \(i\) and column \(j\) of the (arbitrary) invertible matrix \(A\). Thus the entry with \(i = j = 1\) is \(|M_{11}|/|A|\). In the case where \(A = A_n\), the submatrix \(M_{11}\) is \(A_{n-1}\), so the desired formula is \(|A_{n-1}|/|A_n|\). Now \(|A_n| = 1 - n\) by part (a), so \(|A_4| = -3\) and \(|A_3| = -2\). Thus the \((1, 1)\) entry of \(A_4^{-1}\) is \(2/3\). RUBRIC: 5 points for the correct ratio, 5 points for the correct application to the current problem. If the wrong ratio was given, then no credit was given for applying it. (c) In solution 2 of part (a) above, we saw that the eigenvectors are all the nonzero vectors whose entries add up to 0. Two obvious such vectors are \((1, -1, 0)\) and \((0, 1, -1)\), but there are many more linearly independent pairs. However, \((1, -1, 0)\) and \((0, 1, -1)\) are not orthogonal! So we must find another pair. We can use the Gram-Schmidt process to get orthogonal vectors, or we can just try to guess two orthogonal vectors whose entries add up to 0. For example, \((1, -1, 0)\) and \((1, 1, -2)\) work. (Note that the vectors are not required to have unit length.) RUBRIC: up to 5 points for a correct method, 2 points for finding linearly independent vectors, 3 points for orthogonality. (d) In solution 2 of part (a) above, we saw that the third eigenvalue is \(-2\) and a corresponding eigenvector is \((1, 1, 1)\). Another way to proceed is to notice that the trace of \(A_3\) is 0. However, the trace is the sum of the eigenvalues, and two of them are 1. So the third must be \(-2\). Alternatively, in part (a), we saw that \(|A_3| = -2\); the determinant is the product of the eigenvalues, and two of them are 1, so the third must be \(-2\). A third way to proceed is to find the characteristic polynomial of \(A_3\), which is \(\lambda^3 - 3\lambda + 2\). Since 1 is a double root, we can find the third root by dividing twice by \(\lambda - 1\). RUBRIC: 5 points for the eigenvalue, 5 points for a corresponding eigenvector.Keywords: determinant, Cramer's rule, eigenvalues, eigenvectors