What is a dot product?
The dot product, also known as the scalar product, is a binary operation that takes two vectors and returns a single scalar value. It's a fundamental concept in linear algebra and vector mathematics. Here's a simple breakdown:
-
Definition: Given two vectors u = (u₁, u₂, ..., uₙ) and v = (v₁, v₂, ..., vₙ) in an n-dimensional space, their dot product is defined as:
u · v = u₁v₁ + u₂v₂ + ... + uₙvₙ
-
Geometric interpretation: The dot product of two vectors can be thought of as the product of their magnitudes (or lengths) and the cosine of the angle between them. Mathematically, this is expressed as:
u · v = |u| |v| cos(θ)
where |u| and |v| are the magnitudes of vectors u and v, respectively, and θ is the angle between them.
-
Properties:
- Commutative: u · v = v · u
- Distributive: u · (v + w) = u · v + u · w
- Orthogonality: If u is orthogonal (perpendicular) to v, then u · v = 0.