Skip to main content
Logo image

Coordinated Multivariable Calculus

Section 1.3 The Dot Product

In the last section, we considered vector addition and scalar multiplication and found that each operation had a natural geometric interpretation. In this section, we will introduce a means of multiplying vectors.

Preview Activity 1.3.1.

For two-dimensional vectors u=⟨u1,u2⟩ and v=⟨v1,v2⟩, the dot product is simply the scalar obtained by
uβ‹…v=u1v1+u2v2.
  1. If u=⟨3,4⟩ and v=βŸ¨βˆ’2,1⟩, find the dot product uβ‹…v.
  2. Find iβ‹…i and iβ‹…j.
  3. If u=⟨3,4⟩, find uβ‹…u. How is this related to |u|?
  4. On the axes in Figure 1.3.1, plot the vectors u=⟨1,3⟩ and v=βŸ¨βˆ’3,1⟩. Then, find uβ‹…v. What is the angle between these vectors?
    Figure 1.3.1. For part (d)
  5. On the axes in Figure 1.3.2, plot the vector u=⟨1,3⟩.
    Figure 1.3.2. For part (e)
    For each of the following vectors v, plot the vector on Figure 1.3.2 and then compute the dot product uβ‹…v.
    • v=⟨3,2⟩.
    • v=⟨3,0⟩.
    • v=⟨3,βˆ’1⟩.
    • v=⟨3,βˆ’2⟩.
    • v=⟨3,βˆ’4⟩.
  6. Based upon the previous part of this activity, what do you think is the sign of the dot product in the following three cases shown in Figure 1.3.3?
    Figure 1.3.3. For part (f)

Subsection 1.3.1 The Dot Product

The definition of the dot product for vectors in R2 given in Preview Activity 1.3.1 can be extended to vectors in Rn.

Definition 1.3.4.

The dot product of vectors u=⟨u1,u2,…,un⟩ and v=⟨v1,v2,…,vn⟩ in Rn is the scalar
uβ‹…v=u1v1+u2v2+…+unvn.
(As we will see shortly, the dot product arises in physics to calculate the work done by a vector force in a given direction. It might be more natural to define the dot product in this context, but it is more convenient from a mathematical perspective to define the dot product algebraically and then view work as an application of this definition.)
For instance, we find that
⟨3,0,1βŸ©β‹…βŸ¨βˆ’2,1,4⟩=3β‹…(βˆ’2)+0β‹…1+1β‹…4=βˆ’6+0+4=βˆ’2.
Notice that the resulting quantity is a scalar. Our work in Preview Activity 1.3.1 examined dot products of two-dimensional vectors.

Activity 1.3.2.

Determine each of the following.
  1. ⟨1,2,βˆ’3βŸ©β‹…βŸ¨4,βˆ’2,0⟩.
  2. ⟨0,3,βˆ’2,1βŸ©β‹…βŸ¨5,βˆ’6,0,4⟩
Answer.
  1. ⟨1,2,βˆ’3βŸ©β‹…βŸ¨4,βˆ’2,0⟩=1β‹…4+2β‹…(βˆ’2)+(βˆ’3)β‹…0=4βˆ’4+0=0
  2. ⟨0,3,βˆ’2,1βŸ©β‹…βŸ¨5,βˆ’6,0,4⟩=0β‹…5+3β‹…(βˆ’6)+(βˆ’2)β‹…0+1β‹…4=0βˆ’18+0+4=βˆ’14
The dot product is a natural way to define a product of two vectors. In addition, it behaves in ways that are similar to the product of, say, real numbers.

Properties of the dot product.

Let u, v, and w be vectors in Rn. Then
  1. uβ‹…v=vβ‹…u (the dot product is commutative), and
  2. (u+v)β‹…w=(uβ‹…w)+(vβ‹…w).
  3. if c is a scalar, then (cu)β‹…w=c(uβ‹…w).
