Matrix K B3B04A
1. **State the problem:**
Find matrix $K$ such that:
$$(\operatorname{tr}(M - N) - 2) K + \det(M^{-1}) \cdot \operatorname{diag}(1, 3) = \det(N L^T) \cdot M - 2 M M^T + I_2 + P Q$$
2. **Given matrices:**
$$M = \begin{bmatrix}1 & 3 \\ 7 & 8\end{bmatrix}, N = \begin{bmatrix}0 & -5 \\ 2 & 1\end{bmatrix}, L = \begin{bmatrix}2 & 3 \\ -1 & 0\end{bmatrix}, P = \begin{bmatrix}1 & 2 & 0 \\ -1 & 0 & 3\end{bmatrix}, Q = \begin{bmatrix}4 & 0 \\ 1 & -2 \\ 4 & -3\end{bmatrix}$$
3. **Calculate $M - N$:**
$$M - N = \begin{bmatrix}1-0 & 3-(-5) \\ 7-2 & 8-1\end{bmatrix} = \begin{bmatrix}1 & 8 \\ 5 & 7\end{bmatrix}$$
4. **Calculate $\operatorname{tr}(M - N)$:**
$$\operatorname{tr}(M - N) = 1 + 7 = 8$$
5. **Calculate $\det(M)$:**
$$\det(M) = 1 \times 8 - 3 \times 7 = 8 - 21 = -13$$
6. **Calculate $\det(M^{-1})$:**
Since $\det(M^{-1}) = \frac{1}{\det(M)}$,
$$\det(M^{-1}) = \frac{1}{-13} = -\frac{1}{13}$$
7. **Calculate $\det(N L^T)$:**
First find $L^T$:
$$L^T = \begin{bmatrix}2 & -1 \\ 3 & 0\end{bmatrix}$$
Calculate $N L^T$:
$$N L^T = \begin{bmatrix}0 & -5 \\ 2 & 1\end{bmatrix} \begin{bmatrix}2 & -1 \\ 3 & 0\end{bmatrix} = \begin{bmatrix}0 \times 2 + (-5) \times 3 & 0 \times (-1) + (-5) \times 0 \\ 2 \times 2 + 1 \times 3 & 2 \times (-1) + 1 \times 0\end{bmatrix} = \begin{bmatrix}-15 & 0 \\ 7 & -2\end{bmatrix}$$
Calculate determinant:
$$\det(N L^T) = (-15)(-2) - 0 \times 7 = 30$$
8. **Calculate $M M^T$:**
$$M^T = \begin{bmatrix}1 & 7 \\ 3 & 8\end{bmatrix}$$
$$M M^T = \begin{bmatrix}1 & 3 \\ 7 & 8\end{bmatrix} \begin{bmatrix}1 & 7 \\ 3 & 8\end{bmatrix} = \begin{bmatrix}1 \times 1 + 3 \times 3 & 1 \times 7 + 3 \times 8 \\ 7 \times 1 + 8 \times 3 & 7 \times 7 + 8 \times 8\end{bmatrix} = \begin{bmatrix}10 & 31 \\ 31 & 113\end{bmatrix}$$
9. **Calculate $P Q$:**
$$P = \begin{bmatrix}1 & 2 & 0 \\ -1 & 0 & 3\end{bmatrix}, Q = \begin{bmatrix}4 & 0 \\ 1 & -2 \\ 4 & -3\end{bmatrix}$$
$$P Q = \begin{bmatrix}1 \times 4 + 2 \times 1 + 0 \times 4 & 1 \times 0 + 2 \times (-2) + 0 \times (-3) \\ -1 \times 4 + 0 \times 1 + 3 \times 4 & -1 \times 0 + 0 \times (-2) + 3 \times (-3)\end{bmatrix} = \begin{bmatrix}6 & -4 \\ 8 & -9\end{bmatrix}$$
10. **Calculate $I_2$ (2x2 identity matrix):**
$$I_2 = \begin{bmatrix}1 & 0 \\ 0 & 1\end{bmatrix}$$
11. **Calculate right side:**
$$\det(N L^T) \cdot M - 2 M M^T + I_2 + P Q = 30 \begin{bmatrix}1 & 3 \\ 7 & 8\end{bmatrix} - 2 \begin{bmatrix}10 & 31 \\ 31 & 113\end{bmatrix} + \begin{bmatrix}1 & 0 \\ 0 & 1\end{bmatrix} + \begin{bmatrix}6 & -4 \\ 8 & -9\end{bmatrix}$$
Calculate each term:
$$30 M = \begin{bmatrix}30 & 90 \\ 210 & 240\end{bmatrix}$$
$$-2 M M^T = \begin{bmatrix}-20 & -62 \\ -62 & -226\end{bmatrix}$$
Sum all:
$$\begin{bmatrix}30 & 90 \\ 210 & 240\end{bmatrix} + \begin{bmatrix}-20 & -62 \\ -62 & -226\end{bmatrix} + \begin{bmatrix}1 & 0 \\ 0 & 1\end{bmatrix} + \begin{bmatrix}6 & -4 \\ 8 & -9\end{bmatrix} = \begin{bmatrix}30 - 20 + 1 + 6 & 90 - 62 + 0 - 4 \\ 210 - 62 + 0 + 8 & 240 - 226 + 1 - 9\end{bmatrix} = \begin{bmatrix}17 & 24 \\ 156 & 6\end{bmatrix}$$
12. **Calculate left side coefficient:**
$$\operatorname{tr}(M - N) - 2 = 8 - 2 = 6$$
13. **Calculate $\det(M^{-1}) \cdot \operatorname{diag}(1,3)$:**
$$-\frac{1}{13} \cdot \begin{bmatrix}1 & 0 \\ 0 & 3\end{bmatrix} = \begin{bmatrix}-\frac{1}{13} & 0 \\ 0 & -\frac{3}{13}\end{bmatrix}$$
14. **Rewrite equation for $K$:**
$$(6) K + \begin{bmatrix}-\frac{1}{13} & 0 \\ 0 & -\frac{3}{13}\end{bmatrix} = \begin{bmatrix}17 & 24 \\ 156 & 6\end{bmatrix}$$
15. **Isolate $K$:**
$$6 K = \begin{bmatrix}17 & 24 \\ 156 & 6\end{bmatrix} - \begin{bmatrix}-\frac{1}{13} & 0 \\ 0 & -\frac{3}{13}\end{bmatrix} = \begin{bmatrix}17 + \frac{1}{13} & 24 \\ 156 & 6 + \frac{3}{13}\end{bmatrix}$$
16. **Simplify entries:**
$$17 + \frac{1}{13} = \frac{221}{13}, \quad 6 + \frac{3}{13} = \frac{81}{13}$$
17. **Divide by 6:**
$$K = \frac{1}{6} \begin{bmatrix} \frac{221}{13} & 24 \\ 156 & \frac{81}{13} \end{bmatrix} = \begin{bmatrix} \frac{221}{78} & 4 \\ 26 & \frac{27}{26} \end{bmatrix}$$
**Final answer:**
$$K = \begin{bmatrix} \frac{221}{78} & 4 \\ 26 & \frac{27}{26} \end{bmatrix}$$