Lesson 4 of 8 · 14 min

The angle between two vectors

Rearrange the scalar product to find the angle between two vectors, exactly or with technology, and use it to find the angles of a triangle from coordinates.

What you will be able to do

  • Find the angle between two vectors using cos⁡(θ)=a∼⋅b∼∣a∼∣∣b∼∣\cos(\theta) = \dfrac{\tvec{a} \cdot \tvec{b}}{|\tvec{a}||\tvec{b}|}.
  • Give exact angles where the cosine is a known exact value, and rounded angles otherwise.
  • Find an angle of a triangle from the coordinates of its vertices, choosing vectors that start at the vertex.

The scalar product has two formulas: one with the angle, one with the components. Set them equal and you can find the angle between any two vectors from their components alone, with no protractor and no sketch to measure.

The angle between two non-zero vectors
cos⁡(θ)=a∼⋅b∼∣a∼∣∣b∼∣=a1b1+a2b2a12+a22 b12+b22,0∘≤θ≤180∘\cos(\theta) = \frac{\tvec{a} \cdot \tvec{b}}{|\tvec{a}||\tvec{b}|} = \frac{a_1 b_1 + a_2 b_2}{\sqrt{a_1^2 + a_2^2}\,\sqrt{b_1^2 + b_2^2}}, \qquad 0^\circ \le \theta \le 180^\circ
Interactive

Angle from components

Check the formula: divide the dot product by the product of the magnitudes and compare cos⁡−1\cos^{-1} of that with the angle shown.

Note

Why there is never a quadrant problem

cos⁡−1\cos^{-1} gives angles from 0∘0^\circ to 180∘180^\circ, which is exactly the range of the angle between two vectors. A negative cosine gives an obtuse or straight angle automatically, so you never need to adjust the calculator's answer.

Worked example

Find the angle between two vectors

  • Simple familiar
  • Technology active

Find the angle between a∼=2i^+j^\tvec{a} = 2\hat{\mathbf{i}} + \hat{\mathbf{j}} and b∼=−i^+3j^\tvec{b} = -\hat{\mathbf{i}} + 3\hat{\mathbf{j}}, correct to one decimal place.

4 steps

Try it yourself first, then check the working one step at a time.

Method

  1. Find a∼⋅b∼\tvec{a} \cdot \tvec{b}, ∣a∼∣|\tvec{a}| and ∣b∼∣|\tvec{b}|.

  2. cos⁡(θ)=a∼⋅b∼∣a∼∣∣b∼∣\cos(\theta) = \dfrac{\tvec{a} \cdot \tvec{b}}{|\tvec{a}||\tvec{b}|}.

  3. Apply cos⁡−1\cos^{-1} in degree mode.

Watch out for

  • Calculator in radian mode gives 1.431.43, which is the angle in radians.

Find the exact angle, in degrees, between a∼=i^+2j^\tvec{a} = \hat{\mathbf{i}} + 2\hat{\mathbf{j}} and b∼=3i^+j^\tvec{b} = 3\hat{\mathbf{i}} + \hat{\mathbf{j}}.

in circ

Find the angle between (1−1)\begin{pmatrix} 1 \\ -1 \end{pmatrix} and (−30)\begin{pmatrix} -3 \\ 0 \end{pmatrix}, in degrees.

in circ

The same formula finds the angles of a triangle drawn on a coordinate grid. The only care needed is choosing the right pair of vectors.

For the angle at AA, use two vectors that start at AA: AB→\overrightarrow{AB} and AC→\overrightarrow{AC}.

Worked example

The angles of a triangle from its vertices

  • Complex familiar
  • Technology active

A triangle has vertices A(1,1)A(1, 1), B(4,2)B(4, 2) and C(2,5)C(2, 5). Find the size of each angle of the triangle, correct to one decimal place.

4 steps

Try it yourself first, then check the working one step at a time.

Method

  1. For the angle at a vertex, use the two vectors from that vertex to the other two.

  2. Apply cos⁡(θ)=u∼⋅v∼∣u∼∣∣v∼∣\cos(\theta) = \dfrac{\tvec{u} \cdot \tvec{v}}{|\tvec{u}||\tvec{v}|}.

  3. Check that the three angles add to 180∘180^\circ.

Watch out for

  • Using AB→\overrightarrow{AB} and BC→\overrightarrow{BC} for angle BB gives 180∘−B180^\circ - B.

  • Finding the last angle only by subtraction from rounded values can be out by 0.1∘0.1^\circ.

Common mistake

Head to tail gives the wrong angle

For the angle at BB you need BA→\overrightarrow{BA} and BC→\overrightarrow{BC}. Using AB→\overrightarrow{AB} and BC→\overrightarrow{BC} (head to tail) gives the exterior angle, 180∘−B180^\circ - B. If your three angles do not add to 180∘180^\circ, check this first.

Exam tip

Exact or rounded?

In a technology-free question the numbers will be chosen so that cos⁡(θ)\cos(\theta) is an exact value such as 12\frac{1}{2}, 32\frac{\sqrt{3}}{2} or −12-\frac{1}{\sqrt{2}}. Otherwise give θ\theta to the accuracy asked for, usually one decimal place, and keep the unrounded cosine in your calculator.

Summary

  • cos⁡(θ)=a∼⋅b∼∣a∼∣∣b∼∣\cos(\theta) = \dfrac{\tvec{a} \cdot \tvec{b}}{|\tvec{a}||\tvec{b}|} gives the angle between two non-zero vectors, with 0∘≤θ≤180∘0^\circ \le \theta \le 180^\circ.

  • A negative dot product gives an obtuse or straight angle; cos⁡−1\cos^{-1} handles this without adjustment.

  • For the angle at a vertex of a triangle, use the two vectors that start at that vertex.

  • Learn the exact values: cos⁡(θ)=12,12,32\cos(\theta) = \frac{1}{2}, \frac{1}{\sqrt{2}}, \frac{\sqrt{3}}{2} give 60∘,45∘,30∘60^\circ, 45^\circ, 30^\circ, and their negatives give 120∘,135∘,150∘120^\circ, 135^\circ, 150^\circ.

Finished the lesson?

Try the 2 quick checks above and the lesson completes itself, or mark it complete now.

Lesson 4 of 80% read

Save your progress with a free account