# Inner Product Definitions Galore?

Hello, I thought I understood the Dot Product but Apparently Not!

$$\overline{u} \ \cdot \ \overline{v} \ = (u_x \ \cdot \ v_x) ( \overline{i} \cdot \overline{i} ) \ + \ (u_y \ \cdot \ v_y) ( \overline{j} \cdot \overline{j} ) \ = \ | \overline{u} | | \overline{v} | cos \theta$$

That is the dot product in all it's glory, right? I've included the component definition & the angle definition.

This is all I've ever needed in physics anyway.

However! My wonderful book from the 1960's has so kindly informed me of the definition of the dot product arises from the Law of Cosines. I'm at a loss I must say.

I guess I took a lot of stuff for granted about vectors & this book is ironing out the mental kinks, bear with me if I say something stupid, it just has to be done I need to get a few things clear first, should only take a moment!

http://img121.imageshack.us/img121/6545/vector1n.jpg [Broken]

I believe the above way is the method for adding two vectors together, is in not? (The absolute value signs on $$\overline{u} \ + \ \overline{v}$$ is a mistake, so is the labelling on the graph, vector u is at point 2, NOT 1, I apologise!).

What has confused me about this is that in my book there are plenty of pictures of the following;

http://img510.imageshack.us/img510/2930/vector2.jpg [Broken]

And a picture such as the above is used to define the Inner Product.

I thought adding vectors tail to tail was wrong, it's has to be like in my first picture, (as my physics book made quite clear)?

Which way is which and when is either done???

I don't mean to take up too much of anybodies time with my misunderstandings but I'll have a few more questions

Last edited by a moderator:

Related Calculus and Beyond Homework Help News on Phys.org
Mark44
Mentor
Hello, I thought I understood the Dot Product but Apparently Not!

$$\overline{u} \ \cdot \ \overline{v} \ = (u_x \ \cdot \ v_x) ( \overline{i} \cdot \overline{i} ) \ + \ (u_y \ \cdot \ v_y) ( \overline{j} \cdot \overline{j} ) \ = \ | \overline{u} | | \overline{v} | cos \theta$$

That is the dot product in all it's glory, right? I've included the component definition & the angle definition.
Your coordinate definition has some extra stuff that's unnecessary (the dot products of the i and j unit vectors), and it is limited to vectors in R2, when it is actually much more general.
This is all I've ever needed in physics anyway.

However! My wonderful book from the 1960's has so kindly informed me of the definition of the dot product arises from the Law of Cosines. I'm at a loss I must say.

I guess I took a lot of stuff for granted about vectors & this book is ironing out the mental kinks, bear with me if I say something stupid, it just has to be done I need to get a few things clear first, should only take a moment!

http://img121.imageshack.us/img121/6545/vector1n.jpg [Broken]

I believe the above way is the method for adding two vectors together, is in not? (The absolute value signs on $$\overline{u} \ + \ \overline{v}$$ is a mistake, so is the labelling on the graph, vector u is at point 2, NOT 1, I apologise!).

What has confused me about this is that in my book there are plenty of pictures of the following;

http://img510.imageshack.us/img510/2930/vector2.jpg [Broken]

And a picture such as the above is used to define the Inner Product.

I thought adding vectors tail to tail was wrong, it's has to be like in my first picture, (as my physics book made quite clear)?
No, this isn't wrong. The vector sum is usually portrayed with the tail of one vector starting out from the head of another vector. This determines a parallelogram whose long diagonal represents the sum of the two vectors.

But a vector is unchanged by merely translating it. As long as the magnitude and direction don't change, the vector doesn't change, so it makes to difference if the two vectors start from the same point or if one of them starts from the head end of the other.

For your question about the Law of Cosines, as I remember it (and I haven't thought about this for some time), you start with two vectors as in your 2nd drawing, and use the Law of Cosines to find the cosine of the angle between the two vectors. The two vectors form two sides of the triangle, and the third side runs between the heads of the two vectors.
Which way is which and when is either done???

I don't mean to take up too much of anybodies time with my misunderstandings but I'll have a few more questions

Last edited by a moderator:
Thanks for the helpful response. :)

Yes I restricted the dimensions out of laziness & included the dot product of the the i's and j's just to be extra careful (literally dotting all i's & crossing all j's ;) ).

1: So, illustrating the vectors joined at the tail is a convenience as it doesn't change the magnitude of their resultant vector (i.e.when they are added or subtracted).

