The dot product, also called scalar product of two vectors is one of the two ways we learn how to multiply two vectors together, the other way being the cross product, also called vector product.
When we multiply two vectors using the dot product we obtain a scalar (a number, not another vector!.
Notation
Given two vectors \(\vec{u}\) and \(\vec{v}\) we refer to the scalar product by writing:
\[\vec{u}\bullet \vec{v}\]
In other words by writing a dot between the two vectors, which explains why we also call it the dot product.
Scalar Product: using the components of the vectors
2D Vectors
Given two vectors \(\vec{u} = \begin{pmatrix} u_1 \\ u_2 \end{pmatrix}\) and \(\vec{v} = \begin{pmatrix} v_1 \\ v_2 \end{pmatrix}\) their scalar product is:
\[\vec{u} \bullet \vec{v} = u_1v_1 + u_2v_2 \]
3D Vectors
Given two vectors \(\vec{u} = \begin{pmatrix} u_1 \\ u_2 \\ u_3 \end{pmatrix}\) and \(\vec{v} = \begin{pmatrix} v_1 \\ v_2 \\ v_3 \end{pmatrix}\) their scalar product is:
\[\vec{u} \bullet \vec{v} = u_1v_1 + u_2v_2 + u_3v_3 \]
Tutorial: How to Calculate the Scalar Product
In this tutorial we learn how to calculate the scalar product of \(2\) vectors, using their components. We do this for both 2D and 3D vectors.
Example (2D Vectors)
Given \(\vec{a} = \begin{pmatrix} 2 \\ - 5 \end{pmatrix}\) and \(\vec{b} = \begin{pmatrix} 1 \\ -3 \end{pmatrix}\), we can calculate their scalar product \(\vec{a}\bullet \vec{b}\) as follows:
\[\begin{aligned}
\vec{a}\bullet \vec{b} & = 2 \times 1 + (-5)\times (-3) \\
& = 2 + 15 \\
\vec{a}\bullet \vec{b} & = 17
\end{aligned}\]
Example (3D Vectors)
Given \(\vec{u} = \begin{pmatrix} 2 \\ 1 \\ -3 \end{pmatrix}\) and \(\vec{v} = \begin{pmatrix} 4 \\ 0 \\ 5 \end{pmatrix}\), we can calculate their cross product \(\vec{u}\bullet \vec{v}\) as follows:
\[\begin{aligned}
\vec{u} \bullet \vec{v} & = 2\times 4 + 1\times 0 + (-3)\times 5 \\
& = 8 + 0 - 15 \\
\vec{u} \bullet \vec{v} & = -7
\end{aligned}\]
Scalar Product: using the magnitudes and angle
Given two vectors \(\vec{u}\) and \(\vec{v}\), in 2D or in 3D, their scalar product (or dot product) can be calculated using the formula:
\[\vec{u} \bullet \vec{v} = \begin{vmatrix}\vec{u} \end{vmatrix}.\begin{vmatrix}\vec{v} \end{vmatrix}cos \theta\]
where \(\theta \) is the angle between \(\vec{u}\) and \(\vec{v}\)
Example
Given two vectors \(\vec{a}\) and \(\vec{b}\) such that \(\begin{vmatrix} \vec{a}\end{vmatrix} = 4\), \(\begin{vmatrix} \vec{b}\end{vmatrix} = 5\) and the angle between them is \(\theta = 60^{\circ}\).
The scenario we're dealing with is illustrated here. Using the formula we just saw, we can state:
\[\begin{aligned} \vec{a} \cdot \vec{b} &= \begin{vmatrix} \vec{a}\end{vmatrix}. \begin{vmatrix} \vec{b}\end{vmatrix} \times cos \theta \\
& = 4\times 5 \times cos\begin{pmatrix}60^{\circ} \end{pmatrix} \\
& = 20\times 0.5 \\
\vec{a}\cdot {b} & = 10 \end{aligned} \]
The scalar product of these two vectors equals \(10\).
The Role of the interior angle \(\theta \)
The angle \(\theta \) between two vectors \(\vec{u}\) and \(\vec{v}\) plays an important role on the sign of the dot product.
This is due to the fact that \(cos \theta \) changes from positive to zero to negative as \(\theta \) goes from acute, to right angle, to obtuse.
Looking at the formula \(\vec{u} \bullet \vec{v} = \begin{vmatrix}\vec{u} \end{vmatrix}.\begin{vmatrix}\vec{v} \end{vmatrix}cos \theta\) it is clear that the magnitudes \(\begin{vmatrix} \vec{u} \end{vmatrix}\) and \(\begin{vmatrix} \vec{u} \end{vmatrix}\) are always positive so \(cos \theta \) and therefore \(\theta \) is the parameter that dictaes the sign of the result.
The 3 scenarios that must be known are shown here:
When \(\theta \) is Acute
When the angle \(\theta \) between the vectors \(\vec{u}\) and \(\vec{v}\) is acute the dot product is positive:
\[\vec{u} \cdot \vec{v} > 0\]
When \(\theta \) is Obtuse
When the angle \(\theta \) between the vectors \(\vec{u}\) and \(\vec{v}\) is obtuse the dot product is negative:
\[\vec{u} \cdot \vec{v} < 0\]
When \(\theta = 90^{\circ }\)
When the angle \(\theta \) between the vectors \(\vec{u}\) and \(\vec{v}\) is a right angle the dot product is equal to zero:
\[\vec{u} \cdot \vec{v} = 0\]
TEST for PERPENDICULAR VECTORS
Given two vectors \(\vec{u}\) and \(\vec{v}\) (in 2D or 3D) they are perpendicular if and only if:
\[\vec{u} \cdot \vec{v} = 0\]
This provides with a very useful way for checking whether two vectors are perpendicular.
Example
State whether the following pairs of vectors are perpendicular:
We work through a typical exam style question, seen several times in exams (although with different numbers).
Given the vectors \(\vec{u} = \begin{pmatrix} 0 \\ 5 \\ q \end{pmatrix}\) and \(\vec{v} = \begin{pmatrix} 0 \\ 10 \\ 14 \end{pmatrix}\) find the value of \(q\) for which \(\vec{u}\) and \(\vec{v}\) are:
Parallel
Perpendicular
Properties of the Scalar Product
For any vectors such as \(\vec{u}\), \(\vec{v}\) and \(\vec{w}\)
The scalar product is commutative: \(\vec{u}\bullet \vec{v} = \vec{v}\bullet \vec{u}\)
The scalar product follows the "usual" laws of distributivity \(\vec{u}\bullet \begin{pmatrix} \vec{v} + \vec{v}\end{pmatrix} = \vec{u}\bullet \vec{v} + \vec{u}\bullet \vec{w}\)
Given a vector \(\vec{u}\) and a scalar \(k\in\mathbb{R}\): \(\begin{vmatrix} k.\vec{u}\end{vmatrix} = \begin{vmatrix} k\end{vmatrix}.\begin{vmatrix} \vec{u}\end{vmatrix}\)
Example 1
Given the two vectors \(\vec{a} = \begin{pmatrix}1 \\ 4 \\ -3\end{pmatrix}\) and \(\vec{b} = \begin{pmatrix}2 \\ 7 \\ 5\end{pmatrix}\), we can show that \(\vec{a} \cdot \vec{b} = \vec{b} \cdot \vec{a} \):
Given the vectors \(\vec{a} = \begin{pmatrix} 2 \\ -3 \\ 4 \end{pmatrix}\) and \(\vec{b} = \begin{pmatrix}1 \\ -2 \\ p \end{pmatrix}\), find the value of \(p\) for which \(\vec{a}\) and \(\vec{b}\) are perpendicular.
Given the vectors \(\vec{u} = \begin{pmatrix} 0 \\ 5 \\ q \end{pmatrix}\) and \(\vec{v} = \begin{pmatrix} 0 \\ 10 \\ 14 \end{pmatrix}\), find the value of \(q\) for which \(\vec{u}\) and \(\vec{v}\) are:
parallel
perpendicular
Show that triangle ABC, where the vertices \(A\), \(B\) and \(C\) have coordinates \(A(0,-3,9)\), \(B(5,-10,10)\) and \(C(2,-4,6)\) is right angled at \(C\).
Given \(\vec{u} = \begin{pmatrix} 2k \\ - 1 \\ 1 \end{pmatrix}\) and \(\vec{v} = \begin{pmatrix} k \\ k \\ -1 \end{pmatrix}\) are perpendicular and \(k >0\), find the value of \(k\).
Note: this exercise can be downloaded as a worksheet to practice with: Worksheet 1
Exercise 1 - Answer Key
We find the following results:
\(\vec{a}\cdot \vec{b} = 1\)
\(\vec{u}\cdot \vec{v} = -9\)
\(\vec{c}\cdot \vec{d} = -18\)
For the \(\vec{a}\) and \(\vec{b}\) to be perpendicular they must be such that:
\[\vec{a} \cdot \vec{b} = 0\]
Since:
\[\vec{a} \cdot \vec{b} = 2+ 6+ 4p = 8 + 4p\]
we find \(p\) such that:
\[8+4p=0\]
Which leads to:
\[p = -2\]
For \(\vec{u}\) and \(\vec{v}\) to be:
parallel, we find \(q =7\)
perpendicular, we find \(q = -\frac{25}{7}\).
We show that the vectors \(\vec{CA}\) and \(\vec{CB}\) are perpendicular:
\[\vec{CA} = \begin{pmatrix} -2 \\ 1 \\ 3 \end{pmatrix}, \quad \vec{CB} = \begin{pmatrix} 3 \\ -6 \\ 4 \end{pmatrix} \]
We now calculate \(\vec{CA}\cdot \vec{CB}\):
\[\vec{CA} \cdot \vec{CB} = -6 - 6 +12 = 0\]
Since \(\vec{CA} \cdot \vec{CB} = 0\) we can confirm that the triangle is right angled at \(C\).
\(\vec{u}\) and \(\vec{v}\) are perpendicular if and only if \(\vec{u} \cdot \vec{v} = 0\).
Since:
\[\vec{u} \cdot \vec{v} = 2k^2 - k - 1\]
We therefore solve \(2k^2 - k - 1 = 0\).
Factoring we find:
\[2k^2 - k - 1 = \begin{pmatrix}2k+1 \end{pmatrix} \begin{pmatrix} k - 1 \end{pmatrix}\]
Solving \(\begin{pmatrix}2k+1 \end{pmatrix} \begin{pmatrix} k - 1 \end{pmatrix} = 0\) leads to 2 possible values:
\[k = -\frac{1}{2}, \quad k = 1\]
Since we are told \(k>0\) we can state \(k=1\).
Answers with Working
Select the question number you'd like to see the working for:
Scan this QR-Code with your phone/tablet and view this page on your preferred device.
Subscribe Now and view all of our playlists & tutorials.