Jump to content
Sign in to follow this  
hobz

Why is cosine used in the definition of the dot product

Recommended Posts

When defining the dot product, the cosine of the angle between two vectors is chosen. Why not the sine?

 

What advantages are there by choosing the cosine?

Share this post


Link to post
Share on other sites
When defining the dot product, the cosine of the angle between two vectors is chosen. Why not the sine?

Multiple answers:


  •  
  • First and foremost, the cosine is not used in the definition of the dot product. For vectors in a Cartesian space, the dot product is defined as
     
    [math]\mathbf a \cdot \mathbf b = \sum_i a_i b_i[/math]
     
    That this is equal to [math]||\mathbf a||\,||\mathbf b||\,\cos\theta[/math] is a consequence of the definition.
     
     
  • The generalization of the dot product is the inner product. Inner products can be defined for spaces where the concept of angle doesn't really make sense other than tautologically via
     
    [math]\cos\theta \equiv \frac{\mathbf a \cdot \mathbf b}{||\mathbf a||\,||\mathbf b||}[/math]
     
     
  • The inner product between a vector and itself, [math](\mathbf a,\mathbf a)[/math], must only be zero if [math]\mathbf a[/math] is the zero vector. Defining the dot product in terms of sine would violate this fundamental precept. The result might be a scalar, but it would not be an inner product.
     
     
  • Lack of a clear-cut meaning. What is the sign (not sine) of the angle [math]\theta[/math]? Since [math]\cos\theta = \cos(-\theta)[/math], that the sign of the angle is a bit ambiguous doesn't really matter if the dot product is defined in terms of [math]\cos\theta[/math]. It obviously makes a big difference if the inner product was defined in terms of [math]\sin\theta[/math].
     
     
  • For vectors in three-space there already is a product that depends on the sine of the angle between the vectors. This is the cross product.
     
     
  • Finally, there is a matter of utility. A scalar product that depends on the cosine of the angle of the angle between the vectors turns out to have a lot more utility than one based on the sine of the angle. The cross product only makes sense in three-space and seven-space. The dot product makes sense in any space.

Share this post


Link to post
Share on other sites

Alot of good arguments.

 

A comment the cross product "making sense". The cross product only exists in those dimension because it is required to be perpendicular to both the vectors that are crossed. Right?

Share this post


Link to post
Share on other sites
A comment the cross product "making sense". The cross product only exists in those dimension because it is required to be perpendicular to both the vectors that are crossed. Right?

No. Note that I said [math]\mathbb R^3[/math] and [math]\mathbb R^7[/math] -- but not [math]\mathbb R^4[/math] (or anything but 3 and 7).

 

The dot and cross product are but two of many products that can be defined with respect to vectors. One generalization of the cross product is the wedge product. However, the wedge product of two vectors is not a vector. It is a bivector. The cross product is rather unique; it is the only product where the result is also a vector, and a vector that is a member of the same space that contains the multiplicands.

 

The cross product can only be defined for [math]\mathbb R^3[/math] and [math]\mathbb R^7[/math]. What's so special about 3 and 7? The answer is that 3=4-1 and 7=8-1.

 

"Okay, smartass. What's so special about 4 and 8?" The answer is the quaternions and the octonions.

 

One way to represent quaternions is that a quaternion, like a complex number, comprises a real and imaginary part. Unlike complex numbers, the imaginary part of a quaternion is a three vector. The product of two quaternions can be expressed using the dot and cross product. Given two quaternions [math]\mathcal Q_1[/math] and [math]\mathcal Q_2[/math],

 

[math]\mathcal Q_1 = (q_{1,r}\,,\, \mathbf q_{1,v})[/math]

[math]\mathcal Q_2 = (q_{2,r}\,,\, \mathbf q_{2,v})[/math]

 

The product of these quaternions can be expressed as

[math]\mathcal Q_1\,\mathcal Q_2 =