I think the pictures confused me, when you see a picture like the one below this text, in the green part, you would mentally calculate steps 1 & 2 in the picture to convince yourself that the red u - v is the vector sum u + (-v) or vice versa, right?

http://img51.imageshack.us/img51/4435/vector3n.jpg [Broken]

2: Okay, so what is confusing me about the Law of Cosines when applied to the inner product is as follows (drum roll!!!), I think doing a worked example will be the best way for me, I'll do the work & you just criticize me :tongue2:

Using the following picture, I wish to find the angle between the displayed vectors by constructing a vector opposite the angle $$\theta$$

The side opposite the angle is u - v as shown; Okay. We'll use the definition of the Law of Cosines;

$$| \overline{u} \ - \ \overline{v} |^2 = \ | \overline{u} |^2 \ + \ | \overline{v} |^2 \ - \ 2 | \overline{u} | | \overline{v} | cos \theta$$

So to find the angle we just algebraically solve for $$cos \theta$$

Staying with the above equation, I do not know how to calculate $$| \overline{u} \ - \ \overline{v} |^2$$ ? I am confused by the absolute value signs, and think you'd add components first, but I'm not sure.

Using my above example I'll calculate all that I can do, to be sure I'm doing it right.

$$\overline{u} \ = \ 2 \overline{i} \ + \ 6 \overline{j}$$

$$| \overline{u} | \ = \sqrt{(2)^2 \ + \ (6)^2} \ = \ 6.324.. \ \approx \ 6.3$$

$$| \overline{u} |^2 \ \approx \ 40$$

$$\overline{v} \ = \ 4 \overline{i} \ + \ 3 \overline{j}$$

$$| \overline{v} | \ = \sqrt{(4)^2 \ + \ (3)^2} \ = \ 5$$

$$| \overline{v} |^2 \ = \ 25$$

Last edited by a moderator:
Mark44
Mentor
Yes, just solve for cos(theta) algebraically.
Since you know the coordinates of vectors u and v, it's a simple matter to find |u - v|.

You can derive the coordinate-free definition of the dot product from the coordinate version + the Law of Cosines. Here's how it would go for vectors in R2.

Let u = <u1, u2> and v = <v1, v2>.
From the Law of Cosines, you have
|u - v|2 = |u|2 + |v|2 - 2|u||v|cos(t) (using t instead of theta)
==> |u - v|2 - |u|2 - |v|2 = - 2|u||v|cos(t)
==> (1/2)(|u|2 + |v|2 - |u - v|2) = |u||v|cos(t)

Now expand everything on the left side using the fact that |u|2 = u12 + u22, and similarly for |v|2 and |u - v|2. Lots of terms will drop out.

Using the Law of Cosines, I could solve for $$cos \theta$$ and use the information thatI've already calculated in my last post, this will avoid some of the work & is the very same thing. You'll see where I'm tripping up in what follows:

$$\overline{u} \ = \ 2 \overline{i} \ + \ 6 \overline{j}$$

$$| \overline{u} | \ = \sqrt{(2)^2 \ + \ (6)^2} \ = \ 6.324.. \ \approx \ 6.3$$

$$| \overline{u} |^2 \ \approx \ 40$$

$$\overline{v} \ = \ 4 \overline{i} \ + \ 3 \overline{j}$$

$$| \overline{v} | \ = \sqrt{(4)^2 \ + \ (3)^2} \ = \ 5$$

$$| \overline{v} |^2 \ = \ 25$$

So I can rewrite the definition of the Law of Cosines using this information;

$$| \overline{u} \ - \ \overline{v} |^2 = \ | \overline{u} |^2 \ + \ | \overline{v} |^2 \ - \ 2 | \overline{u} | | \overline{v} | cos \theta$$

$$\ 2 | \overline{u} | | \overline{v} | cos \theta \ = \ | \overline{u} |^2 \ + \ | \overline{v} |^2 \ - | \overline{u} \ - \ \overline{v} |^2$$

$$cos \theta \ = \frac{| \overline{u} |^2 \ + \ | \overline{v} |^2 \ - \ | \overline{u} \ - \ \overline{v} |^2 }{2 | \overline{u} | | \overline{v}| }$$

And now plug in the values;

$$cos \theta \ = \frac{ 40 \ + 25 - \ | \overline{u} \ - \ \overline{v} |^2 }{2 (6.3)(5) }$$

