The vector formula to find the angle between vectors is a useful formula to memorize. This formula uses the dot product, magnitude and cosine to give us the angle between vectors. We can use this formula to not only find the angle between vectors, but to also find the angle between planes and the angle between vectors in space, or in the 3D coordinate system.
I want to talk about a really important property of the dot product it can be used to find the angle between 2 vectors so let's say we have 2 vectors u and v theta here is the angle between them and it's going to be some angle between 0 and pi and if I want to find it I can use this property of the dot product. The cosine of theta equals the dot product of the 2 vectors divided by the product of their magnitudes remember theta will always be between 0 and pi or 0 degrees and 180.
Let's see how this works, here's an example let u equal 3 negative 1 and v equal 2 negative 5. Let me first sketch this as position vectors and then I'll compute the angle between them. Now recall that when you sketch a vector as a position vector you're putting its initial point on the origin so 3 negative 1 will be the terminal point. 3 negative 1 is here and so my vector u is right here so that's its position vector I'll label it u and then v goes from the origin to 2 negative 5, 2, 1, 2, 3, 4, 5 so something like this point here now sketching these before hand gives us some idea of what to expect for the angle between them. This is v, the angle between them looks like it's going to be a q so that's good to know ahead of time.
Let's compute it so we use this formula cosine theta equals the dot product of the 2 vectors u.v over the product of their magnitudes. So I should calculate their magnitudes, now the magnitude of u is the square root of 3 squared plus negative 1 squared. The square root of 9 plus 1 root 10 and the magnitude of v is the square root of 2 squared or 4 plus negative 5 squared or 25 and that make 29. Okay so that I can write cosine of theta equals in the denominator root 10 times root 29 okay now let's calculate the dot product u.v it's 3 times 2, 6 plus negative 1 times negative 5, 5. So we get 11 over this product of square roots, I'll write that as the square root of 290 quicker to enter into the calculator and that's cosine of theta. So if I want theta we need to use inverse cosine, theta will equal the inverse cosine of 11 over root 290. So let's calculate that and I'd like my answer in degrees so I'm going to make sure that I'm in degree mode and I am. So inverse cosine of 11 divided by the square root of 290 equals 49.8 degrees that's an approximation and that looks about right.
So remember when you're calculating the angle between 2 vectors use this formula very important, very important application of the dot product. Cosine of the angle between 2 vectors equals the dot product of the 2 vectors divided by the product of their magnitudes.