(q_{1,r}q_{2,r}-\mathbf q_{1,v}\cdot\mathbf q_{2,v}\,,\,

q_{1,r}\mathbf q_{2,v} + q_{2,r}\mathbf q_{1,v}

+ \mathbf q_{1,v}\times\mathbf q_{2,v}[/math]

 

What if those two quaternions are pure imaginary quaternions: [math]q_{1,r} = q_{2,r} = 0[/math]? The above reduces to

 

[math]\mathcal Q_1\,\mathcal Q_2 =

(-\mathbf q_{1,v}\cdot\mathbf q_{2,v}\,,\,

\mathbf q_{1,v}\times\mathbf q_{2,v})[/math]

 

In other words, the quaternion product of two pure imaginary quaternion comprises real and imaginary parts that are respectively equal to the dot product (negated) and the cross product of the imaginary parts of those two quaternions.

 

What goes around comes around. The dot product and cross product for three vectors can be expressed in terms of the quaternion product. In fact, this is one of the two independent paths by which our modern view of vectors arose. (Aside: If you read Thomas Pynchon, the war between the quaternionists and vectorialists plays a part in his novel "Against the Day.")

 

The question is, can this concept be extended to higher dimensions? The answer is yes: To [math]\mathbb R^7[/math]. First though, an aside on these different algebras. The complex numbers can be viewed as an extension of the reals, the quaternions as an extension of the complex numbers, and so on. Each step up the chain doubles the dimensionality. The reals are one dimensional, the complex numbers are two dimensional, the quaternions four dimensional, and so on. Each step adds something (e.g., with the complex numbers you can now solve equations like [math]x^2+1=0[/math]) but also takes something away. The reals can be sorted; the complex numbers cannot. The reals and complex numbers are commutative ([math]ab=ba[/math]); the quaternions are not.

 

The next step up the chain after the quaternions are the octonions. These are 8 dimensional things. As mentioned before, something is lost with each step up the chain. What is lost with the octonions is that they are no longer associative: [math](ab)c \ne a(bc)[/math] in general for the octonions. This is not a big enough loss to preclude the construction of a cross product for [math]\mathbb R^7[/math].

 

How about higher dimensions? Nope. octonions are still alternative: [math]a(ab) = (aa)b[/math]. The next step up after the octonions, the sedonions, are not alternative. It turns out that alternativity is an essential property for defining the cross product in the manner first used by Gibbs, Wilson, and Heaviside. The cross product is unique to [math]\mathbb R^3[/math] and [math]\mathbb R^7[/math].

Edited by D H

Share this post


Link to post
Share on other sites

Interesting stuff!

 

A few questions.

What are "r" and "v" supposed to indicate in the quaternions?

I will repeat; "Okay, smartass. What's so special about 4 and 8?". I fail to see the connection between the 4 and 8 and the 3 and 7.

Share this post


Link to post
Share on other sites
A few questions.

What are "r" and "v" supposed to indicate in the quaternions?

First, the complex numbers: They have a scalar real part and a scalar imaginary part. One way to represent quaternions is that they too have real and imaginary parts. The real part is still a scalar but the imaginary part is now a 3-vector. The "r" designates the (scalar) real part of a quaternion while the "v" represents the designates the vectorial (imaginary) part of the quaternion. To be consistent I should have used "s" to designate the scalar (real) part.

 

The octonions are similar. They can be represented as having a scalar real part and an imaginary part that is a 7-vector.

 

I will repeat; "Okay, smartass. What's so special about 4 and 8?".

The quaternions and the octonions are respectively 4 and 8 dimensional thingies.

 

I fail to see the connection between the 4 and 8 and the 3 and 7.

Snarky response: 3=4-1, and 7=8-1. Not so snarky, 3 is the dimensionality of the imaginary part of a quaternion while 7 is the dimensionality of the imaginary part of an octonion.

Share this post


Link to post
Share on other sites

You can also think of it in terms of Hurwitz's theorem. As DH has noted bilinear multiplication on [math]V \oplus R[/math] is important ([math]V[/math] is the Euclidean vector space under question ). I forget any details, (see DH's post) but the existence of the cross product is equivalent to the bilinear multiplication forming a normed division algebra over [math]R[/math].

 

Hurwitz's theorem states that (up to isomorphisms) the only normed division algebras are the real numbers, the complex numbers, the quaternions and the octonions.

 

So there exists a cross product in 0, 1, 3, 7 dimensions. The first two are trivial.

Share this post


Link to post
Share on other sites

Okay, so v and r are just to clarify the parts (although you already bolded the vectors).

 

As I understand your snarky response (through your not so snarky) is that the cross product "naturally" arises in the quaternions "imaginary" part from the definition of quaternions. the Tesponse 4=3-1 is due to q-nions are 4-dimensional, and the cross product only occurs in three of those?

 

Thanks for the insight. I will have a readup on quaternions. It looks interesting.

Share this post


Link to post
Share on other sites

I think you missed a key point. I said "What goes around comes around. The dot product and cross product for three vectors can be expressed in terms of the quaternion product."

 

I showed how the quaternion product can be expressed in terms of the dot product and cross product. That is, as is much of math and physics, an after the fact presentation. What happened in history was that the quaternion product was defined first; i.e. without using the dot and cross product. Gibbs & Heaviside developed our modern vector mathematics as an offshoot of the Hamilton's quaternions. In particular, they showed how to first define the dot product and cross product in terms of the quaternion product. Only then did they show how to do it without the quaternion stuff.

 

BTW, there are still a few vestiges of the quaternion heritage in our vector notation. Sometimes you will see the unit vectors designated as [math]\hat x[/math], [math]\hat y[/math], and [math]\hat z[/math], but other times as [math]\hat i[/math], [math]\hat j[/math], and [math]\hat k[/math]. The x,y,z hat stuff makes sense, but where does that i,j,k stuff come from. The answer to that is some graffiti Hamilton drew on a bridge in Dublin: [math]i^2=j^2=k^2=ijk=-1[/math] His i, j, and k represented the three different imaginary units (c.f. i in the complex numbers). His i, j, and k became [math]\hat i[/math], [math]\hat j[/math], and [math]\hat k[/math] in the initial development of vector analysis.

Share this post


Link to post
Share on other sites
When defining the dot product, the cosine of the angle between two vectors is chosen. Why not the sine?

 