But I mechanically do not know how to compute the $$| \overline{u} \ - \ \overline{v} |^2$$ because of the absolute values etc...

I'd be more confident deriving the general form of the Law once I get past this little snippet :)

Mark44
Mentor
Using the Law of Cosines, I could solve for $$cos \theta$$ and use the information thatI've already calculated in my last post, this will avoid some of the work & is the very same thing. You'll see where I'm tripping up in what follows:

$$\overline{u} \ = \ 2 \overline{i} \ + \ 6 \overline{j}$$

$$| \overline{u} | \ = \sqrt{(2)^2 \ + \ (6)^2} \ = \ 6.324.. \ \approx \ 6.3$$

$$| \overline{u} |^2 \ \approx \ 40$$
No, |u|2 = 40 (exactly)
$$\overline{v} \ = \ 4 \overline{i} \ + \ 3 \overline{j}$$

$$| \overline{v} | \ = \sqrt{(4)^2 \ + \ (3)^2} \ = \ 5$$

$$| \overline{v} |^2 \ = \ 25$$

So I can rewrite the definition of the Law of Cosines using this information;

$$| \overline{u} \ - \ \overline{v} |^2 = \ | \overline{u} |^2 \ + \ | \overline{v} |^2 \ - \ 2 | \overline{u} | | \overline{v} | cos \theta$$

$$\ 2 | \overline{u} | | \overline{v} | cos \theta \ = \ | \overline{u} |^2 \ + \ | \overline{v} |^2 \ - | \overline{u} \ - \ \overline{v} |^2$$

$$cos \theta \ = \frac{| \overline{u} |^2 \ + \ | \overline{v} |^2 \ - \ | \overline{u} \ - \ \overline{v} |^2 }{2 | \overline{u} | | \overline{v}| }$$

And now plug in the values;

$$cos \theta \ = \frac{ 40 \ + 25 - \ | \overline{u} \ - \ \overline{v} |^2 }{2 (6.3)(5) }$$

But I mechanically do not know how to compute the $$| \overline{u} \ - \ \overline{v} |^2$$ because of the absolute values etc...
There's nothing at all difficult here. You know the coordinates of the two vectors, so you should be able to find the coordinates of u - v. Then calculate the magnitude of that new vector.
I'd be more confident deriving the general form of the Law once I get past this little snippet :)

No, |u|2 = 40 (exactly)
Haha, nice I think I got consumed by playing with latex (pun intended :tongue2: )

Listen, I really appreciate your help. I'm sorry if it's a bit frustrating, really, I appreciate you pushing me to get the answer as opposed to spelling it out The ways I would think of evaluating $$| \overline{u} \ - \ \overline{v} |^2$$ would be either;

Using
$$\overline{u} \ = \ 2 \overline{i} \ + \ 6 \overline{j}$$
&
$$\overline{v} \ = \ 4 \overline{i} \ + \ 3 \overline{j}$$

$$1: \ | \ \overline{u} \ - \overline{v} |^2 \ = \ | (2 \ - \ 4)\overline{i} \ + \ (6 \ - 3 ) \overline{j} |^2 \ = \ | -2 \overline{i} \ + \ 3 \overline{j} |^2$$

$$| -2 \overline{i} \ + \ 3 \overline{j} |^2 \ = \ [ \sqrt{(-2)^2 \ + 3^2} ]^2 \ = \ [ \sqrt{13} ]^2 ] \ = \ 13$$

or

$$2: \ | \ \overline{u} \ - \overline{v} |^2 \ = ( \overline{u} \ - \overline{v} ) ( \overline{u} \ - \overline{v} ) = \ \overline{u}^2 \ - \ 2 \overline{u} \overline{v} \ + \ \overline{v}^2$$

But if I use this second description I'll be left with i's and j's in the result & that can't go in the fraction on top!

If I use the First method, I'll get an answer;

$$cos \theta \ = \frac{ 40 \ + 25 - \ 13 }{2 (6.3)(5) }$$
$$cos \theta \ = \frac{ 52 }{63 }$$
$$\theta \ = arccos ( \frac{ 52 }{63 } )$$
$$\theta \ = \ 34.3712...'$$

If you think that's correct, please let me know.

Also, in my second method above I'd need to use that method to do a proof of the general Dot Product & it seems like my book avoids components, I may be missing something in my expansion, could you point out what it is?

Mark44
Mentor
Just do it the first way you did it.