Cosine between two vectors

• Nov 24th 2010, 11:33 PM
Glitch
Cosine between two vectors
The question:

Given the vectors p = (1 1 -1) and q = (2 1 -1), find the cosine between p and q.

My attempt:

I found the magnitude of p and q, which are $\sqrt{3}$ and $\sqrt{6}$ respectively.

I then found the dot product of the vectors, which resulted in 4.

Using $a.b = |a||b|cos\theta$ I rearranged the equation to:

$cos\theta = \frac{a.b}{|a||b|}$

Substituting the values I got $\frac{4}{3\sqrt{2}}$

The answer in the text is $\frac{2\sqrt{2}}{6}}$

What am I doing wrong? Thanks!
• Nov 25th 2010, 12:41 AM
earboth
Quote:

Originally Posted by Glitch
The question:

Given the vectors p = (1 1 -1) and q = (2 1 -1), find the cosine between p and q.

My attempt:

I found the magnitude of p and q, which are $\sqrt{3}$ and $\sqrt{6}$ respectively.

I then found the dot product of the vectors, which resulted in 4.

Using $a.b = |a||b|cos\theta$ I rearranged the equation to:

$cos\theta = \frac{a.b}{|a||b|}$

Substituting the values I got $\frac{4}{3\sqrt{2}}$

The answer in the text is $\frac{2\sqrt{2}}{6}}$

What am I doing wrong? Thanks!

With the given vectors your result is OK, but:

$\frac{4}{3\sqrt{2}} = \frac{4}{3\sqrt{2}} \cdot \frac{\sqrt{2}}{\sqrt{2}} = \frac{2\sqrt{2}}3$
• Nov 25th 2010, 01:19 AM
Glitch
So the text is incorrect?