You can use the geometric definition of the dot product to calculate the angle between two non-zero vectors. Now, if one of the vectors is the zero vector, the angle between the two vectors is not defined at all. For two non-zero vectors u and v, solve the formula
u
v = ||u|| ||v|| cos θ for cos θ:

.

Then

.

Some special cases of this formula are useful to remember.

Two vectors are perpendicular, or orthogonal, when the angle between them is 90º or π/2. In that case, cos θ = 0 and you get uv = 0.

If the angle between the vectors is acute (less than π/2), then cos θ > 0, so
uv > 0.

If the angle between the vectors is obtuse (greater than π/2), then cos θ < 0, so
u
v < 0.

If the vectors are parallel in the same direction, then the angle between them is 0 and
cos θ = 1 , so uv = ||u|| ||v||.

If the vectors are parallel in opposite directions, then the angle between them is π and
cos θ = -1, so uv = -||u|| ||v||.

This diagram shows the effect of changing the vectors on the formula for angles. Which parts of the formula change if you change only the length of one of the vectors?
:::