The dot product (or scalar product) of two vectors is a way of multiplying vectors that results in a scalar (number). This operation, often symbolized by a centered dot, is dependent on the length of both vectors and the angle between them.
- Determines the angle between vectors.
- Product is large when the angle between the vectors is small, indicating they point in a similar direction.
- Conversely, when the vectors are perpendicular, the dot product is zero.

The dot product of two vectors, denoted by a ⋅ b, is defined in two ways:
- Algebraically: The dot product is the sum of the products of the corresponding entries of the two sequences of numbers.
a ⋅ b = ∑ (a_i * b_i)
- a and b are the vectors.
- i iterates over all dimensions (1 to n, where n is the number of dimensions).
- ai and bi represent the corresponding components of vectors a and b.
- Geometrically: It is the product of the magnitudes of the two vectors and the cosine of the angle between them.
a ⋅ b = |a| |b| cos(θ)
- |a| and |b| are the magnitudes (lengths) of vectors a and b, and
- θ is the angle between them.
Finding The Dot Product of Two Vectors
- Identify the vectors: Ensure you have two vectors with the same number of dimensions.
- Multiply corresponding components: For each dimension, multiply the components from each vector together.
- Sum the products: Add the multiplied components together.
- The result is the dot product.
Angle Between Two Vectors Using Dot Product
The dot product formula can be rearranged to find the angle (θ) between two vectors (a and b) using the following formula:
cos(θ) = \dfrac{(a ⋅ b)} {(|a| |b|)}
This formula is useful for determining whether vectors are parallel, perpendicular, or point in similar directions.
Properties
The dot product has several important properties, including:
- Commutative: a ⋅ b = b ⋅ a
- Distributive: a ⋅ (b + c) = a ⋅ b + a ⋅ c
- Associative with scalar multiplication: k(a ⋅ b) = (ka) ⋅ b = a ⋅ (kb)
Applications
The dot product has numerous applications in various fields, including:
- Geometry: Calculating lengths, angles, projections of vectors.
- Graphics: Lighting calculations, 3D transformations.
- Physics: Work done by a force, power, potential energy.
- Machine Learning: Inner product in linear algebra used in algorithms like Support Vector Machines.
Solved Examples
Example 1: Find the dot product of vectors a = [1, 2] and b = [3, 4].
a ⋅ b = (1 * 3) + (2 * 4) = 11
Example 2: Calculate the angle between vectors a = [2, 1] and b = [1, 3] using the dot product.
To calculate the angle between vectors a = [2, 1] and b = [1, 3] using the dot product, you can use the formula:
\cos(\theta) = \frac{\mathbf{a} \cdot \mathbf{b}}{\|\mathbf{a}\| \cdot \|\mathbf{b}\|} a⋅b = (2×1) + (1×3) = 2+3 = 5
|a| = 22 + 12 = 4 + 1 = 5
|b|= 12 + 32 = 1 + 9 = 10
Plugging these values into the formula:
\cos(\theta) = \frac{5}{\sqrt{5} \cdot \sqrt{10}} = \frac{5}{\sqrt{50}} = \frac{5}{\sqrt{25 \cdot 2}} = \frac{5}{5\sqrt{2}} = \frac{1}{\sqrt{2}} = \frac{\sqrt{2}}{2} Taking the inverse cosine to find the angle:
\theta = \cos^{-1}\left(\frac{\sqrt{2}}{2}\right) = 45^\circ
Practice Problems
1. Find the dot product of the vectors a =⟨2, 3⟩ and b = ⟨4, 1⟩.
2. Calculate the dot product of the vectors a = ⟨1, −2, 3⟩ and b = ⟨4, 0, −1⟩.
3. Determine whether the vectors a = ⟨3, 4⟩ and b = ⟨4, −3⟩ are perpendicular using the dot product.
4. Find the angle between the vectors a = ⟨1, 1⟩ and b = ⟨1, −1⟩.
5. Find the projection of the vector a = ⟨6, 8⟩ onto the vector b = ⟨3, 0⟩.