☰ Course contents
Mathematics 🔬 Grade 12 Vector Shadow: The Dot Product and Projections
🔬 Grade 12 · Lesson 8 of 13

Vector Shadow: The Dot Product and Projections

Shine a light straight down onto one vector and the length of the shadow another vector casts is exactly what the dot product measures.

Grade 12Calculus / AP level
Vector Shadow: The Dot Product and Projections — illustration
💡
The big idea: The dot product turns two vectors into a single number that captures how much they point the same way. Algebraically it is just “multiply matching components and add.” Geometrically it is a length times a shadow: the dot product equals the lengths multiplied by the cosine of the angle between them. That one idea powers projections, tests for perpendicularity, and finds angles in any number of dimensions.
🎯 By the end, you'll be able to
  • Compute the dot product from components and from lengths and the included angle
  • Use the sign of the dot product to classify the angle as acute, right, or obtuse
  • Find the scalar projection (the shadow length) of one vector onto another
  • Find the vector projection and use the dot product to test for perpendicularity
📎 You should already know
  • Vectors, components, and magnitude
  • Cosine and the unit circle

Two vectors, one number

You already know how to add vectors and scale them. The dot product does something different: it combines two vectors into a single ordinary number (a scalar), and that number tells you how aligned the two vectors are.

Point them the same way and the dot product is large and positive. Make them perpendicular and it collapses to exactly zero. Point them in opposing directions and it goes negative. In one stroke it measures “how much of this vector lies along that one.”

🔑 Two faces of the same number
The dot product has an algebraic face — multiply matching components and add them up — and a geometric face — the two lengths times the cosine of the angle between them. They always agree, and that agreement is what makes the dot product so useful.
\[ \vec{a}\cdot\vec{b} = a_1 b_1 + a_2 b_2 + a_3 b_3 = |\vec{a}|\,|\vec{b}|\cos\theta \]
The component form (left) and the geometric form (right) give the same scalar. Here θ is the angle between the two vectors.

The shadow picture

Imagine light shining straight down onto vector a. Vector b casts a shadow along the line of a. The length of that shadow is |b| cos θ — it shrinks as the angle opens up, and reverses direction once the angle passes 90°.

Multiply that shadow length by |a| and you get the dot product. So a · b is really “the length of one vector times the shadow the other casts on it.”

🎮 Vector Shadow LIVE
The dot product measures one vector's shadow on another.
✨ The sign is a protractor
Because |a| and |b| are never negative, the sign of the dot product comes entirely from cos θ. So a · b > 0 means an acute angle, a · b = 0 means a right angle, and a · b < 0 means an obtuse angle. You can judge the geometry without ever drawing it.
\[ \cos\theta = \dfrac{\vec{a}\cdot\vec{b}}{|\vec{a}|\,|\vec{b}|} \]
Rearranging the two forms lets you recover the angle between any two vectors, in any dimension.
📝 Worked example: Find the angle between a = (2, 1) and b = (3, 4).
  1. Dot product: \( \vec{a}\cdot\vec{b} = 2\cdot 3 + 1\cdot 4 = 6 + 4 = 10 \).
  2. Lengths: \( |\vec{a}| = \sqrt{2^2+1^2} = \sqrt{5} \) and \( |\vec{b}| = \sqrt{3^2+4^2} = 5 \).
  3. So \( \cos\theta = \dfrac{10}{\sqrt{5}\cdot 5} = \dfrac{10}{5\sqrt{5}} = \dfrac{2}{\sqrt{5}} \approx 0.894 \).
  4. Take the inverse cosine: \( \theta = \cos^{-1}(0.894) \).
✓ The angle is about <strong>26.6&deg;</strong>. The positive dot product already told us it would be acute.

From shadow length to shadow vector

The scalar projection of b onto a is the signed shadow length, comp = (a · b) / |a|. To turn that length back into an actual vector lying along a, multiply by the unit vector in the direction of a. The result is the vector projection.

\[ \operatorname{proj}_{\vec{a}}\vec{b} = \left(\dfrac{\vec{a}\cdot\vec{b}}{|\vec{a}|^{2}}\right)\vec{a} \]
The vector projection: the part of b that lies along a. The scalar in front is the shadow length divided by |a|.
📝 Worked example: Project b = (3, 4) onto a = (2, 1).
  1. Dot product: \( \vec{a}\cdot\vec{b} = 2\cdot 3 + 1\cdot 4 = 10 \).
  2. Squared length of a: \( |\vec{a}|^2 = 2^2 + 1^2 = 5 \).
  3. Scale a by the ratio: \( \operatorname{proj}_{\vec{a}}\vec{b} = \dfrac{10}{5}(2,1) = 2\,(2,1) \).
✓ The vector projection is <strong>(4, 2)</strong> &mdash; it points along a, exactly as a shadow on a should.
⚠️ Zero dot product means perpendicular
The fastest perpendicularity test there is: two nonzero vectors are perpendicular exactly when a · b = 0. For example (2, 1) · (1, −2) = 2 − 2 = 0, so those two vectors meet at a right angle. Do not confuse the dot product (which returns a scalar) with the cross product (which returns a vector) — they answer different questions.

Check your understanding

1. What is the dot product of a = (3, &minus;2) and b = (4, 5)?
a·b = 3(4) + (−2)(5) = 12 − 10 = 2. Multiply matching components and add.
2. Two nonzero vectors have a dot product of exactly 0. What does that tell you?
a·b = |a||b|cosθ. With nonzero lengths, the product is 0 only when cosθ = 0, i.e. θ = 90°.
3. If the angle between two vectors is obtuse (between 90&deg; and 180&deg;), the dot product is…
Cosine is negative for angles between 90° and 180°, and the lengths are positive, so the dot product is negative.
4. The scalar projection (shadow length) of b onto a is given by…
The shadow length is |b|cosθ, and since a·b = |a||b|cosθ, dividing by |a| leaves exactly |b|cosθ.
5. Find the vector projection of b = (6, 0) onto a = (0, 5).
a·b = 0(6) + 5(0) = 0, so the projection is the zero vector. b lies along the x-axis and a along the y-axis, so b casts no shadow on a.
✅ Key takeaways
  • The dot product turns two vectors into one scalar: multiply matching components and add.
  • Geometrically, a&middot;b = |a||b|cos&theta;, a length times the shadow the other vector casts.
  • The sign of the dot product classifies the angle: positive = acute, zero = right, negative = obtuse.
  • The scalar projection (a&middot;b)/|a| is the shadow length; the vector projection puts that shadow back along a.
  • Two nonzero vectors are perpendicular exactly when their dot product is 0.