(2 pontos) Seja a matriz A=Q R, com A e Q dados abaixo. Temos que Q e R são dados pela chamdada fatoração QR.
a) A é uma matriz ortogonal? Explique.
b) Encontre a matriz triangular superior R;
c) Resolva a equação A \boldsymbol{x}=\boldsymbol{y} por mínimos quadrados, onde \boldsymbol{y} também é dado abaixo, utilizando a matriz \mathbf{R}.
A=\left[\begin{array}{rr} 2 & 0 \\\\ 4 & 4 \\\\ -1 & 0 \\\\ -2 & 2 \end{array}\right] \quad Q=\frac{1}{5}\left[\begin{array}{rr} -2 & -4 \\\\ 4 & 2 \\\\ -1 & 2 \\\\ -2 & -1 \end{array}\right] ; \boldsymbol{y}=\left[\begin{array}{r} 1 \\\\ 3 \\\\ -1 \\\\ 2 \end{array}\right]

Resposta

Temos que A=Q R, com Q uma matriz ortonormal e R uma matriz triangular superior.
a) Temos que:
\begin{aligned} R & =Q^{T} A \\\ & =\frac{1}{5}\left[\begin{array}{llrr} -2 & 4 & -1 & -2 \\\\ -4 & 2 & 2 & -1 \end{array}\right]\left[\begin{array}{rr} 2 & 0 \\\\ 4 & 4 \\\\ -1 & 0 \\\\ -2 & 2 \end{array}\right] \\\ & =\left[\begin{array}{ll} 5 & 4 \\\\ 0 & 2 \end{array}\right] \end{aligned}
b) Temos que:
\begin{aligned} \boldsymbol{x} & =R^{-1} Q^{T} \boldsymbol{y} \\\ & =\frac{1}{10}\left[\begin{array}{rr} 2 & -4 \\\\ 0 & 5 \end{array}\right] \frac{1}{5}\left[\begin{array}{llrr} -2 & 4 & -1 & -2 \\\\ -4 & 2 & 2 & -1 \end{array}\right]\left[\begin{array}{r} 1 \\\\ 3 \\\\ -1 \\\\ 2 \end{array}\right] \\\ & =\frac{1}{5}\left[\begin{array}{r} 3 \\\\ -1 \end{array}\right]=\left[\begin{array}{r} 0.6 \\\\ -0.2 \end{array}\right] \end{aligned}

Passo 1

O enunciado nos dá uma matriz A\in\mathbb{R}^{4\times2} que se escreve como fatoração QR, isto é,
A = Q\,R,
onde Q\in\mathbb{R}^{4\times2} tem colunas ortonormais e R\in\mathbb{R}^{2\times2} é triangular superior. Precisamos:
a) verificar se A é ortogonal;
b) determinar R via Q^{T}A;
c) resolver por mínimos quadrados A\,\boldsymbol{x}=\boldsymbol{y} usando R.

Passo 2

Para ser ortogonal, uma matriz quadrada M deve satisfazer M^{T}M=I. Aqui A é 4\times2, não é quadrada, e de fato
A^{T}A =\begin{pmatrix} 2 & 4 & -1 & -2\\\\ 0 & 4 & 0 & 2 \end{pmatrix} \begin{pmatrix} 2 & 0\\\ 4 & 4\\\ -1 & 0\\\ -2 & 2 \end{pmatrix} =\begin{pmatrix} 25 & 12\\\\ 12 & 20 \end{pmatrix}\neq I_{2}.
Portanto A não é ortogonal.

Passo 3

Para achar R, usamos
R = Q^{T}A.
Como
Q = \frac{1}{5}\begin{pmatrix} -2 & -4\\\\ 4 & 2\\\\ -1 & 2\\\\ -2 & -1 \end{pmatrix},
temos
Q^{T} =\frac{1}{5}\begin{pmatrix} -2 & 4 & -1 & -2\\\\ -4 & 2 & 2 & -1 \end{pmatrix},
logo
R =\frac{1}{5}\begin{pmatrix} -2 & 4 & -1 & -2\\\\ -4 & 2 & 2 & -1 \end{pmatrix} \begin{pmatrix} 2 & 0\\\ 4 & 4\\\ -1 & 0\\\ -2 & 2 \end{pmatrix} =\begin{pmatrix} 5 & 4\\\\ 0 & 2 \end{pmatrix}.

Passo 4

Para resolver os mínimos quadrados, sabemos que a solução é dada por
R\,\boldsymbol{x}=Q^{T}\boldsymbol{y}.
Primeiro calculamos
Q^{T}\boldsymbol{y} =\frac{1}{5}\begin{pmatrix} -2 & 4 & -1 & -2\\\\ -4 & 2 & 2 & -1 \end{pmatrix} \begin{pmatrix} 1\\\ 3\\\ -1\\\ 2 \end{pmatrix} =\frac{1}{5}\begin{pmatrix} 7\\\ -2 \end{pmatrix} =\begin{pmatrix} 7/5\\\ -2/5 \end{pmatrix}.
Agora resolvemos por substituição reversa em
\begin{pmatrix} 5 & 4\\\\ 0 & 2 \end{pmatrix} \begin{pmatrix} x_{1}\x_{2} \end{pmatrix} =\begin{pmatrix} 7/5\\\ -2/5 \end{pmatrix}.
Da segunda linha vem
2\,x_{2}=-\tfrac{2}{5} \quad\Longrightarrow\quad x_{2}=-\tfrac{1}{5},
e da primeira
5\,x_{1}+4\,\bigl(-\tfrac{1}{5}\bigr)=\tfrac{7}{5} \quad\Longrightarrow\quad 5\,x_{1}=\tfrac{7}{5}+ \tfrac{4}{5}=\tfrac{11}{5} \quad\Longrightarrow\quad x_{1}=\tfrac{11}{25}.

Resposta

a) A não é ortogonal, pois A^{T}A\neq I.
b) \displaystyle R=\begin{pmatrix}5&4\\\ 0&2\end{pmatrix}.
c) A solução por mínimos quadrados é
\boldsymbol{x} =\begin{pmatrix}11/25\\\ -1/5\end{pmatrix}.

Exercícios relacionados