Exercise 3.2.11. a) Given the line through the origin and find the matrix
that projects onto this line, as well as the matrix
that projects onto the line perpendicular to the original line.
b) What is ? What is
? Explain your answers.
Answer: a) We have
We next find the perpendicular line. If this line passes through the origin and then we will have
orthogonal to
so that
. One vector satisfying this condition is
. We then have
b) Taking the product of the two projection matrices first, we have
This true because multiplying a vector by projects it onto the line through
, and multiplying by
projects the resulting vector onto the line through
. But because
is perpendicular to
in multiplying by
all points on the line through
get projected onto the origin. The effect of multiplying by the product matrix
is thus the same as multiplying by zero. (Note also that
for the same reason.)
Taking the sum of the two projection matrices, we have
In other words, multiplying a vector by the sum of the two projection matrices results in the same vector:
In effect we have transformed the vector into two perpendicular component vectors: one component
on the line through
and a second component
on the perpendicular line through
. Adding the components back together reconstitutes the original vector.
UPDATE: Corrected the calculations above to include the factors and
when calculating the projection matrices. Thanks go to Trystyn for catching my original error.
NOTE: This continues a series of posts containing worked out exercises from the (out of print) book Linear Algebra and Its Applications, Third Edition by Gilbert Strang.
If you find these posts useful I encourage you to also check out the more current Linear Algebra and Its Applications, Fourth Edition, Dr Strang’s introductory textbook Introduction to Linear Algebra, Fourth Edition
and the accompanying free online course, and Dr Strang’s other books
.
This is wrong.
P = [a a^T] / [a^T a]
not just [a a^T]
Trystyn: You are correct, thanks for finding this error! I’ve updated the post to reflect your correction.