Multivariable CalculusVectors and the Geometry of Space3 of 5
Vectors and the Geometry of Space · 3
The Dot Product
We already know how to add vectors and scale them, and now we need a way to multiply two vectors that measures how much they work together in the same direction.
1
The Dot Product as a Signed Shadow
The dot product of two vectors a and b, written a⋅b, is a single number that measures how much the two vectors line up. When a is at an angle θ to b, only the shadow of a cast perpendicular onto the line of b goes in b's direction, so we multiply that signed shadow by the length of b.
The Dot Product as a Signed Shadow
Shining a light perpendicular to b gives a right triangle with hypotenuse ∣a∣ and adjacent side ∣a∣cosθ along the line of b:
a⋅b=signed shadow of a(∣a∣cosθ)length of b∣b∣=∣a∣∣b∣cosθ
The result a⋅b is a scalar (a single number), not a vector, and the factor ∣a∣cosθ is called the signed shadow because cosθ automatically tracks whether the shadow falls forward or backward along b.
See how the shadow of a and the sign of a⋅b change as you swing a from acute to 90∘ to obtuse:
With b held fixed, the dot product follows the shadow that a casts onto the line of b: positive when the shadow lands forward on b, zero at 90 degrees, and negative when it falls behind b’s tail.
2
The Coordinate Formula for the Dot Product
In 2D and especially in 3D, we are almost always given vectors by their coordinates rather than the angle between them. How do we find the dot product of a=⟨3,1⟩ and b=⟨2,4⟩ using only their coordinates?
The Coordinate Formula for the Dot Product
Text solution
Multiply matching coordinates and addBecause the x- and y-axes are at 90∘ to each other, the x-part of one vector casts zero shadow on the y-part of the other, so only the matching x-parts and matching y-parts stay.
a⋅b=(3)(2)+(1)(4)=6+4=10
In 3D, the x-, y-, and z-axes are all perpendicular to each other, so every pair of different axes casts zero shadow and drops out:
a⋅b=axbx+ayby+azbz
3
Finding the Angle Between Two Vectors
Now we have two ways to compute the exact same number a⋅b: the coordinate formula gives the value with simple arithmetic, while the shadow formula contains the angle θ between the vectors. Setting them equal lets us find the angle θ between any two 3D vectors:
Let's use this equation to find the angle between a=⟨1,2,2⟩ and b=⟨2,0,−1⟩, and then see what changes when b=⟨2,1,2⟩.
Finding the Angle Between Two Vectors
Text solution
First pair: a=⟨1,2,2⟩ and b=⟨2,0,−1⟩
Compute the coordinate dot product firstMultiply matching coordinates and add before calculating any lengths.
a⋅b=(1)(2)+(2)(0)+(2)(−1)=2+0−2=0
So θ=90∘: a dot product of 0 means the shadow has length zero and the two vectors are perpendicular, without needing ∣a∣ or ∣b∣.
Second pair: a=⟨1,2,2⟩ and b=⟨2,1,2⟩
Compute the coordinate dot productMultiply matching components and add them up for the left side of the equation.
a⋅b=(1)(2)+(2)(1)+(2)(2)=2+2+4=8
Find the length of each vectorBy the 3D Pythagorean theorem, square each vector's components, add them, and take the square root.
∣a∣∣b∣=12+22+22=9=3,=22+12+22=9=3
Set the two dot product expressions equal and solve for θDivide the coordinate dot product by ∣a∣∣b∣ and take the inverse cosine.
8⟹cosθ⟹θ=(3)(3)cosθ=98=arccos(98)
4
Direction Angles and Direction Cosines
In 2D, a single angle with the positive x-axis fixes a vector's direction, but in 3D a single angle only narrows the vector to a cone around that axis. To specify the direction of a=⟨1,2,2⟩ in 3D, we measure its three direction anglesα,β, and γ with the positive x-, y-, and z-axes.
Direction Angles and Direction Cosines
Because the signed shadow of a on the x-axis is both ax and ∣a∣cosα, dividing a's components by its length ∣a∣ gives the three direction cosines, which are simply the coordinates of the unit vector a^:
a^=∣a∣a=⟨∣a∣ax,∣a∣ay,∣a∣az⟩=direction cosines of a⟨cosα,cosβ,cosγ⟩
Since a^ is a unit vector, its length is 1, so squaring its three coordinates and adding them always gives 1:
cos2α+cos2β+cos2γ=1
Text solution
Divide a=⟨1,2,2⟩ by its length ∣a∣=3 to get a^The coordinates of the unit vector are the three direction cosines.
a^=3⟨1,2,2⟩=⟨31,32,32⟩=⟨cosα,cosβ,cosγ⟩
Take the inverse cosine of each coordinateEach component of a^ gives the angle with that axis.
αβγ=arccos(31),=arccos(32),=arccos(32)
Notice how tilting a toward one axis forces its angles with the other two axes to adjust so that cos2α+cos2β+cos2γ=1:
A vector’s direction cosines are the coordinates of its unit vector, and tilting toward one axis grows that shadow while the other two shrink so their squares still add up to 1.
5
Scalar and Vector Projections
Instead of projecting a onto a coordinate axis, we often need to project a onto the line of another vector b. Given a=⟨4,3⟩ and b=⟨2,1⟩, we want to find the signed length of a's shadow on b (the scalar projection, compba), the shadow arrow itself along the line of b (the vector projection, projba), and the remaining part of a that is perpendicular to b(aperp).
Scalar and Vector Projections
Because a⋅b multiplies the signed shadow of a by the length of b, dividing by ∣b∣ (which is the same as dotting a with the unit vector b^=b/∣b∣) leaves just the signed shadow of a:
compba=a⋅b^=∣b∣a⋅b
Multiplying that signed number by the unit vector b^ turns the shadow into a vector along the line of b, putting a second factor of ∣b∣ in the denominator:
Notice a nice shortcut in that denominator: ∣b∣2=b⋅b is just the sum of the squared coordinates of b, so when finding a vector projection you don't even have to take a square root.
Text solution
Dot a and b, and find the length of bFor a=⟨4,3⟩ projected onto b=⟨2,1⟩, only the length of b is needed.
a⋅b=(4)(2)+(3)(1)=11,∣b∣=22+12=5
Divide a⋅b by ∣b∣ for the scalar projectionThis divides out the length of b and leaves the signed length of a's shadow.
compba=∣b∣a⋅b=511
Multiply b by (a⋅b)/∣b∣2 for the vector projectionSince ∣b∣2=5, scale b=⟨2,1⟩ by 511.
projba=511⟨2,1⟩=⟨522,511⟩
Subtract the vector projection from a to get the perpendicular partSince projba+aperp=a, subtracting the shadow along b leaves the part perpendicular to b.
aperp=a−projba=⟨4,3⟩−⟨522,511⟩=⟨−52,54⟩
As a quick check, dot aperp with b:⟨−52,54⟩⋅⟨2,1⟩=−54+54=0, confirming they are perpendicular.
Try changing the length and angle of b below: stretching or shrinking b changes a⋅b, but dividing by ∣b∣ cancels b's length out so the projections stay the same, while rotating b past 90∘ flips the shadow backward.
Projecting a onto b depends only on the line b lies on, not how long b is, and past 90 degrees a negative shadow flips the shadow arrow to point opposite b.
6
Work as a Dot Product
In physics, work(W) is the energy transferred when a force F moves an object along a displacement vector d, and only the part of the force lined up with the motion does any work. Let's find the work done in two situations: pulling a crate 10 m horizontally with a 50 N rope at 60∘ above the floor, and a 3D wind force F=⟨3,−2,4⟩ N pushing a drone through a displacement d=⟨5,1,2⟩ m.
Work as a Dot Product
Multiplying the signed shadow of the force along the path by the distance moved is the dot product of F and d:
W=effective force along d(∣F∣cosθ)distance∣d∣=∣F∣∣d∣cosθ=F⋅d
Text solution
Given magnitudes and an angle: use ∣F∣∣d∣cosθFor ∣F∣=50 N at θ=60∘ over ∣d∣=10 m, only the horizontal shadow of the pull moves the crate forward.
W=(50)(10)cos60∘=500(21)=250 J
Given coordinates: dot the components of F and d directlyFor F=⟨3,−2,4⟩ N and d=⟨5,1,2⟩ m, multiply matching coordinates and add without finding any 3D angles.
W=F⋅d=(3)(5)+(−2)(1)+(4)(2)=15−2+8=21 J
So the wind does 21 J of total work, which automatically includes the −2 J in the y-direction where the wind pushed backward (−2 N) while the drone moved forward (+1 m).
Summary
All of these methods come back to one picture: shining a light perpendicular to a vector and measuring the signed shadow.
Lesson Recap
Because the dot product is both the shadow formula ∣a∣∣b∣cosθ and the coordinate sum axbx+ayby+azbz, you can always use whichever form matches what you know:
Computing a⋅b or work W=F⋅d
Use ∣a∣∣b∣cosθ when given lengths and an angle (obtuse angles make cosθ and a⋅b negative), or multiply matching coordinates and add when given components.
Angles and direction cosines
Set axbx+ayby+azbz=∣a∣∣b∣cosθ to find the angle between two vectors, checking a⋅b=0 first for 90∘. For a single vector's angles with the axes, the unit vector a^=a/∣a∣=⟨cosα,cosβ,cosγ⟩ gives the direction cosines directly, with cos2α+cos2β+cos2γ=1.
Projections
Divide a⋅b by ∣b∣ once for the signed shadow length compba=∣b∣a⋅b, divide by ∣b∣2 when scaling b for the shadow vector projba=(∣b∣2a⋅b)b, and subtract aperp=a−projba for the perpendicular part.
7
Practice
1
Two vectors a and b have magnitudes ∣a∣=6 and ∣b∣=4, and the angle between them is θ=120∘. Find the signed shadow of a on the line of b and the dot product a⋅b.
Watch out: cos120∘=−21, not +21; forgetting the negative sign for an obtuse angle gives +3 and +12, and using ∣b∣=4 instead of ∣a∣=6 for the shadow of a gives −2.Watch out: cos120∘=−21, not +21; forgetting the negative sign for an obtuse angle gives +3 and +12, and using ∣b∣=4 instead of ∣a∣=6 for the shadow of a gives −2.
The signed shadow of a comes from the right triangle with hypotenuse ∣a∣=6 and angle 120∘. Since 120∘>90∘, does the shadow land forward or backward along b?
Signed shadow of a=∣a∣cos120∘=6(−21)=−3
(Watch out: cos120∘=−21, not +21; forgetting the negative sign for an obtuse angle gives +3 and +12, and using ∣b∣=4 instead of ∣a∣=6 for the shadow of a gives −2.)
a⋅b=(−3)(4)=−12
2
Find the dot product of a=⟨1,1,0⟩ and b=⟨0,1,−1⟩, and use it to find the angle θ between them.
Multiply matching coordinates to get a⋅b, then set it equal to ∣a∣∣b∣cosθ. What is the length of each vector?
a⋅b=(1)(0)+(1)(1)+(0)(−1)=1
∣a∣=12+12+02=2,∣b∣=02+12+(−1)2=2
(Watch out: don't forget the square roots on ∣a∣ and ∣b∣. Using 2 instead of 2 gives cosθ=41 and θ=arccos(41). Also remember (−1)2=+1, not −1.)
cosθ=2⋅21=21⟹θ=60∘
3
Find the value of c that makes the 3D vectors a=⟨3,c,−2⟩ and b=⟨4,−3,3⟩ perpendicular.
Watch out: (−2)(3)=−6, not +6. Adding 6 instead of subtracting gives 18−3c=0 and the wrong answer c=6.
When two vectors are perpendicular, what must their signed shadow and their dot product equal?
a⋅b=(3)(4)+(c)(−3)+(−2)(3)=12−3c−6=6−3c=0
(Watch out: (−2)(3)=−6, not +6. Adding 6 instead of subtracting gives 18−3c=0 and the wrong answer c=6.)
c=2
4
Find the direction cosines and the direction angles α,β, and γ of the vector v=⟨2,−3,6⟩.
Watch out: (−3)2=+9, not −9, which would give 31; and keep the negative sign on the y-component −73 so β comes out obtuse.
Which unit vector has the direction cosines of v as its three coordinates?
∣v∣=22+(−3)2+62=4+9+36=7⟹v^=⟨72,−73,76⟩
(Watch out: (−3)2=+9, not −9, which would give 31; and keep the negative sign on the y-component −73 so β comes out obtuse.)
cosα=72,cosβ=−73,cosγ=76
α=arccos(72),β=arccos(−73),γ=arccos(76)
5
Given a=⟨1,−2,−3⟩ and b=⟨1,2,2⟩, find the scalar projection and vector projection of a onto b, then split a to find the component aperp that is perpendicular to b.
Watch out: divide by ∣b∣=3, not ∣a∣=14, which gives −149.
Since a is being projected onto b, which vector's length belongs in the denominator, and how many factors of that length go into the scalar projection versus the vector projection?
(Watch out: divide by ∣b∣=3, not ∣a∣=14, which gives −149.)
compba=∣b∣a⋅b=3−9=−3
(Watch out: when multiplying by the unscaled vector b, divide by ∣b∣2=9, not ∣b∣=3. Dividing by 3 forgets to turn b into a unit vector and gives ⟨−3,−6,−6⟩.)
projba=(9−9)⟨1,2,2⟩=⟨−1,−2,−2⟩
(Watch out: you are subtracting a negative vector from a, so subtracting ⟨−1,−2,−2⟩ adds ⟨1,2,2⟩. Dropping the minus signs gives ⟨0,−4,−5⟩.)
aperp=a−projba=⟨1,−2,−3⟩−⟨−1,−2,−2⟩=⟨2,0,−1⟩
6
You pull a crate 8 m horizontally across a floor with a rope force of 40 N at an angle of 60∘ above the floor, while a friction force of 15 N pulls straight backward at 180∘ to the motion. Find the work done by the rope and the work done by friction.
Watch out: only the horizontal shadow 40cos60∘=20 N moves the crate forward; multiplying 40×8 directly gives 320 J. For friction, cos180∘=−1, so don't leave the work positive as +120 J.
How much of the 40 N rope force actually lines up with the horizontal 8 m motion, and what is cos180∘ for a force pulling straight backward?
Wrope=(40)(8)cos60∘=320(21)=160 J
(Watch out: only the horizontal shadow 40cos60∘=20 N moves the crate forward; multiplying 40×8 directly gives 320 J. For friction, cos180∘=−1, so don't leave the work positive as +120 J.)
Wfriction=(15)(8)cos180∘=120(−1)=−120 J
7
A wind force F=⟨4,−3,2⟩ N acts on a drone as it moves along the displacement vector d=⟨3,2,5⟩ m. Find the total work done by the wind, and determine how much work the y-component of the wind does and why it has that sign.
Watch out: work is a single scalar sum, not the vector ⟨12,−6,10⟩, and missing the negative sign on (−3)(2)=−6 gives 28 J.
Multiply matching coordinates of F and d and add them up. What do the signs of Fy=−3 and dy=2 tell you about how the wind and the drone's motion compare along the y-axis?
W=F⋅d=(4)(3)+(−3)(2)+(2)(5)=12−6+10=16 J
(Watch out: work is a single scalar sum, not the vector ⟨12,−6,10⟩, and missing the negative sign on (−3)(2)=−6 gives 28 J.)
The y-component does (−3)(2)=−6 J of work, which is negative because the wind pushes in the negative y-direction while the drone moves in the positive y-direction.
8
A 3D vector a of length 10 makes angles α=60∘ with the positive x-axis, β=45∘ with the positive y-axis, and an obtuse angle γ with the positive z-axis. Find γ and the coordinates of a.
Watch out: taking the positive root cosγ=+21 gives the acute angle γ=60∘ and z-coordinate +5; because γ is obtuse, cosγ must be negative.
What must the squares of the three direction cosines add up to, and which sign do you pick when taking the square root for cosγ if γ is obtuse?