Linear Algebra
Intermediate

Angle Between Vectors

Angle from the dot product and magnitudes.

Formula

cosθ=abab\cos\theta = \frac{\mathbf{a}\cdot\mathbf{b}}{\|a\|\|b\|}

Variables

a,bVectors

Example

Orthogonal vectors give 90°

Did You Know?

The cosine of the angle between two vectors is their dot product over their lengths — used to compare documents in search engines.