Vector Projection

Parallel Projection

The perpendicular projection of a vector $\vec{u}$ onto another vector $\vec{v}$ gives us a vector that is parallel to the vector $\vec{v}$ whose length how far the vector $\vec{u}$ extends in the direction on $\vec{v}$. This is illustrated below.

parallelprojection1.jpg

Now let us develop the formula for the parallel projection. We know that the result will be parallel to $\vec{v}$. We just need to figure out the magnitude. For that we can use right triangle trigonometry. Using the following picture as a guide,

parallelprojectiondevelopment.jpg
(1)
\begin{eqnarray} \cos \theta =\frac{|\mbox{Proj}_\vec{v} \vec{u}|}{|\vec{u}|}\\ |\mbox{Proj}_\vec{v} \vec{u}|=|\vec{u}|\cos \theta\\ |\mbox{Proj}_\vec{v} \vec{u}|=|\vec{u}|\frac{\vec{u} \cdot \vec{v}}{|\vec{u}\|\vec{v}|}\\ |\mbox{Proj}_\vec{v} \vec{u}|=\frac{\vec{u} \cdot \vec{v}}{|\vec{v}|}\\ \end{eqnarray}

Now if we combine this fact, with our previous knowledge that it should be parallel to $\vec{v}$. We have,

(2)
\begin{align} \mbox{Proj}_\vec{v} \vec{u}=\frac{\vec{u} \cdot \vec{v}}{|\vec{v}|^2}\vec{v}\\ \end{align}

Example
Find the parallel projection of $<3,5,-2>$ onto $<4,0,1>$

Perpendicular Projection

Where as the parallel projection gave us a vector parallel to the onto vector, the perpendicular gives us a vector perpendicular to the onto vector. This perpendicular projection with have magnitude that corresponds to the amount $\vec{u}$ extends in the direction perpendicular to $\vec{v}$

perpendicularprojection.jpg

It is rather straightforward to get the perpendicular projection from the parallel projection by means of vector addition as follows.

(3)
\begin{align} \mbox{Proj}_\vec{v} \vec{u} + \bot \mbox{Proj} _\vec{v} \vec{u} = \vec{u}\\ \bot \mbox{Proj} _\vec{v} \vec{u} = \vec{u}-\mbox{Proj}_\vec{v} \vec{u} \end{align}

Example
Find the perpendicular projection of $<3,5,-2>$ onto $<4,0,1>$

Closest Points

The use of vector projection can greatly simplify the process of finding the closest point on a line or a plane from a given point. We will look at two approaches. The first approach makes use of the direction normal to the object in question. This will include lines in 2D and planes in 3D. The second approach uses the direction parallel to the object, which is applicable to lines in 3D.

Lines in 2D and Planes in 3D

In these problems we will have some point in 2D or 3D that we will call $Q$ and either a line in 2D line or a plane in 3D. Both of these objects can be described in terms of a point on the object $P$ and a direction normal to the object. We will represent the normal direction by a vector $\vec{n}$. We will be trying to determine the closest point $S$ on the object from the point $Q$. From the illustration below, you see that the vector, $\vec{S}$, that points to the closest point $S$ is given by, $\vec{S}=\vec{Q}-\mbox{Proj}_{\vec{n}}\vec{PQ}$

closestpointnormal.jpg

If we were interested in the distance from the point $Q$ to the point $S$, we would only need to calculate $|\mbox{Proj}_{\vec{n}}\vec{PQ}|$

Example
Find the point on the plane $x+2y-3z=4$ that is closest to the point $(0,1,-1)$

Lines in 2D or 3D

In these problems we will have some point in 2D or 3D that we will call $Q$ and a line in either 2D or 3D . Both lines can be described in terms of a point on the line $P$ and a direction parallel to the line. We will represent the parallel direction by a vector $\vec{d}$. We will be trying to determine the closest point $S$ on the object from the point $Q$. From the illustration below, you see that the vector, $\vec{S}$, that points to the closest point $S$ is given by, $\vec{S}=\vec{P}+\mbox{Proj}_{\vec{d}}\vec{PQ}$

closestpointparallel.jpg

If we were interested in the distance from the point $Q$ to the point $S$, we would only need to calculate $|\vec{Q} - \vec{S}|$

Example
Find the point on the line $<1+t,4-3t,2t>$ that is closest to the point $(5,6,7)$

Exercises

  1. Find the parallel projection of $\vec{u}=<1,4,-2>$ onto the vector $\vec{v}=<0,3,5>$
  2. Find the perpendicular projection of $\vec{u}=<1,4,-2>$ onto the vector $\vec{v}=<0,3,5>$
  3. Write $\vec{u}=<1,4,-2>$ as the sum of a vector parallel and a vector perpendicular to $\vec{v}=<0,3,5>$
  4. Under what conditions would $\mbox{Proj} _\vec{v} \vec{u} =\vec{0}$
  5. Find the point on the line passing through (1,4,-8) and (3,2,1) that is closest to the point (0,0,0). Also give the distance from the point to the line.
  6. Find the point on the plane $x+y-z=2$ closest to the point (1,4,0). Also give the distance from the point to the plane.
  7. Why can't we use the method of involving the normal direction when finding the point closest to a line in 3D?
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License