In various ways, you are likely to be familiar with the concept of projection. You could have encountered it in geography class or through work connected with graphics, or maybe in therapy sessions. Or you could have come across it in philosophy readings or sci-fi movies. Usually, this term is associated with transferring certain properties of one object to another or carrying a certain image between two different spaces. Interestingly, this intuitive idea also holds in mathematics, where projections are used in different fields. In this discussion, you will focus on projections of vectors, which are related to the concept of orthogonality and offer a compelling geometric interpretation.
Some may perceive the outline of projections as somewhat simplistic or not immediately applicable. However, it's crucial to recognize that vector projections are an immensely valuable tool for fundamental constructions in linear algebra. Their significance should not be underestimated.
A helpful visual intuition
Imagine a light source sending a broad, parallel beam of light perpendicular to a straight line. In this scenario, a projection of a vector onto this line can be visualized as its shadow (see the picture).
Although this representation is not the most precise definition of a projection, it does provide some valuable insights. For instance, when a vector lies on the line, its projection coincides with the vector itself. This represents the maximum length a projection can achieve, as in any other case, a vector will have a greater magnitude than its projection.
A geometric definition
Let’s now give a precise geometric definition of a projection, which does not use these physical entities. Up until now, we were discussing a projection of a vector onto a line, however, it turns out to be more natural to define a projection of a vector onto another vector.
Consider two vectors and :
Then draw a line on which the vector lies:
After that, draw a perpendicular from the and of vector to this line:
A projection of onto is a vector directed from the beginning of the vector to the intersection of the line on which lies and the constructed perpendicular (the red vector in the following picture)
The gray arrows show how this definition is connected with the ‘shadow’ construction.
It is understandable, that this particular geometric concept could look quite contrived, but trust us, it is not. Knowing projections of a vector onto some given set of vectors could be very useful, especially if you choose these last to be a basis.
An abstract point of view
The essence of linear algebra lies in the ability to describe a wide range of geometric objects through the use of linear equations and algebraic concepts. This approach allows us to work with complex geometric images without necessarily visualizing them. Additionally, integrating linear algebra into programming problems becomes more manageable as you work with variables, which aligns much more naturally with machine computing rather than pictures. Therefore, in this context, you will define a projection using the notion of an inner product for abstract Euclidean spaces.
Consider a Euclidean space with inner product . Summarizing everything that was said about projections up until this place, we can say that a projection of a vector onto a vector is a vector of length , where is an angle between and . Notice that it means that the projection of a vector can not be longer than vector itself. The projection is lying on the same line with and it is directed in the same way as if and in the opposite way if . Here are the pictures describing these two situations:
In the left one and in the right one . The vector is a unit (length one) vector codirected with , therefore
All in all, you can write the following, as
Now let’s rewrite it in terms of the inner product:
Or finally
This is the most general definition of a projection of onto in a generic Euclidean space.
Numeric example
Consider a plane as a Euclidean space with a standard dot product as an inner product. Let’s find a projection of onto :
This calculation is illustrated higher; a projection vector is given in red, you can check using the squared greed, that it is indeed .
Note that if the angle between two vectors is , their dot product is , therefore a projection of each of these vectors onto another is a zero vector. If this angle is equal to or the protection is equal to a projected vector.
Conclusion
These are some facts for you to take away
- A projection of a vector onto a vector in a Euclidean space with an inner product is a vector
- If is colinear to then ;
- If is orthogonal to then ;
- The geometrical purpose of is, in some sense, to show the degree of alignment of vector with ;
- Or it could be thought of as a ‘shadow’ of on line vector lies at.