In Chapter 2.3, we broke a vector in into two perpendicular components. Let’s extend that idea to . First, we’ll break a vector into a component along a line and a component in a plane perpendicular to that line. Then, we’ll use three perpendicular directions to describe the vector using an orthonormal basis.
Recalling projections in ℝ²¶
Let , where is nonzero. Given a vector in , we want to write
where lies on and lies on , the line perpendicular to through the origin.
Since lies on , we can write for some scalar . The remaining vector is . To make it perpendicular to , we need
Solving for gives
Therefore,
Notice that does not need to have length one. We only need , so that the denominator is nonzero.
Projecting onto a line and a plane in ℝ³¶
In , the vectors perpendicular to a line through the origin form a plane through the origin. Let and let . Equivalently, : the vectors perpendicular to every vector in form the line .
We again want to write , but now lies on and lies in . The derivation above still works! It only uses dot products, so adding a third coordinate does not change the argument.
The blue component lies on , and the orange component lies in . Together, they add to . Drag to rotate the picture.
If is a nonzero normal vector to , we can first find the component along , then subtract it from .
Why does the second component lie in ? Recall from Chapter 2.5 that consists of the vectors whose dot product with its normal is zero. Our choice of ensures exactly that:
Example: Projecting onto a plane¶
Let
Find the projections of onto and onto .
The coefficients in the equation of give us a normal vector:
We compute
So the projection onto the line is
Subtracting this from gives the projection onto the plane:
Let’s check that lies in by substituting its coordinates into the plane’s equation:
Also, is a multiple of the normal vector, so it is perpendicular to .
Orthonormal bases in ℝ³¶
So far, we have broken a vector into a component along a line and a component in a plane. Can we break the plane component into two perpendicular components as well?
Choose two perpendicular lines through the origin in . Both are perpendicular to , so we now have three mutually perpendicular lines. Choosing a unit vector along each line gives three perpendicular unit directions. These play the same role as the two vectors in an orthonormal basis of from Chapter 2.2.
“Pairwise orthogonal” means that each pair of distinct vectors is orthogonal. We need to check all three dot products.
Every vector in can be written uniquely as a linear combination of these three directions. Geometrically, we can first project onto the line along and its perpendicular plane, then split the plane component along and .
Example: The standard basis¶
The standard basis vectors
form an orthonormal basis. Each has length one, and every pair has dot product zero. For example,
Example: A different orthonormal basis¶
Consider
First, check their lengths:
Next, check all three dot products:
All three vectors have length one and are pairwise orthogonal, so they form an orthonormal basis of .
Finding coefficients using dot products¶
Let be an orthonormal basis. We can write a vector as
How do we find , , and ? As in , taking a dot product isolates one coefficient at a time. Taking the dot product with gives
The first dot product is 1 because is a unit vector. The other two are 0 because the vectors are orthogonal. Taking dot products with and similarly gives and .
Each term is the projection of onto the line . The denominator in the projection formula is . The coefficient is a scalar; multiplying it by gives the corresponding vector component.
Example: Writing a vector in the new basis¶
Use the orthonormal basis from the previous example:
Let . Its coefficients are
Therefore,
We can check this by carrying out the linear combination in standard coordinates:
The coordinates in this basis are , while the standard coordinates are . These are two descriptions of the same vector. The negative coefficient -6 means that the second component points opposite to .
The components , , and lie on three mutually perpendicular lines. The dashed copies show how they add to . Drag to rotate the picture.
Application: Forces on a drone¶
The usual -, -, and -directions describe a force using fixed, global coordinates. For a moving drone, it can be more useful to describe the same force using the drone’s forward, rightward, and upward directions. If these directions form an orthonormal basis, three dot products tell us how much force acts along each one.