Subjects linear algebra

Matrix Transformation

Step-by-step solutions with LaTeX - clean, fast, and student-friendly.

Search Solutions

Matrix Transformation


1. **State the problem:** We need to find matrix transformations for rotating an image by a positive $\frac{\pi}{2}$ turn (90 degrees) about the origin, scaling by 2 times, reflecting across the y-axis, apply combined transformations to an image matrix, and then find the inverse transformation matrix. 2. **Given image matrix:** $$A = \begin{bmatrix} 2 & 1 \\ 3 & 4 \end{bmatrix}$$ each column is a pixel coordinate. 3. **(a) Matrix representations:** - Rotation by $\frac{\pi}{2}$ (90 degrees) counterclockwise: $$R = \begin{bmatrix} \cos 90^\circ & -\sin 90^\circ \\ \sin 90^\circ & \cos 90^\circ \end{bmatrix} = \begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix}$$ - Scaling by factor 2 about origin: $$S = \begin{bmatrix} 2 & 0 \\ 0 & 2 \end{bmatrix}$$ - Reflection across y-axis: $$M = \begin{bmatrix} -1 & 0 \\ 0 & 1 \end{bmatrix}$$ 4. **(b) Single matrix for combined transforms:** The transformations are applied in order: rotate, then scale, then reflect. Since matrix multiplication applies transformations from right to left, the combined matrix is: $$T = M \times S \times R$$ Calculate stepwise: $$S \times R = \begin{bmatrix} 2 & 0 \\ 0 & 2 \end{bmatrix} \times \begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix} = \begin{bmatrix} 0 & -2 \\ 2 & 0 \end{bmatrix}$$ Then: $$T = M \times (S \times R) = \begin{bmatrix} -1 & 0 \\ 0 & 1 \end{bmatrix} \times \begin{bmatrix} 0 & -2 \\ 2 & 0 \end{bmatrix} = \begin{bmatrix} 0 & 2 \\ 2 & 0 \end{bmatrix}$$ 5. **(c) Apply the combined matrix $T$ to image matrix $A$: $$T A = \begin{bmatrix} 0 & 2 \\ 2 & 0 \end{bmatrix} \times \begin{bmatrix} 2 & 1 \\ 3 & 4 \end{bmatrix} = \begin{bmatrix} 0 \times 2 + 2 \times 3 & 0 \times 1 + 2 \times 4 \\ 2 \times 2 + 0 \times 3 & 2 \times 1 + 0 \times 4 \end{bmatrix} = \begin{bmatrix} 6 & 8 \\ 4 & 2 \end{bmatrix}$$ 6. **(d) Find the inverse matrix to undo transformations:** We want $T^{-1}$ so that $T^{-1} T A = A$. Matrix $T = \begin{bmatrix} 0 & 2 \\ 2 & 0 \end{bmatrix}$. Calculate determinant: $$\det(T) = 0 \times 0 - 2 \times 2 = -4$$ The inverse is: $$T^{-1} = \frac{1}{-4} \begin{bmatrix} 0 & -2 \\ -2 & 0 \end{bmatrix} = \begin{bmatrix} 0 & \frac{1}{2} \\ \frac{1}{2} & 0 \end{bmatrix}$$ 7. **Verify inverse application:** $$T^{-1} (T A) = A$$ --- **Final answers:** - Rotation matrix: $$\begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix}$$ - Scale matrix: $$\begin{bmatrix} 2 & 0 \\ 0 & 2 \end{bmatrix}$$ - Reflection matrix: $$\begin{bmatrix} -1 & 0 \\ 0 & 1 \end{bmatrix}$$ - Combined transformation matrix: $$\begin{bmatrix} 0 & 2 \\ 2 & 0 \end{bmatrix}$$ - Transformed image matrix: $$\begin{bmatrix} 6 & 8 \\ 4 & 2 \end{bmatrix}$$ - Inverse matrix to undo transformation: $$\begin{bmatrix} 0 & \frac{1}{2} \\ \frac{1}{2} & 0 \end{bmatrix}$$