Vector projection explained

The vector projection (also known as the vector component or vector resolution) of a vector on (or onto) a nonzero vector is the orthogonal projection of onto a straight line parallel to . The projection of onto is often written as

\operatorname{proj}ba

or .

The vector component or vector resolute of perpendicular to, sometimes also called the vector rejection of from (denoted

\operatorname{oproj}ba

or),[1] is the orthogonal projection of onto the plane (or, in general, hyperplane) that is orthogonal to . Since both

\operatorname{proj}ba

and

\operatorname{oproj}ba

are vectors, and their sum is equal to, the rejection of from is given by: \operatorname_ \mathbf = \mathbf - \operatorname_ \mathbf.

To simplify notation, this article defines

a1:=\operatorname{proj}ba

and

a2:=\operatorname{oproj}ba.

Thus, the vector

a1

is parallel to

b,

the vector

a2

is orthogonal to

b,

and

a=a1+a2.

The projection of onto can be decomposed into a direction and a scalar magnitude by writing it as

a1=a1\hatb

where

a1

is a scalar, called the scalar projection of onto, and is the unit vector in the direction of . The scalar projection is defined as[2] a_1 = \left\|\mathbf\right\|\cos\theta = \mathbf\cdot\mathbfwhere the operator denotes a dot product, ‖a‖ is the length of, and θ is the angle between and .The scalar projection is equal in absolute value to the length of the vector projection, with a minus sign if the direction of the projection is opposite to the direction of, that is, if the angle between the vectors is more than 90 degrees.

The vector projection can be calculated using the dot product of

a

and

b

as:\operatorname_ \mathbf = \left(\mathbf \cdot \mathbf\right) \mathbf = \frac \frac = \frac = \frac ~ .

Notation

This article uses the convention that vectors are denoted in a bold font (e.g.), and scalars are written in normal font (e.g. a1).

The dot product of vectors and is written as

ab

, the norm of is written ‖a‖, the angle between and is denoted θ.

Definitions based on angle θ

Scalar projection

See main article: Scalar projection. The scalar projection of on is a scalar equal to a_1 = \left\|\mathbf\right\| \cos \theta, where θ is the angle between and .

A scalar projection can be used as a scale factor to compute the corresponding vector projection.

Vector projection

The vector projection of on is a vector whose magnitude is the scalar projection of on with the same direction as . Namely, it is defined as\mathbf_1 = a_1 \mathbf = (\left\|\mathbf\right\| \cos \theta) \mathbfwhere

a1

is the corresponding scalar projection, as defined above, and

\hatb

is the unit vector with the same direction as :\mathbf = \frac

Vector rejection

By definition, the vector rejection of on is:\mathbf_2 = \mathbf - \mathbf_1

Hence,\mathbf_2 = \mathbf - \left(\left\|\mathbf\right\| \cos \theta\right) \mathbf

Definitions in terms of a and b

When is not known, the cosine of can be computed in terms of and, by the following property of the dot product \mathbf \cdot \mathbf = \left\|\mathbf\right\| \left\|\mathbf\right\| \cos \theta

Scalar projection

By the above-mentioned property of the dot product, the definition of the scalar projection becomes:a_1 = \left\|\mathbf\right\| \cos \theta = \frac .

In two dimensions, this becomesa_1 = \frac .

Vector projection

Similarly, the definition of the vector projection of onto becomes:\mathbf_1 = a_1 \mathbf = \frac \frac,which is equivalent to either\mathbf_1 = \left(\mathbf \cdot \mathbf\right) \mathbf,or[3] \mathbf_1 = \frac = \frac ~ .

Scalar rejection

In two dimensions, the scalar rejection is equivalent to the projection of onto

b\perp=\begin{pmatrix}-by&bx\end{pmatrix}

, which is

b=\begin{pmatrix}bx&by\end{pmatrix}

rotated 90° to the left. Hence,a_2 = \left\|\mathbf\right\| \sin \theta = \frac = \frac .

Such a dot product is called the "perp dot product."[4]

Vector rejection

By definition,\mathbf_2 = \mathbf - \mathbf_1

Hence,\mathbf_2 = \mathbf - \frac .

By using the Scalar rejection using the perp dot product this gives

\mathbf_2 = \frac\mathbf^\perp

Properties

Scalar projection

See main article: Scalar projection. The scalar projection on is a scalar which has a negative sign if 90 degrees < θ ≤ 180 degrees. It coincides with the length of the vector projection if the angle is smaller than 90°. More exactly:

Vector projection

The vector projection of on is a vector which is either null or parallel to . More exactly:

Vector rejection

The vector rejection of on is a vector which is either null or orthogonal to . More exactly:

Matrix representation

The orthogonal projection can be represented by a projection matrix. To project a vector onto the unit vector, it would need to be multiplied with this projection matrix:P_\mathbf = \mathbf \mathbf^\textsf = \begin a_x \\ a_y \\ a_z \end \begin a_x & a_y & a_z \end = \begin a_x^2 & a_x a_y & a_x a_z \\ a_x a_y & a_y^2 & a_y a_z \\ a_x a_z & a_y a_z & a_z^2 \\ \end

Uses

The vector projection is an important operation in the Gram–Schmidt orthonormalization of vector space bases. It is also used in the separating axis theorem to detect whether two convex shapes intersect.

Generalizations

Since the notions of vector length and angle between vectors can be generalized to any n-dimensional inner product space, this is also true for the notions of orthogonal projection of a vector, projection of a vector onto another, and rejection of a vector from another.

In some cases, the inner product coincides with the dot product. Whenever they don't coincide, the inner product is used instead of the dot product in the formal definitions of projection and rejection. For a three-dimensional inner product space, the notions of projection of a vector onto another and rejection of a vector from another can be generalized to the notions of projection of a vector onto a plane, and rejection of a vector from a plane.[5] The projection of a vector on a plane is its orthogonal projection on that plane. The rejection of a vector from a plane is its orthogonal projection on a straight line which is orthogonal to that plane. Both are vectors. The first is parallel to the plane, the second is orthogonal.

For a given vector and plane, the sum of projection and rejection is equal to the original vector. Similarly, for inner product spaces with more than three dimensions, the notions of projection onto a vector and rejection from a vector can be generalized to the notions of projection onto a hyperplane, and rejection from a hyperplane. In geometric algebra, they can be further generalized to the notions of projection and rejection of a general multivector onto/from any invertible k-blade.

See also

External links

Notes and References

  1. Book: Perwass, G. . 2009 . Geometric Algebra With Applications in Engineering . 83 . 9783540890676 .
  2. Web site: Scalar and Vector Projections. 2020-09-07. www.ck12.org.
  3. Web site: Dot Products and Projections.
  4. Book: Hill . F. S. Jr. . Graphics Gems IV . 1994 . Academic Press . San Diego . 138–148.
  5. M.J. Baker, 2012. Projection of a vector onto a plane. Published on www.euclideanspace.com.