Section 2.7 Dot Products
There are two distinct ways to multiply vectors together. The first, which will be discussed here, is called the dot product or scalar product,because the result is a scalar value. The second, called the cross product, will be discussed in Section 2.8 below.
Dot products are used to compute the angle between vectors and to determine the project of one vector onto another. The projection represents the portion of the first vector which is parallel to second vector.
The dot product of two vectors \(\vec{A}\) and \(\vec{B}\) is defined as the sum of the product of the vector components in each coordinate direction. For three-dimensional vectors \(\vec{A}\) and \(\vec{B}\text{,}\)
For two-dimensional vectors, the \(z\) components and the \(A_z B_z\) term of the dot product are zero.
Dot products are commutative, associative and distributive:
-
Commutative. The order does not matter
\begin{equation} \vec{A}\cdot\vec{B} = \vec{B}\cdot\vec{A}\tag{2.7.2} \end{equation} -
Associative. It does not matter whether you multiply a scalar value a by the final dot product, or either of the individual vectors, you will still get the same answer.\begin{equation} a\left( \vec{A}\cdot\vec{B} \right ) = a\vec{A}\cdot\vec{B}= \vec{A}\cdot a\vec{B}\tag{2.7.3} \end{equation}
-
Distributive. If you are dotting one vector \(\vec{A}\) with the sum of two more \((\vec{B}+\vec{C})\text{,}\) you can either add \(\vec{B}+\vec{C}\) first, or dot \(\vec{A}\) by both and add the final value.\begin{equation} \vec{A}\cdot\left( \vec{B} + \vec{C} \right ) = \vec{A}\cdot\vec{B}+ \vec{A}\cdot \vec{C}\tag{2.7.4} \end{equation}
Subsection 2.7.1 Dot Products and Magnitude
Dot products can be used to find vector magnitudes. When a vector is dotted with itself, the result is the square of the magnitude of the vector. Consider the two dimensional vector \(\vec{A} = \langle A_x, A_y \rangle\text{.}\) Applying equation (2.7.1), and recognizing the form of the the Pythagorean Theorem, we see
Example 2.7.1. Find vector magnitude using dot product.
Find the magnitude of vector \(\vec{F}\) with components \(F_x = \N{30}\) and \(F_y=\N{-40}\)
Subsection 2.7.2 Angle between two vectors
An alternate, equivalent method to find the dot product of two vectors is
In this equation \(\theta\) in the equation is the angle between between the two vectors.
Subsubsection Computation of a Dot Product Using Vector Components
The dot product is used to find the projection of one vector onto another or the angle between two vectors. Let us go back to our example of the two cables in the interactive in Figure 2.6.1. If you would like to compute the portion of of tension in cable \(A\) which is pulling in the same direction as cable \(B\text{,}\) known as the projection of \(\vec{A}\) onto \(\vec{B}\) you could start with the dot product.
Coming back to our basic dot product equation, we can compute the dot products of unit vectors \(\ihat\) and \(\jhat\text{.}\) The dot product of \(\ihat\) and \(\ihat\) is:
As the length of \(\ihat\) is just 1, equation result is dependent on the \(\cos \theta\text{.}\) Of course, in this case \(\theta = \ang{0}\) and we know that the \(\cos \ang{0} = 1 \text{.}\)
Similarly, the orthogonal unit vectors \(\ihat\) and \(\jhat\) are \(\ang{90}\) apart so,
Hence, the dot product of parallel vectors is the product of their lengths, and the dot product of perpendicular vectors is zero. Thus, we can also write that a dot product is equal to the sum-product of the like components:
Subsection 2.7.3 Vector Projection
Now, let's look geometrically at the vector projections, by which we mean the rectangular component of one vector in the direction specified by another vector. In the interactive of Figure 2.7.1, the projection of the blue vector \(\vec{B}\) in the direction of the red vector \(\vec{A}\) is the black vector \(\vec{u}\text{.}\) If the vectors represent forces, the projection is also a force.
Interactive showing how a drawing a line perpendicular to \(\vec{B}\) to the tip of \(\vec{A}\) creates a right triangle with the interior angle \(\theta\text{.}\) You can change both vectors by dragging the orange ‘+’ marks.
Our goal is to find the amount of tension force \(\vec{A}\) which is parallel to tension force \(\vec{B}\text{.}\) We see that the adjacent side of our new right triangle can be shown to be equal to \(A \cos \theta\text{.}\) This appears to be the answer to our question, but how is it this value related to the dot product? It turns out that the dot product gives us a bit more than just \(A \cos \theta\text{.}\) Rearranging the right side of the basic dot product equation we can see that
So, the dot product of \(\vec{A}\) and \(\vec{B}\) gives us the projection of \(\vec{A}\) onto \(\vec{B}\) times the magnitude of \(\vec{B}\text{.}\) So, to find the scalar value of the projection of \(\vec{A}\) onto \(\vec{B}\) we write
While you might have learned the ‘calculus version’ if you have taken Calculus III there are simpler equivalent versions available. Rearranging (2.7.6) above, the projection of \(\vec{A}\) onto \(\vec{B}\) divided by the length of \(\vec{B}\text{.}\) This equation can be further simplified to the dot product of \(\vec{A}\) and the unit vector \(\hat{B}\text{.}\) As the unit vector \(\hat{B}\) has already been divided by the length of vector, \(\left \| \vec{B} \right \|\text{.}\)
Dot products always result in a scalar value: positive, negative, or zero. The spatial interpretation of the results of a dot product of \(\vec{A}\) and \(\vec{B}\) is:
One final modification you may need to perform is to find the vector projection of \(\vec{A}\) onto \(\vec{B}\text{,}\) as opposed to the scalar value which we solve for in equation (2.7.6) above. To project the scalar value onto \(\vec{B}\text{,}\) multiply the scalar projection you solve for above by the unit vector \(\hat{\vec{B}}\text{.}\) In reference to our earlier cable example, the vector projection of \(\vec{A}\) onto \(\vec{B}\) would be the tension components of cable \(\vec{A}\) which are parallel to cable \(\vec{B}\text{.}\)
Similar to equation (2.7.6) above, both the calculus version and the quick version are shown.
You can use this interactive as an example to test your computations and sketches by moving the slider to the left, changing the vectors, doing your computations, and then moving the slider to the right to check your work.
Subsection 2.7.4 Vector Magnitude vs. Scalar Value
The magnitude of a vector and the scalar result of a dot product may seem similar as they are both are numeric values which come from a vector or vectors. They are not the same, however. The key difference is that vector magnitudes are always positive or zero, while the scalar results of dot products are signed values which can be positive or negative.
Subsection 2.7.5 Dot Products and Projections
This section builds on the basics of dot products started in Section 2.7 earlier in this chapter. Recall that dot products find the amount of one vector parallel to another and are also useful to find the angle between two vectors.
Previously, we found that the dot product of the parallel unit vectors \(\ihat\) and \(\jhat\) was 1, while the dot product of the perpendicular unit vectors \(\ihat\) and £ was 0. We can expand this general relationship where the dot products of any two parallel unit vectors equal one and the dot product of any two perpendicular unit vectors is zero to demonstrate that
For three-dimensional vectors we can also write that a dot product is equal to the sum-product of the like components:
Just like we did for two-dimensional dot products, our goal is to find the amount of tension force \(\vec{F}_A\) which is parallel to tension force \(\vec{F}_B\text{.}\) In two-dimensional problems it can be straightforward to create a right triangle to resolve the projected length of \(\vec{F}_A\) onto \(\vec{F}_B\text{,}\) on three-dimensional problems you’ll need to rely on the dot product from Equation XX above. As shown in the equation below, the easiest way to find the magnitude of the projection of \(\vec{F}_A\) onto \(\vec{F}_B\) is by dotting \(\vec{F}_A\) with \(\hat{F_B}\text{.}\)
As mentioned earlier, dot products always result in a scalar value. Refer to List 2.7.3 help you to interpret the results of a dot product of \(\vec{F}_A\) and \(\vec{F}_B\text{.}\)
One final modification you may need to perform is to find the vector projection of \(\vec{F}_A\) onto \(\vec{F}_B\) (as opposed to the scalar value which we solve for in equation XX above). To project the scalar value onto \(\vec{F}_B\text{,}\) just multiply the scalar projection you solve for above by the unit vector \(\hat{B}\text{.}\) In reference to our earlier cable example, vector projection of \(\vec{F}_A\) onto \(\vec{F}_B\) would be the tension components of cable \(\vec{F}_A\text{,}\) which are parallel to cable \(\vec{F}_B\text{.}\)
Similar to equation XX above, both the calculus version and quick version are shown.
The final topic which can be a useful application of dot products is to find the vector portion of \(\vec{F}_A\) which is perpendicular to \(\vec{F}_B\text{.}\) Since we already have the vector portion of \(\vec{F}_A\) which is parallel to \(\vec{F}_B\) (which is the \(\proj_{\vec{F}_B}\vec{F}_A\)), we can use vector algebra to show the following:
If we rearrange this equation to solve for \(\vec{F_A \perp F_B}\text{,}\) we find that
Thus, we can use all of our efforts to compute the portion of \(\vec{F}_A\) to \(\vec{F}_B\) to quickly compute the vector portion of \(\vec{F}_A\) which is perpendicular to \(\vec{F}_B\text{.}\)
Subsection 2.7.6 Force Vectors from Position Vectors
When translating two-dimensional force vectors from the problem geometry, we were able to use right triangle trigonometry. However, translating three-dimensional force vectors from the problem geometry often requires the use of unit vectors. The process for resolving three-dimensional vector components of a force along a line is described step-by-step below.
-
Use the problem geometry to find the displacement vector from point \(A\) to point \(B, \vec{AB}\text{.}\) There are two approaches:
-
Subtract the coordinates of the starting point \(A\) from the coordinates of the destination point \(B\) to find the vector \(\vec{AB}\)
\begin{align*} A \amp=\left(A_x,A_y,A_z \right)\\ B \amp=\left(B_x,B_y,B_z \right)\\ \vec{AB}\amp =\left(B_x-A_x \right )\ihat+\left(B_y-A_y \right )\jhat+\left(B_z-A_z \right )\khat \end{align*} -
Write the displacements directly by noting the distance traveled in each coordinate direction when moving from \(A\) to \(B\text{.}\) This is really the same as the previous method.
\begin{align*} AB_x \amp = \Delta x = B_x - A_x\\ AB_y \amp = \Delta y = B_y - A_y\\ AB_z \amp = \Delta z = B_z - A_x\\ \vec{AB}\amp = \Delta x \ihat+ \Delta y \jhat+ \Delta z \khat \end{align*}
-
-
Find the distance between point \(A\) and point \(B\) using the Pythagorean Theorem. This distance is also the magnitude of \(\vec{AB}\) or \(|\vec{AB}|\)
\begin{equation*} \left|\vec{AB}\right |=\sqrt{(AB_x)^2+(AB_y)^2+(AB_z)^2}\text{.} \end{equation*} -
Find the unit vector from \(A\) to \(B\text{,}\) \(\widehat{\vec{AB}}\) by dividing vector \(\vec{AB}\) by its magnitude. This is a unitless vector with a magnitude of 1 which points from \(A\) to \(B\text{.}\)
\begin{equation*} \widehat{\vec{AB}}= \left \langle \frac{A_x}{|A|},\frac{A_y}{|A|},\frac{A_z}{|A|} \right \rangle \end{equation*} -
Multiply the magnitude of the force by the unit vector \(\widehat{AB}\) from \(A\) to \(B\) to get force \(\vec{F}_{AB}.\)
\begin{align*} \vec{F}_{AB} \amp = F_{AB} \; \widehat{\vec{AB}}\\ \amp = F_{AB} \left \langle \frac{A_x}{|\vec{A}|},\frac{A_y}{|\vec{A}|},\frac{A_z}{|\vec{A}|}\right \rangle \end{align*}
Example 2.7.2. Find a force in a specified direction.
Determine the components of a \(\kN{5}\) force \(\vec{F}\) acting at point \(A\text{,}\) in the direction of a line from \(A\) to \(B\text{.}\) Given: \(A =\m{ \left ( 2,3,-2.1 \right )}\) and \(B = \m{\left ( -2.5, 1.5, 2.2 \right )}\)
(a)
Draw a good diagram.
The interactive in Figure 2.7.6 may be useful for this problem.
(b)
Find the displacement vector from \(A\) to \(B\text{.}\)
(c)
Find the magnitude of the displacement vector.
(d)
Find the unit vector pointing from \(A\) to \(B\text{.}\)
(e)
Find the force vector.
Once you understand the process of creating a force vector from the problem geometry, try your own computations using the interactive below in Figure 2.7.6.