What advantages are there by choosing the cosine?

 

hobz ,i wonder why you don't look for an explanation in WIKIPEDIA ,the explanation there is excellent.

 

Vector dot product is very common concept and the WEB is full of it

Share this post


Link to post
Share on other sites
I think you missed a key point. I said "What goes around comes around. The dot product and cross product for three vectors can be expressed in terms of the quaternion product."

 

I showed how the quaternion product can be expressed in terms of the dot product and cross product. That is, as is much of math and physics, an after the fact presentation. What happened in history was that the quaternion product was defined first; i.e. without using the dot and cross product. Gibbs & Heaviside developed our modern vector mathematics as an offshoot of the Hamilton's quaternions. In particular, they showed how to first define the dot product and cross product in terms of the quaternion product. Only then did they show how to do it without the quaternion stuff.

 

BTW, there are still a few vestiges of the quaternion heritage in our vector notation. Sometimes you will see the unit vectors designated as [math]\hat x[/math], [math]\hat y[/math], and [math]\hat z[/math], but other times as [math]\hat i[/math], [math]\hat j[/math], and [math]\hat k[/math]. The x,y,z hat stuff makes sense, but where does that i,j,k stuff come from. The answer to that is some graffiti Hamilton drew on a bridge in Dublin: [math]i^2=j^2=k^2=ijk=-1[/math] His i, j, and k represented the three different imaginary units (c.f. i in the complex numbers). His i, j, and k became [math]\hat i[/math], [math]\hat j[/math], and [math]\hat k[/math] in the initial development of vector analysis.

 

Very interesting. So the quaternion came first.

Can you recommend some reading on the history of this, and perhaps math in general? It helps quite a deal to know the chronology and history behind.


Merged post follows:

Consecutive posts merged
hobz ,i wonder why you don't look for an explanation in WIKIPEDIA ,the explanation there is excellent.

 

Vector dot product is very common concept and the WEB is full of it

 

I have. The explanation from Wikipedia is more a general introduction, where as I am seeking a more intuitive way of thinking about the dot product. For instance, from the definition (given at wikipedia) all else follows which in turn is the motivation for the definition. Sort of a chicken-egg to me. I enjoyed DH's historically based answer, which had a beginning and en end.

 

I came across this, when I tried to arrive at the definition of the dot product, from the geometrical point of view (area of parallelograms).

Here is occured to me, that what the dot product is normally used for (at least to my knowledge) it could just as easily be defined as the sine.

So if [math]\vec{a}\cdot\vec{b} =|\vec{a}||\vec{b}| \sin \theta[/math]

then [math] \vec{a} \perp \vec{b} \Rightarrow \vec{a}\cdot\vec{b} =|\vec{a}||\vec{b}|[/math]

 

However, as DH pointed out, there are some disadvantages with this.

Share this post


Link to post
Share on other sites
When defining the dot product, the cosine of the angle between two vectors is chosen. Why not the sine?

 

What advantages are there by choosing the cosine?

 

Because to project a vector on another, you need to take into account how similar they point, rather than how perpendicular.

Share this post


Link to post
Share on other sites
Very interesting. So the quaternion came first.

Kinda, sorta. Talk to a mathematician and they might well bring up the work of Grassmann. Grassmann's work might well led to the development of modern vector analysis, except it didn't. Grassmann was more or less a contemporary with Hamilton, and the path to modern vector analysis was clearly an offshoot of Hamilton's quaternions. Grassmann's work was folded back in after the fact.

 

A lot of mathematics and science works this way. The pretty picture we have now is not what was initially developed. The development of that pretty package took time, smoothing of some rough edges, and smoothing of some rather rough egos. Physics teachers do teach those rough edges to some extent. For example, understanding the fumblings of the early quantum physicists truly does helps students of physics. For many arenas, however, those initial (mis)steps are a distraction at best. The rough edges of mathematics are, well, rough edges.

 

Can you recommend some reading on the history of this, and perhaps math in general? It helps quite a deal to know the chronology and history behind.

The best of the bunch (a Reader's Digest version of the author's book on the topic):

http://www.math.ucdavis.edu/~temple/MAT21D/SUPPLEMENTARY-ARTICLES/Crowe_History-of-Vectors.pdf

 

A bit shorter:

http://www.math.mcgill.ca/labute/courses/133f03/VectorHistory.html

 

A *lot* longer:

http://deepblue.lib.umich.edu/bitstream/2027.42/7868/5/bad1474.0001.001.pdf

 

An alternate history (no mention of Gibbs and Heaviside whatsoever; Hamilton barely deserves a paragraph):

http://www-groups.dcs.st-and.ac.uk/~history/HistTopics/Abstract_linear_spaces.html

Share this post


Link to post
Share on other sites

Great stuff!

 

Why is it necessary for the quaternions to have the real part, and later set to zero? Why not just have the three imaginary axis?


Merged post follows:

Consecutive posts merged

Ahhh.. since Q1*Q2=Q3 should apply and because the product of the two produce a real part, which has no place to be in a "triternion", you need the real part.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.