The dot product
$\mathbf{u} \cdot \mathbf{v} = u_1 v_1 + u_2 v_2 + u_3 v_3$ equals $|\mathbf{u}|\,|\mathbf{v}| \cos\theta$, so it finds the angle between two vectors, tests for right angles and measures how much of one lies along the other.
From Multivariable Calculus.