Moreover, the dot product gives us valuable geometric information about the vectors and their relative orientation. For instance, let’s consider what happens when we dot a vector with itself:
uβ‹…u=⟨u1,u2,…,unβŸ©β‹…βŸ¨u1,u2,…,un⟩=u12+u22+…+un2=|u|2.
In other words, the dot product of a vector with itself gives the square of the length of the vector: uβ‹…u=|u|2.

Subsection 1.3.2 The angle between vectors

The dot product can help us understand the angle between two vectors. For instance, if we are given two non-zero vectors u and v, there are two angles that these vectors create, as depicted at left in Figure 1.3.5. We will call ΞΈ, the smaller of these angles, the angle between these vectors. Notice that ΞΈ lies between 0 and Ο€.
Figure 1.3.5. Left: The angle between u and v. Right: The triangle formed by u, v, and uβˆ’v.

Investigation 1.3.3.

To determine this angle, we may apply the Law of Cosines to the triangle shown at right in Figure 1.3.5.
Using the fact that the dot product of a vector with itself gives us the square of its length, together with the properties of the dot product, we find:
|uβˆ’v|2=(|u|2+|v|2βˆ’2|u||v|cos⁑(ΞΈ)(uβˆ’v)β‹…(uβˆ’v)=(uβ‹…u+vβ‹…vβˆ’2|u||v|cos⁑(ΞΈ)uβ‹…(uβˆ’v)βˆ’vβ‹…(uβˆ’v)=(uβ‹…u+vβ‹…vβˆ’2|u||v|cos⁑(ΞΈ)uβ‹…uβˆ’2uβ‹…v+vβ‹…v=(uβ‹…u+vβ‹…vβˆ’2|u||v|cos⁑(ΞΈ)βˆ’2uβ‹…v=(βˆ’2|u||v|cos⁑(ΞΈ)uβ‹…v=(|u||v|cos⁑(ΞΈ).
So if we knew u and v, we could solve that equation for ΞΈ.

The dot product and the angle between two vectors.

To summarize, we have the important relationship
(1.3.1)uβ‹…v=u1v1+u2v2+…+unvn=|u||v|cos⁑(ΞΈ).
It is sometimes useful to think of Equation (1.3.1) as giving us an expression for the angle between two vectors:
ΞΈ=cosβˆ’1⁑(uβ‹…v|u||v|).
The real beauty of this expression is this: the dot product is a very simple algebraic operation to perform yet it provides us with important geometric information β€” namely the angle between the vectors β€” that would be difficult to determine otherwise.

Activity 1.3.4.

Determine each of the following.
  1. The length of the vector u=⟨1,2,βˆ’3⟩ using the dot product.
  2. The angle between the vectors u=⟨1,2⟩ and v=⟨4,βˆ’1⟩ to the nearest tenth of a degree.
  3. The angle between the vectors y=⟨1,2,βˆ’3⟩ and z=βŸ¨βˆ’2,1,1⟩ to the nearest tenth of a degree.
  4. If the angle between the vectors u and v is a right angle, what does the expression uβ‹…v=|u||v|cos⁑(ΞΈ) say about their dot product?
  5. If the angle between the vectors u and v is acuteβ€”that is, less than Ο€/2β€”what does the expression uβ‹…v=|u||v|cos⁑(ΞΈ) say about their dot product?
  6. If the angle between the vectors u and v is obtuseβ€”that is, greater than Ο€/2β€”what does the expression uβ‹…v=|u||v|cos⁑(ΞΈ) say about their dot product?
Answer.
  1. The dot product gives us uβ‹…u=1+4+9=14, and since the dot product is the same as the magnitude squared, this gives |u|=14.
  2. We get that uβ‹…v=4βˆ’2=2, |u|=5, and |v|=17, so the angle between u and v is approximately
    ΞΈ=cosβˆ’1⁑(uβ‹…v|u||v|)=cosβˆ’1⁑(25β‹…17)β‰ˆ77.5
    degrees.
  3. The angle between the vectors y=⟨1,2,βˆ’3⟩ and z=βŸ¨βˆ’2,1,1⟩ to the nearest tenth of a degree. We get that yβ‹…z=βˆ’2+2βˆ’3=βˆ’3, |y|=14, and |z|=6, so the angle between y and z is approximately
    ΞΈ=cosβˆ’1⁑(uβ‹…v|u||v|)=cosβˆ’1⁑(βˆ’314β‹…6)β‰ˆ109.1
    degrees.
  4. If the angle ΞΈ between the vectors u and v is a right angle, then cos⁑(ΞΈ)=cos⁑(Ο€2)=0 and uβ‹…v=|u||v|cos⁑(ΞΈ)=0 so the dot product of u and v will be zero.
  5. If the angle ΞΈ between the vectors u and v is acute then cos⁑(ΞΈ)>0 because cosine is always positive on accute angles. The values |u| and |v| will also be positive since the magnitudes are positive. Then uβ‹…v=|u||v|cos⁑(ΞΈ)>0 since multiplying any number of positive values together gives a positive value. That is, the dot product of u and v will be positive.
  6. If the angle ΞΈ between the vectors u and v is obtuse then cos⁑(ΞΈ)<0 because cosine is always negative on obtuse angles. The values |u| and |v| will both be positive since the magnitudes are positive. Then uβ‹…v=|u||v|cos⁑(ΞΈ)<0 since multiplying any number of positive values together with one negative gives a negative value. That is, the dot product of u and v will be negative.

Subsection 1.3.3 The Dot Product and Orthogonality

When the angle between two vectors is a right angle, it is frequently the case that something important is happening. In this case, we say the vectors are orthogonal. For instance, orthogonality often plays a role in optimization problems; to determine the shortest path from a point in R3 to a given plane, we move along a line orthogonal to the plane.
As Activity 1.3.4 indicates, the dot product provides a simple means to determine whether two vectors are orthogonal to one another. In this case, uβ‹…v=|u||v|cos⁑(Ο€/2)=0, so we make the following important observation.

The dot product and orthogonality.

Two non-zero vectors u and v in Rn are orthogonal to each other if uβ‹…v=0.
More generally, the sign of the dot product gives us useful information about the relative orientation of the vectors. If we remember that
cos⁑(ΞΈ)>0(    if ΞΈ is an acute angle,cos⁑(ΞΈ)=0(    if ΞΈ is a right angle, andcos⁑(ΞΈ)<0(    if ΞΈ is an obtuse angle,
we see that for nonzero vectors u and v,
uβ‹…v>0(    if ΞΈ is an acute angle,uβ‹…v=0(    if ΞΈ is a right angle, anduβ‹…v<0(    if ΞΈ is an obtuse angle.
This is illustrated in Figure 1.3.6.
Figure 1.3.6. The orientation of vectors

Subsection 1.3.4 Work, Force, and Displacement

In physics, work is a measure of the energy required to apply a force to an object through a displacement. For instance, Figure 1.3.7 shows a force F displacing an object from point A to point B. The displacement is then represented by the vector ABβ†’.
Figure 1.3.7. A force F displacing an object.
It turns out that the work required to displace the object is
W=Fβ‹…ABβ†’=|F||ABβ†’|cos⁑(ΞΈ).
This means that the work is determined only by the magnitude of the force applied parallel to the displacement. Consequently, if we are given two vectors u and v, we would like to write u as a sum of two vectors, one of which is parallel to v and one of which is orthogonal to v. We take up this task after the next activity.

Activity 1.3.5.

Determine the work done by a 25 pound force acting at a 30∘ angle to the direction of the object’s motion, if the object is pulled 10 feet. In addition, is more work or less work done if the angle to the direction of the object’s motion is 60∘?
Answer.
We get that |F|=25 since there are 25 pounds of force being applied, |ABβ†’|=10 since the object is pulled 10 feet, and ΞΈ=30∘ since the force is acting at a 30∘ angle to the direction of motion. Our work formula then gives that the amount of work done is
W=|F||ABβ†’|cos⁑(ΞΈ)=(25)(10)cos⁑(30∘)β‰ˆ216.5.
If the angle between the force and the direction of motion is θ=60∘, then the work done will still be positive, but will be less than when θ=30∘ because cosine approaches 0 as θ approaches 90∘. We can check this with our work formula:
W=|F||ABβ†’|cos⁑(ΞΈ)=(25)(10)cos⁑(60∘)=125.

Subsection 1.3.5 Projections

Figure 1.3.8. Left: projvu. Right: projvu when ΞΈ>Ο€2.
Suppose we are given two non-zero vectors u and v as shown at left in Figure 1.3.8. Motivated by our discussion of work, we would like to write u as a sum of two vectors, one of which is parallel to v and one of which is orthogonal. That is, we would like to write
(1.3.2)u=projvu+projβŠ₯vu,
where projvu is parallel to v and projβŠ₯vu is orthogonal to v. We call the vector projvu the projection of u onto v. Note that, as the diagram at right in Figure 1.3.8 illustrates, it is also possible to create a projection even if the angle between the vectors u and v exceeds Ο€2.
To find the vector projvu, we will dot both sides of Equation (1.3.2) with the vector v, to find that
uβ‹…v=((projvu+projβŠ₯vu)β‹…v=((projvu)β‹…v+(projβŠ₯vu)β‹…v=((projvu)β‹…v.
Notice that (projβŠ₯vu)β‹…v=0 since projβŠ₯vu is orthogonal to v. Also, projvu must be a scalar multiple of v since it is parallel to v, so we will write projvu=sv. It follows that
uβ‹…v=(projvu)β‹…v=svβ‹…v,
which means that
s=uβ‹…vvβ‹…v
and hence
projvu=uβ‹…vvβ‹…vv=uβ‹…v|v|2v
It is sometimes useful to write projvu as a scalar times a unit vector in the direction of v. We call this scalar the component of u along v and denote it as compvu. We therefore have
projvu=uβ‹…v|v|2v=uβ‹…v|v|v|v|=compvuv|v|,
so that
compvu=uβ‹…v|v|.

The dot product and projections.

Let u and v be non-zero vectors in Rn. The component of u in the direction of v is the scalar
compvu=uβ‹…v|v|,
and the projection of u onto v is the vector
projvu=uβ‹…vvβ‹…vv.
Moreover, since
u=projvu+projβŠ₯vu,
it follows that
projβŠ₯vu=uβˆ’projvu.
This shows that once we have computed projvu, we can find projβŠ₯vu simply by calculating the difference of two known vectors.

Activity 1.3.6.

Let u=⟨2,6⟩.
  1. Let v=⟨4,βˆ’8⟩. Find compvu, projvu and projβŠ₯vu, and draw a picture to illustrate. Finally, express u as the sum of two vectors where one is parallel to v and the other is perpendicular to v.
  2. Now let v=βŸ¨βˆ’2,4⟩. Without doing any calculations, find projvu. Explain your reasoning. (Hint: Refer to the picture you drew in part (a).)
  3. Find a vector w not parallel to z=⟨3,4⟩ such that projzw has length 10. Note that there are infinitely many different answers.
Answer.
  1. Calculating some constants in the component and projection we get:
    uβ‹…v=8βˆ’48=βˆ’40,
    vβ‹…v=16+64=80,
    and
    |v|=80
    so
    compvu=uβ‹…v|v|=βˆ’4080=βˆ’25
    and
    projvu=uβ‹…vvβ‹…vv=βˆ’4080⟨4,βˆ’8⟩=βˆ’12⟨4,βˆ’8⟩=βŸ¨βˆ’2,4⟩
    and
    projβŠ₯vu=uβˆ’projvu=⟨2,6βŸ©βˆ’βŸ¨βˆ’2,4⟩=⟨4,2⟩.
    Then
    u=⟨2,6⟩=βŸ¨βˆ’2,4⟩+⟨4,2⟩
    where βŸ¨βˆ’2,4⟩ is parallel to v and ⟨4,2⟩ is perpendicular to v.
  2. In part (a) we saw that v=βŸ¨βˆ’2,4⟩ is parallel to ⟨4,βˆ’8⟩, so the projection of u onto βŸ¨βˆ’2,4⟩ will be the same as the projection of u onto ⟨4,βˆ’8⟩. Then projvu=βŸ¨βˆ’2,4⟩.
  3. Let w=⟨w1,w2⟩ and z=⟨3,4⟩ so |z|=32+42=5. Assuming projzw has length 10 we get
    10=|projzw|=compzw=wβ‹…z|z|=3w1+4w25.
    As noted in the statement, this has infinitely many solutions. We can pick w1=0 and solve: 10=0+4w25 gives w2=252. Note that w=⟨0,252⟩ is not a multiple of z and the two vectors are thus not parallel.

Subsection 1.3.6 Summary

  • The dot product of two vectors in Rn, u=⟨u1,u2,…,un⟩ and v=⟨v1,v2,…,vn⟩, is the scalar
    uβ‹…v=u1v1+u2v2+β‹―+unvn.
  • The dot product is related to the length of a vector since uβ‹…u=|u|2.
  • The dot product provides us with information about the angle between the vectors since
    uβ‹…v=|u| |v|cos⁑(ΞΈ),
    where ΞΈ is the angle between u and v.
  • Two vectors are orthogonal if the angle between them is Ο€/2. In terms of the dot product, the non-zero vectors u and v are orthogonal if and only if uβ‹…v=0.
  • The projection of a vector u in Rn onto a non-zero vector v in Rn is the vector
    projvu=uβ‹…vvβ‹…vv.

Exercises 1.3.7 Exercises

1.

Find aβ‹…b if
a=⟨0,5,βˆ’4⟩ and b=βŸ¨βˆ’2,0,3⟩
aβ‹…b=
Is the angle between the vectors "acute", "obtuse" or "right"?

2.

Determine if the pairs of vectors below are "parallel", "orthogonal", or "neither".
a=⟨2,2,βˆ’5⟩ and b=βŸ¨βˆ’6,βˆ’6,βˆ’24/5⟩ are
a=⟨2,2,βˆ’5⟩ and b=βŸ¨βˆ’6,βˆ’6,15⟩ are
a=⟨2,2,βˆ’5⟩ and b=⟨6,6,βˆ’14⟩ are

3.

Perform the following operations on the vectors uβ†’=⟨3,βˆ’2,5⟩, vβ†’=⟨3,0,3⟩, and wβ†’=βŸ¨βˆ’1,βˆ’2,βˆ’3⟩.
u→⋅w→=
(u→⋅v→)u→=
((w→⋅w→)u→)⋅u→=
u→⋅v→+v→⋅w→=

4.

Find aβ‹…b if |a| = 9, |b| = 10, and the angle between a and b is βˆ’Ο€3 radians.
aβ‹…b =

6.

Find aβ‹…b if |a| = 1, |b| = 3, and the angle between a and b is βˆ’Ο€7 radians.
aβ‹…b =

7.

A constant force F=βˆ’6i+8j+3k moves an object along a straight line from point (3,βˆ’2,5) to point (5,10,βˆ’3).
Find the work done if the distance is measured in meters and the magnitude of the force is measured in newtons.
Work: Nm

8.

A woman exerts a horizontal force of 4 pounds on a box as she pushes it up a ramp that is 6 feet long and inclined at an angle of 30 degrees above the horizontal.
Find the work done on the box.
Work: ft-lb

9.

If Yoda says to Luke Skywalker, β€œThe Force be with you,” then the dot product of the Force and Luke should be:
  • negative
  • zero
  • positive
  • any real number

10.

Find the angle between the diagonal of a cube of side length 12 and the diagonal of one of its faces. The angle should be measured in radians.

11.

Let v=βŸ¨βˆ’2,5⟩ in R2, and let y=⟨0,3,βˆ’2⟩ in R3.
  1. Is ⟨2,βˆ’1⟩ perpendicular to v? Why or why not?
  2. Find a unit vector u in R2 such that u is perpendicular to v. How many such vectors are there? Justify your answers.
  3. Is ⟨2,βˆ’1,βˆ’2⟩ perpendicular to y? Why or why not?
  4. Find a unit vector w in R3 such that w is perpendicular to y. How many such vectors are there?Justify your answers.
  5. Let z=⟨2,1,0⟩. Find a unit vector r in R3 such that r is perpendicular to both y and z. How many such vectors are there? Explain your process.

12.

Consider the triangle in R3 given by P=(3,2,βˆ’1), Q=(1,βˆ’2,4), and R=(4,4,0).
  1. Find the measure of each of the three angles in the triangle, accurate to 0.01 degrees.
  2. Choose two sides of the triangle, and call the vectors that form the sides (emanating from a common point) a and b.
    1. Compute projba, and projβŠ₯ba.
    2. Explain why projβŠ₯ba can be considered a height of triangle PQR.
    3. Find the area of the given triangle.

13.

Let u and v be vectors in R5 with uβ‹…v=βˆ’1, |u|=2, |v|=3. Use the properties of the dot product to find each of the following.
  1. uβ‹…2v
  2. vβ‹…v
  3. (u+v)β‹…v
  4. (2u+4v)β‹…(uβˆ’7v)
  5. |u||v|cos⁑(θ), where θ is the angle between u and v
  6. ΞΈ

14.

One of the properties of the dot product is that (u+v)β‹…w=(uβ‹…w)+(vβ‹…w). That is, the dot product distributes over vector addition on the right. Here we investigate whether the dot product distributes over vector addition on the left.
  1. Let u=⟨1,2,βˆ’1⟩, v=⟨4,βˆ’3,6⟩, and w=⟨4,7,2⟩. Calculate
    uβ‹…(v+w)   and   (uβ‹…v)+(uβ‹…w).
    What do you notice?
  2. Use the properties of the dot product to show that in general
    xβ‹…(y+z)=(xβ‹…y)+(xβ‹…z)
    for any vectors x, y, and z in Rn.

15.

When running a sprint, the racers may be aided or slowed by the wind. The wind assistance is a measure of the wind speed that is helping push the runners down the track. It is much easier to run a very fast race if the wind is blowing hard in the direction of the race. So that world records aren’t dependent on the weather conditions, times are only recorded as record times if the wind aiding the runners is less than or equal to 2 meters per second. Wind speed for a race is recorded by a wind gauge that is set up close to the track. It is important to note, however, that weather is not always as cooperative as we might like. The wind does not always blow exactly in the direction of the track, so the gauge must account for the angle the wind makes with the track. Suppose a 4 mile per hour wind is blowing to aid runners by making a 38∘ angle with the race track. Determine if any times set during such a race would qualify as records.

16.

Molecular geometry is the geometry determined by arrangements of atoms in molecules. Molecular geometry includes measurements like bond angle, bond length, and torsional angles. These attributes influence several properties of molecules, such as reactivity, color, and polarity.
Figure 1.3.9. A methane molecule.
As an example of the molecular geometry of a molecule, consider the methane CH4 molecule, as illustrated in Figure 1.3.9. According to the Valence Shell Electron Repulsion (VSEPR) model, atoms that surround single different atoms do so in a way that positions them as far apart as possible. This means that the hydrogen atoms in the methane molecule arrange themselves at the vertices of a regular tetrahedron. The bond angle for methane is the angle determined by two consecutive hydrogen atoms and the central carbon atom. To determine the bond angle for methane, we can place the center carbon atom at the point (12,12,12) and the hydrogen atoms at the points (0,0,0), (1,1,0), (1,0,1), and (0,1,1). Find the bond angle for methane to the nearest tenth of a degree.