LINEAR-ALGEBRA ยท Unit 16 ยท Video 2 ยท Interactive Practice

No Inverses Needed: How Orthonormal Bases Turn Projections into Dot Products

IKey Formulas

Formula Name When to Use
P=A(ATA)โˆ’1ATP = A(A^TA)^{-1}A^T General projection matrix Any basis โ€” requires matrix inversion
P=QQTP = QQ^T Orthonormal projection matrix When columns of QQ are orthonormal
x^i=qiTb\hat{x}_i = q_i^T b Coefficient as dot product Finding each least-squares coefficient
QTQ=IQ^TQ = I Orthonormality condition Columns are unit-length and mutually perpendicular

IIVisualization 1 โ€” When QTQ=IQ^TQ = I

QQ has orthonormal columns exactly when QTQ=IQ^TQ = I: unit-length columns on the diagonal, perpendicular columns off it.

๐Ÿ’ก The diagonal entries of QTQQ^TQ are the squared lengths โˆฅqiโˆฅ2\|q_i\|^2; the off-diagonal entry is the dot product q1โ‹…q2q_1 \cdot q_2. Identity demands unit length and perpendicularity together.

IIIVisualization 2 โ€” Projecting bb onto Col(Q)(Q)

With q1=12(1,1,0)Tq_1 = \tfrac{1}{\sqrt{2}}(1,1,0)^T, q2=(0,0,1)Tq_2 = (0,0,1)^T, the map p=QQTbp = QQ^Tb splits bb into an in-plane part pp and a perpendicular error e=bโˆ’pe = b - p.

๐Ÿ’ก pp is the closest point of the plane to bb โ€” which is exactly why ee leaves perpendicular. The coefficients x^1=q1Tb\hat{x}_1 = q_1^Tb and x^2=q2Tb\hat{x}_2 = q_2^Tb are plain dot products, no inverse needed.

IVVisualization 3 โ€” Every Coefficient Is a Dot Product

In the orthonormal basis q1=12(1,1)Tq_1 = \tfrac{1}{\sqrt{2}}(1,1)^T, q2=12(โˆ’1,1)Tq_2 = \tfrac{1}{\sqrt{2}}(-1,1)^T, each coordinate of bb is just a dot product: b=(q1Tb)โ€‰q1+(q2Tb)โ€‰q2b = (q_1^Tb)\,q_1 + (q_2^Tb)\,q_2.

๐Ÿ’ก A general basis would force you to solve ATAx^=ATbA^TA\hat{x} = A^Tb; orthonormality collapses that linear solve into two dot products โ€” the same idea that defines Fourier coefficients.

VQuiz Questions

Question 1

Given orthonormal column q1=(12,โ€…โ€Š12,โ€…โ€Š0)Tq_1 = \left(\frac{1}{\sqrt{2}},\; \frac{1}{\sqrt{2}},\; 0\right)^T and vector b=(1,2,3)Tb = (1, 2, 3)^T, compute the coefficient x^1=q1Tb\hat{x}_1 = q_1^T b.

โœ… Correct! x^1=3/2โ‰ˆ2.121\hat{x}_1 = 3/\sqrt{2} \approx 2.121. Just one dot product!

โŒ Not quite. Compute q1Tbq_1^T b by multiplying corresponding entries and summing: 12โ‹…1+12โ‹…2+0โ‹…3\frac{1}{\sqrt{2}} \cdot 1 + \frac{1}{\sqrt{2}} \cdot 2 + 0 \cdot 3.

Show solution

Solution:

x^1=q1Tb=12(1)+12(2)+0โ‹…(3)=12+22=32โ‰ˆ2.121\hat{x}_1 = q_1^T b = \frac{1}{\sqrt{2}}(1) + \frac{1}{\sqrt{2}}(2) + 0 \cdot (3) = \frac{1}{\sqrt{2}} + \frac{2}{\sqrt{2}} = \frac{3}{\sqrt{2}} \approx 2.121

The third component of q1q_1 is 0, so the third component of bb doesn't contribute. Each coefficient is just a dot product โ€” no system of equations to solve!

Question 2

True or False: If QQ is a 5ร—35 \times 3 matrix with orthonormal columns, then QQT=I5QQ^T = I_5 (the 5ร—55 \times 5 identity matrix).

โœ… Correct! QTQ=I3Q^TQ = I_3 always holds for orthonormal columns, but QQTQQ^T is only a projection matrix onto Col(Q)(Q) โ€” it equals II only when QQ is square.

โŒ Not quite. Think carefully: QTQ=IQ^TQ = I (small identity) always holds, but does QQT=IQQ^T = I (big identity) follow when QQ has fewer columns than rows?

Show solution

Solution: False.

