The document discusses projections onto subspaces. It provides examples of projecting vectors onto lines and subspaces. For projecting a vector v onto a line defined by a vector u, it shows that the projection matrix is P=uuT/uTu. It also shows how to project vectors onto subspaces defined by matrices and how to decompose a vector into components within and orthogonal to a subspace.
1. Projector And Projection Onto Subspaces
Numerical Linear Algebra
Isaac Amornortey Yowetu
NIMS-GHANA
July 20, 2020
2. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Outline
1 problem of the Day
2 Projection onto a Line
3 Projection Matrix
4 Projection onto Subspace
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
3. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Problem of the Day
Consider the matrix
A =
1 0
0 1
1 0
What is the orthogonal projection onto the range(A) and what
is the image under P of the vector (1, 2, 3)∗
?
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
4. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Graphical Example
Figure: By Nicholas Longo
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
5. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Example 1
Let
v =
−2
3
and u =
−1
1
What is the orthogonal projector P onto range(u), and what is
the image under P of the vector (v) ?
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
6. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Solution
Projection Matrix
Here we would like to find a projection matrix P:
P = P2
and PT
= P
P =
uuT
uT u
proju(v) = Pv =
uuT
uT u
v
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
7. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Solution Continue...
P =
uuT
uT u
u · uT
=
−1
1
(−1 1) =
1 −1
−1 1
uT
· u = (−1 1)
−1
1
= 2
∴ P =
1
2
1 −1
−1 1
=
0.5 −0.5
−0.5 0.5
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
8. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
proju(v) = Pv =
0.5 −0.5
−0.5 0.5
−2
3
=
−2.5
2.5
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
9. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Problem of the Day
Consider the matrix
A =
1 0
0 1
1 0
What is the orthogonal projection onto the range(A) and what
is the image under P of the vector (1, 2, 3)∗
?
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
10. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Solution
Projection Matrix
Here we would like to find a projection matrix P:
P = P2
and PT
= P
P =
uuT
uT u
But considering u to be matrix A, then:
projA(v) = Pv =
AAT
AT A
v
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
11. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Solution Continue...
Remark
But we don’t divide matrices. Hence, we will then have
inverse instead of matrix division.
We can consider multiplying the matrix A by the
pseudo-inverse to get matrix P.
Pseudo-inverse = (AT
A)−1
AT
Then,
P = A(AT
A)−1
AT
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
12. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Solution Continue...
AT
A =
1 0 1
0 1 0
1 0
0 1
1 0
=
2 0
0 1
(AT
A)−1
=
0.5 0
0 1
(AT
A)−1
AT
=
0.5 0
0 1
1 0 1
0 1 0
=
0.5 0 0.5
0 1 0
A(AT
A)−1
AT
=
1 0
0 1
1 0
0.5 0 0.5
0 1 0
=
0.5 0 0.5
0 1 0
0.5 0 0.5
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
13. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Considering
P =
0.5 0 0.5
0 1 0
0.5 0 0.5
and
1
2
3
Then,
Pv =
0.5 0 0.5
0 1 0
0.5 0 0.5
1
2
3
=
2
2
2
Conclusion: P is our orthogonal Projection onto Range(A) and
(2, 2, 2)T
is the image under P of the vector(v).
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
14. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Example 2
Let A be the 2-dimensional subspace of R3
spanned by the
orthogonal vectors u1 = (1, 0, 1) and u2 = (0, 1, 0). Write the
vector v = (1, 2, 3) as the sum of vector in A and a vector
orthogonal to A.
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
15. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Solution
Let
x = proju1 v + proju2 v (1)
x = λu1 + βu2 (2)
x =
u1 · v
u1 · u1
u1 +
u2 · v
u2 · u2
u2 (3)
x =
1
0
1
·
1
2
3
1
0
1
·
1
0
1
1
0
1
+
0
1
0
·
1
2
3
0
1
0
·
0
1
0
0
1
0
(4)
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces
16. problem of the Day Projection onto a Line Projection Matrix Projection onto Subspace
Solution Continue...
x = 2
1
0
1
+ 2
0
1
0
=
2
2
2
(5)
v ⊥ A =
1
2
3
−
2
2
2
=
−1
0
1
(6)
Conclusion: Vector x is our sum of vector v in A and (v ⊥ A)
is vector orthogonal to A.
Isaac Amornortey Yowetu NIMS-GHANA
Projector And Projection Onto Subspaces