When QQ is 5ร—35 \times 3 with orthonormal columns:

  • QTQ=I3Q^TQ = I_3 โœ… (the 3ร—33 \times 3 identity โ€” this always holds for orthonormal columns)
  • QQTโ‰ I5QQ^T \neq I_5 โŒ (this is a 5ร—55 \times 5 projection matrix onto the 3D column space, not the identity)

QQT=IQQ^T = I only when QQ is square (nร—nn \times n), meaning the columns span the entire space Rn\mathbb{R}^n. In that case QQ is called an orthogonal matrix and QT=Qโˆ’1Q^T = Q^{-1}.

Key distinction to remember:

  • QTQ=IQ^TQ = I โ†’ always true for orthonormal columns
  • QQT=IQQ^T = I โ†’ only when QQ is square

Question 3

Let QQ be the 3ร—23 \times 2 matrix with orthonormal columns q1=12(1,โ€…โ€Š1,โ€…โ€Š0)Tq_1 = \frac{1}{\sqrt{2}}(1,\; 1,\; 0)^T and q2=(0,โ€…โ€Š0,โ€…โ€Š1)Tq_2 = (0,\; 0,\; 1)^T.

Compute the projection p=QQTbp = QQ^T b for b=(4,0,6)Tb = (4, 0, 6)^T.

โœ… Correct! The projection keeps the q2q_2 component (z = 6) and averages the first two entries via q1q_1: both become 2.

โŒ Not quite.

Show solution

Solution:

Step 1 โ€” Coefficients as dot products:

x^1=q1Tb=12(4)+12(0)+0(6)=42=22\hat{x}_1 = q_1^T b = \frac{1}{\sqrt{2}}(4) + \frac{1}{\sqrt{2}}(0) + 0(6) = \frac{4}{\sqrt{2}} = 2\sqrt{2}

x^2=q2Tb=0(4)+0(0)+1(6)=6\hat{x}_2 = q_2^T b = 0(4) + 0(0) + 1(6) = 6

Step 2 โ€” Reconstruct the projection:

p=x^1q1+x^2q2=22โ‹…12(110)+6(001)=(220)+(006)=(226)p = \hat{x}_1 q_1 + \hat{x}_2 q_2 = 2\sqrt{2} \cdot \frac{1}{\sqrt{2}}\begin{pmatrix}1\\1\\0\end{pmatrix} + 6\begin{pmatrix}0\\0\\1\end{pmatrix} = \begin{pmatrix}2\\2\\0\end{pmatrix} + \begin{pmatrix}0\\0\\6\end{pmatrix} = \begin{pmatrix}2\\2\\6\end{pmatrix}

Interpretation: The projection averages the first two components of bb (since q1q_1 equally weights xx and yy) and keeps the zz-component unchanged (since q2q_2 is the zz-axis).

Question 4

The projection formula simplifies from P=A(ATA)โˆ’1ATP = A(A^TA)^{-1}A^T to P=QQTP = QQ^T when AA is replaced by an orthonormal matrix QQ. What is the key algebraic fact that makes this simplification โ€” and also makes PP idempotent (P2=PP^2 = P)?

โœ… Correct! The single fact QTQ=IQ^TQ = I drives every simplification: the inverse disappears, and the middle factors collapse in the idempotence proof.

โŒ Not quite. Think about what happens when you substitute QTQ=IQ^TQ = I into the formula P=Q(QTQ)โˆ’1QTP = Q(Q^TQ)^{-1}Q^T. What also happens when you compute P2=(QQT)(QQT)P^2 = (QQ^T)(QQ^T)?

Show solution

Solution: The key fact is QTQ=IQ^TQ = I.

For the formula simplification:

P=Q(QTQ)โˆ’1โŸ=Iโˆ’1=IQT=Qโ‹…Iโ‹…QT=QQTP = Q\underbrace{(Q^TQ)^{-1}}_{= I^{-1} = I}Q^T = Q \cdot I \cdot Q^T = QQ^T

For idempotence (P2=PP^2 = P):

P2=(QQT)(QQT)=Q(QTQ)โŸ=IQT=Qโ‹…Iโ‹…QT=QQT=PP^2 = (QQ^T)(QQ^T) = Q\underbrace{(Q^TQ)}_{= I}Q^T = Q \cdot I \cdot Q^T = QQ^T = P

The same fact โ€” QTQQ^TQ collapsing to II โ€” is the engine behind both simplifications. In the idempotence proof, QTQQ^TQ appears sandwiched in the middle and collapses, which is the "algebraic magic moment."

Why the other options are wrong:

  • QQ doesn't need to be square (the 3ร—23 \times 2 example works perfectly).
  • QT=Qโˆ’1Q^T = Q^{-1} only holds when QQ is square (orthogonal matrix), not for rectangular QQ.
  • General projection matrices do require inverses; it's specifically orthonormality that eliminates the inverse.

Solved: 0 / 4