Scalar product and generalised coordinates

In summary: V## as n-tuples, and the metric is then used to define the inner product of these n-tuples)In summary, the conversation discusses the equivalence of the scalar product a.b and aibi in Cartesian coordinates and its relation to the Hamiltonian in Hamiltonian mechanics. It is clarified that the inner product of two elements in Rn is defined independently of any set of basis vectors, and that the configuration space for the Hamiltonian is a more general concept. The generalized coordinates for the Hamiltonian can vary, but they must be independent to allow for the familiar-looking diagonal sum in the inner product.
  • #1
dyn
773
62
TL;DR Summary
Scalar Product and generalized coordinates
Hi
If i have 2 general vectors written in Cartesian coordinates then the scalar product a.b can be written as aibi because the basis vectors are an orthonormal basis.
In Hamiltonian mechanics i have seen the Hamiltonian written as H = pivi - L where L is the lagrangian and v is the time derivative of position . I have also seen this written as H= p.v - L.
My question is ; how is pivi equivalent to p.v ? Surely this only applies if p and v are written in an orthonormal basis but are p and v even vectors when written using generalised coordinates and generalised momenta ? Generalised coordinates q can sometimes just be angles and i have never seen any mention of basis vectors in this case.
So is it just a convention that pivi is equivalent to p.v in Hamiltonian mechanics ?
Thanks
 
Physics news on Phys.org
  • #2
yes the inner product in ##\mathbf{R}^n## is defined ##\mathbf{a} \cdot \mathbf{b} = \displaystyle{\sum_i} a_i b_i##. in the lagrangian and hamiltonian formalisms, the vector ##\mathbf{q} = (q_1, \dots, q_n)##, the vector ##\dot{\mathbf{q}} = (\dot{q}_1, \dots, \dot{q}_n)##, the vector ##\mathbf{p} = (p_1, \dots, p_n)##, etc. are vectors in ##\mathbf{R}^n##
 
  • #3
Thanks. So is this just a convention ? As opposed to the 3-D case where it only applies in the case of orthonormal basis vectors ?
 
  • #4
definitely not a convention - one does not need to even introduce a basis of ##\mathbf{R}^n## to determine the inner product of two of its elements

say you do have some arbitrary basis ##\{ \mathbf{e}_1, \dots, \mathbf{e}_n \}## of n-tuples in ##\mathbf{R}^n##, this means any ##\mathbf{v} = (v_1, \dots, v_n) =\sum_i \tilde{v}_i \mathbf{e}_i \in \mathbf{R}^n## can be taken to some other n-tuple ##(\tilde{v}_1, \dots, \tilde{v}_n)##, its "representation" in the basis

of course now in this representation ##\mathbf{a} \cdot \mathbf{b} = \sum_i \sum_j \tilde{a}_i \tilde{b}_j \mathbf{e}_i \cdot \mathbf{e}_j \equiv \sum_i \sum_j g_{ij} \tilde{a}_i \tilde{b}_j##, and if the basis is not orthonormal then ##g_{ij} \neq \delta_{ij}##
 
  • #5
ergospherical said:
of course now in this representation ##\mathbf{a} \cdot \mathbf{b} = \sum_i \sum_j \tilde{a}_i \tilde{b}_j \mathbf{e}_i \cdot \mathbf{e}_j \equiv \sum_i \sum_j g_{ij} \tilde{a}_i \tilde{b}_j##, and if the basis is not orthonormal then ##g_{ij} \neq \delta_{ij}##
You have just stated that a.b = aibi only if the basis is orthonormal .

So why in Hamiltonian mechanics is p.v written as pivi without knowing if the basis is orthonormal or not. To be honest i don't even know if generalised coordinates such as angles have a basis
 
  • #6
no you are missing the point! elements of ##\mathbf{R}^n## are lists of numbers and a priori you don't need any basis of any kind

you only worry about the metric when working with representations of elements of ##\mathbf{R}^n## with respect to some particular basis of tuples (orthonormal or not), as in post 4
 
  • #7
I do not understand. When working with 3-D vectors a.b only equals aibi if the basis vectors of a and b are orthonormal. Is that correct ?
So i do not understand how p.v can be written as pivi without knowing anything about basis vectors and if they are orthonormal or not
 
  • #8
dyn said:
You have just stated that a.b = aibi only if the basis is orthonormal .
No, that's not at all what @ergospherical is saying. He's not saying anything about whatever basis is involved.
Also, the equation you wrote is incorrect. The right side should be a summation; i.e., ##\sum a_i b_i##, where i ranges from 1 to n in the case of vectors in ##\mathbb R^n##.
dyn said:
So why in Hamiltonian mechanics is p.v written as pivi
Same comments as above.
dyn said:
When working with 3-D vectors a.b only equals aibi if the basis vectors of a and b are orthonormal. Is that correct ?
Again, no.
 
  • #9
ergospherical said:
no you are missing the point! elements of Rn are lists of numbers and a priori you don't need any basis of any kind

you only worry about the metric when working with representations of elements of Rn with respect to some particular basis of tuples (orthonormal or not), as in post 4

I believe the issue of confusion here is what is the n in the Hamiltonian formulation. This is loosely the number of degrees of freedom of the problem (k particles in m dimensions would be ##n=k*m##) and the sum is over all n . All the rest is dividing the baby.
Shoot me if I'm wrong...
 
  • #10
#9 is telling me that the following statement is incorrect ;

In 3-D ; a.b = aibi only when the basis vectors are orthonormal

Every textbook i have ever read says that my statement above is correct
 
  • #11
For elements of a 3D vector space space your statement is correct.

The configuration space for the Hamiltonian is a more general beast.
Please read this carefully and then see if your questions are put in better context:
https://en.wikipedia.org/wiki/Generalized_coordinates

The generalized coordinates for the Hamiltonian can be various. I believe they are required to be independent which always allows the inner product to be written in the familiar-looking diagonal sum. (This is stuff I learned 50 yrs ago so anybody feel free to correct me! )
 
  • #12
hutchphd said:
For elements of a 3D vector space space your statement is correct.

The configuration space for the Hamiltonian is a more general beast.
Please read this carefully and then see if your questions are put in better context:
https://en.wikipedia.org/wiki/Generalized_coordinates

The generalized coordinates for the Hamiltonian can be various. I believe they are required to be independent which always allows the inner product to be written in the familiar-looking diagonal sum. (This is stuff I learned 50 yrs ago so anybody feel free to correct me! )
@hutchphd I hate to say it but this is irrelevant, because the inner product of two elements of ##R^n## is defined independently of the notion of any set of basis vectors

##\mathbf{p}## is a list of numbers, ##\dot{\mathbf{q}}## is a list of numbers, and ##\mathbf{p} \cdot \dot{\mathbf{q}} = \displaystyle{\sum_i} p_i \dot{q}_i## is their inner product

(you only worry about using the metric when you have a vector space isomorphism ##V \rightarrow R^n## from ##V## (any vector space of finite dimension ##n##) to a coordinate space of ##n##-tuples with elements in ##R## - this isomorphism is induced by selecting a basis of ##V##. note that ##V## can also be ##R^n##, in which case the vector and its representation are the same types of objects)
 
  • #13
I like being contradicted, and I'm sure I may well have misstated this. I do understand your point, but I do not think I have said otherwise.
If I remember correctly the reason the Hamiltonian can be written in this form follows from the independence of the generalized coordinates (this is a physics constraint). In the end the choice of basis and representation for these coordinates is of crucial importance to make the problem tractable. These two processes were being intermingled in the OP, and my attempt is to describe this comingling in the way I understand it.
Please do correct as necessary (relevancy is in the eye of the beholder, however).
 
  • #14
no the generalised coordinates are independent (by definition), but this has nothing to do with the ability to use vector notation as opposed to summation notation

to transform one set ##(q,\dot{q})## of independent variables to another set ##(q, p)## one effects a legendre transformation\begin{align*}
dL &= \sum_i \dfrac{\partial L}{\partial q^i} dq_i + \sum_i \dfrac{\partial L}{\partial \dot{q}^i} d\dot{q}^i \\

dL &= \sum_i \dot{p}_i dq^i + \sum_i p_i d\dot{q}^i \\

-\sum_i \dot{p}_i dq^i + \sum_i \dot{q}^i dp_i &= d(\sum_i p_i \dot{q}^i - L) \equiv dH

\end{align*}i.e. ##H \equiv \sum_i p_i \dot{q}^i - L## or equivalently ##H \equiv \mathbf{p} \cdot \dot{\mathbf{q}} - L## where these are n dimensional vectors
 
Last edited:
  • #15
ergospherical said:
no the generalised coordinates are independent (by definition)
Perhaps I don't understand what independent means in this context.
 
  • #16
hutchphd said:
For elements of a 3D vector space space your statement is correct.

The configuration space for the Hamiltonian is a more general beast.
Please read this carefully and then see if your questions are put in better context:
https://en.wikipedia.org/wiki/Generalized_coordinates

The generalized coordinates for the Hamiltonian can be various. I believe they are required to be independent which always allows the inner product to be written in the familiar-looking diagonal sum. (This is stuff I learned 50 yrs ago so anybody feel free to correct me! )
Of course you are not bound to the special case, where the metric components are diagonal. The Lagrange formalism is completely invariant under general diffeomorphisms, the Hamilton formalism even under general symplectomorphisms (canonical transformations) of phase-space variables.
 
  • Like
Likes hutchphd
  • #17
It seems to me that the way I was taught this was that there is

ergospherical said:
definitely not a convention - one does not need to even introduce a basis of ##\mathbf{R}^n## to determine the inner product of two of its elements

say you do have some arbitrary basis ##\{ \mathbf{e}_1, \dots, \mathbf{e}_n \}## of n-tuples in ##\mathbf{R}^n##, this means any ##\mathbf{v} = (v_1, \dots, v_n) =\sum_i \tilde{v}_i \mathbf{e}_i \in \mathbf{R}^n## can be taken to some other n-tuple ##(\tilde{v}_1, \dots, \tilde{v}_n)##, its "representation" in the basis

of course now in this representation ##\mathbf{a} \cdot \mathbf{b} = \sum_i \sum_j \tilde{a}_i \tilde{b}_j \mathbf{e}_i \cdot \mathbf{e}_j \equiv \sum_i \sum_j g_{ij} \tilde{a}_i \tilde{b}_j##, and if the basis is not orthonormal then ##g_{ij} \neq \delta_{ij}##

ergospherical said:
@hutchphd I hate to say it but this is irrelevant, because the inner product of two elements of ##R^n## is defined independently of the notion of any set of basis vectors

##\mathbf{p}## is a list of numbers, ##\dot{\mathbf{q}}## is a list of numbers, and ##\mathbf{p} \cdot \dot{\mathbf{q}} = \displaystyle{\sum_i} p_i \dot{q}_i## is their inner product

(you only worry about using the metric when you have a vector space isomorphism ##V \rightarrow R^n## from ##V## (any vector space of finite dimension ##n##) to a coordinate space of ##n##-tuples with elements in ##R## - this isomorphism is induced by selecting a basis of ##V##. note that ##V## can also be ##R^n##, in which case the vector and its representation are the same types of objects)

You have forced me to blow the dust off my copy of Nomizu "Fundamentals of Linear Algebra" (guite a lot of dust!)

I see that this is mostly an issue with nomenclature. Nomizu, after defining addition and scalar multiplication, defines ##\mathbf{R}^n## as the n-dimensional standard real vector space. In addition he defines the standard basis as the set of n n-tuples $$ (1,0,0...,0)$$ $$(0,1,0,...,0)$$ $$etc$$

He then defines the inner product in terms of the standard (manifestly orthonormal) basis, and makes provision for how to change bases. I much prefer this (and hopefully @dyn will) to just saying " you don't need no stinkin' bases" **

Nomizu is a pretty good text!...

**Treasure of the Sierra Madre
 
  • #18
again, you do not need any basis set to define the inner product of two vectors in ##R^n## (the space of n-tuples with real elements)

the "standard basis" ##E = \{ (0,\dots, \underbrace{1}_{\mathrm{i^{\mathrm{th}}} \, \mathrm{position}}, \dots, 0) \}## of ##R^n## is distinguished in that every ##v \in R^n## is equal to its representation ##[v]_E## with respect to this basis, i.e. ##v = [v]_E##

see e.g. Halmos
 
  • #19
Under what circumstance does this make a difference? Are we parsing words here or am I missing something important?
 
  • #20
it's not important but its worth to understand the distinction

on ##R^n## (n-dimensional tuple space) there is a canonical inner product ##\mathbf{x} \cdot \mathbf{y} = \sum x_i y_i##
where ##\mathbf{x} = (x_1, \dots, x_n)## and ##\mathbf{y} = (y_1, \dots, y_n)##
[no mention of any basis set]

then, given any other finite ##n##-dimensional vector space [including ##R^n##], an inner product can be chosen by mapping each vector to ##R^n## (by choice of a basis), and using the canonical inner product on ##R^n##

e.g. #1 choose a basis ##B = (1,x,x^2)## on the polynomial space ##P_2(R)##, and let ##\varphi## be the standard representation with respect to ##B## i.e. ##\varphi(a_0 + a_1 x + a_2 x^2) = (a_0,a_1,a_2)##, then you can define\begin{align*}
\langle a_0 + a_1 x + a_2 x^2, b_0 + b_1 x + b_2 x^2 \rangle \equiv (a_0,a_1,a_2) \cdot (b_0,b_1,b_2) = a_0 b_0 + a_1 b_1 + a_2 b_2
\end{align*}

e.g. #2 choose a basis ##B = \{ (\cos{\theta}, \sin{\theta}), (-\sin{\theta}, \cos{\theta}) \} \equiv \{\mathbf{x}_1, \mathbf{x}_2 \}## of ##R^2##. one can define a map from vectors in ##R^2## to their representations in this rotated basis (which happen to also live in ##R^2##)\begin{align*}
\mathbf{v} &\mapsto [\mathbf{v}]_B \\
(v_1, v_2) &\mapsto (v_1', v_2') = (v_1 \cos{\theta} + v_2 \sin{\theta}, -v_1 \sin{\theta} + v_2 \cos{\theta})
\end{align*}
given two vectors ##\mathbf{u}, \mathbf{w} \in R^2##, one can find their inner product either directly,\begin{align*}
\mathbf{u} \cdot \mathbf{w} = u_1 w_1 + u_2 w_2
\end{align*}or by their representations in the basis\begin{align*}
\mathbf{u} \cdot \mathbf{w} = \sum_{i,j} (u_i' \mathbf{x}_i) \cdot (w_j' \mathbf{x}_j) = \sum u_i' w_j' \mathbf{x}_i \cdot \mathbf{x}_j = \sum u_i' w_i' = u_1' w_1' + u_2' w_2'
\end{align*}where it is simple in this case since ##\mathbf{x}_i \cdot \mathbf{x}_j = \delta_{ij}##
 
Last edited:
  • #21
I understand that is how you learned it (which is fine) but it is operationally identical I believe. One could call the standard basis the "canonical" basis and (other than the slightly religious overtones) nothing changes. For me it is a cleaner definition and makes @dyn question vanish. If I misunderstand some implication of this I would really like to know. Thanks.
 
  • #22
I don't know how to explain this any more clearly because you are missing the point

it is by definition that ##R^n## is a space of ##n##-tuples and the canonical inner product on ##R^n## is given by ##u \cdot v =\displaystyle{ \sum_i} u_i v_i##. you may see any book, Halmos, Axler, Spivak, Rudin, etc. You do not need the additional structure of a basis [a set of linearly independent elements of ##R^n## itself which span ##R^n##] in order to define this inner product

maybe it is easier to see like this: even if you introduce the standard basis [the set of tuples with ##1## in the ##ith## position and ##0## in the rest] you require a method to compute the inner products ##\mathbf{e}_i \cdot \mathbf{e}_j## of these vectors, which of course brings you back to the canonical definition

[the "standard" basis really is only distinguished by the property that ##v = [v]_E##, other than that it is nothing special]
 
  • #23
ergospherical said:
maybe it is easier to see like this: even if you introduce the standard basis [the set of tuples with 1 in the ith position and 0 in the rest] you require a method to compute the inner products ei⋅ej of these vectors, which of course brings you back to the canonical definition
So can we agree that a more useful answer to the question
dyn said:
You have just stated that a.b = aibi only if the basis is orthonormal .

So why in Hamiltonian mechanics is p.v written as pivi without knowing if the basis is orthonormal or not. To be honest i don't even know if generalised coordinates such as angles have a basis
might be the following: "One can always define the standard basis (manifestly orthonormal as discussed ) and so there is no contradiction."

Seems better than "we don't need no stinking basis"
 
Last edited:
  • #24
that doesn't make any sense, because the standard basis [a concept only defined on vector spaces of type ##F^n##] is nothing but that set of vectors with ##1## in the ##ith## place and ##0## in the rest, in otherwords it's trivially defined
hutchphd said:
Seems better than "we don't need no stinking basis"
is facetious

i'm sorry but you're simply wrong
why do you cling so strongly to the concept of bases?
 
  • #25
This is a vector space of the type ##R^n## . I truly do not know what I have said that makes no sense...can you please be more specific?
 
  • #26
this
hutchphd said:
"One can always define the standard basis (manifestly orthonormal as discussed ) and so there is no contradiction."
is contentless. of course you can "always" define the standard basis of ##R^n##, it's simply ##\{ (1,\dots, 0), (0,1,\dots,0), \dots \}##. of course it's orthonormal using the canonical inner product

you do not need any basis sets to define inner product in R^n

this whole thread is ridiculous
i will not answer more questions on this subject because my pprevious posts are sufficient
 
  • Like
Likes Delta2
  • #27
Arguments fundamentally about dogma always are.
 
  • #28
In physics it's very important to distinguish vectors (tensors) from from their components wrt. a basis. It took me a lot of struggle to understand vectors, because many textbooks don't make this simple distinction. Particularly the also very important subject of basis changes and the various subgroups of the general linear group becomes very lucid.
 
  • Like
Likes Delta2 and ergospherical
  • #29
vanhees71 said:
In physics it's very important to distinguish vectors (tensors) from from their components wrt. a basis. It took me a lot of struggle to understand vectors, because many textbooks don't make this simple distinction. Particularly the also very important subject of basis changes and the various subgroups of the general linear group becomes very lucid.
Yes, and in particular when the underlying vectors are elements of the space ##R^n##, since then both the vector ##\mathbf{v} = (v_1, \dots, v_n)## and its representation ##[\mathbf{v}]_B = \varphi_B(\mathbf{v})## with respect to ##B## are real ##n##-tuples.

[where, if ##B = \{ \mathbf{x}_i \}## with ##\mathbf{x}_i## a set of linearly independent ##n##-tuples which span ##R^n##, then ##\varphi_B## is a linear map defined by ##\varphi_B(\mathbf{x}_i) = (0,\dots, 1, \dots 0)## with ##1## in the ##ith## position]
 
  • Informative
  • Like
Likes vanhees71 and Delta2
  • #30
vanhees71 said:
In physics it's very important to distinguish vectors (tensors) from from their components wrt. a basis.
I do think I understand this well enough. That being said I again sincerely invite criticism of my reply to the OP question about dot product and orthonormal basis:
hutchphd said:
So can we agree that a more useful answer to the question
might be the following: "One can always define the standard basis (manifestly orthonormal as discussed ) and so there is no contradiction."
Is this incorrect in some way?
 
  • Sad
Likes ergospherical
  • #31
I don't know, what you mean by "standard basis". We have an Euclidean vector space ##V## with a scalar product. A Cartesian basis ##\vec{e}_i## fulfills by definition the propery ##\vec{e}_i \cdot \vec{e}_j=\delta_{ij}##, and each vector can be uniquely written in terms of linear combinations of these Cartesian basis vectors,
$$\vec{v}=v^j \vec{e}_j.$$
Here the Einstein summation convention is used, i.e., over equal indices you have to sum. The numbers ##v^j## are the components of the vector ##\vec{v}## wrt. the Cartesian basis.

For the scalar product of two vectors you get
$$\vec{v} \cdot \vec{w} = (v^j \vec{e}_j) \cdot (w^k \vec{e}_k)= v^j w^k \delta_{jk}=w^j v^j.$$
This holds for the components wrt. any Cartesian basis. There is not any special "standard basis".
 
Last edited:
  • #32
hutchphd said:
For elements of a 3D vector space space your statement is correct.

The configuration space for the Hamiltonian is a more general beast.
Please read this carefully and then see if your questions are put in better context:
https://en.wikipedia.org/wiki/Generalized_coordinates

The generalized coordinates for the Hamiltonian can be various. I believe they are required to be independent which always allows the inner product to be written in the familiar-looking diagonal sum. (This is stuff I learned 50 yrs ago so anybody feel free to correct me! )
This hints that the basis vectors are orthogonal which helps.

If i have 2 vectors a = aiei and b = biei then consider the basis vectors are not orthonormal then in the scalar product a.b i will end up with term like a1b2e1.e2 which means in this case a.b≠ aibi
 
  • #33
vanhees71 said:
For the scalar product of two vectors you get
vanhees71 said:
For the scalar product of two vectors you get
v→⋅w→=(vje→j)⋅(wke→k)=vjwkδjk=vjvj.
This holds for the components wrt. any Cartesian basis. There is not any special "standard basis".
I assume you mean ##\omega _j## in last

The "standard basis" is the name I was taught for the trivial set of n-tuples {(1,0,...,0),(0,1,...0),...(0,...,0,1)} associated with ##R^n## and the canonical coordinates.
 
  • Like
Likes vanhees71
  • #34
Sure, I've corrected it in the posting above.
 

FAQ: Scalar product and generalised coordinates

What is a scalar product?

A scalar product, also known as a dot product, is a mathematical operation that takes two vectors and returns a single scalar value. It is calculated by multiplying the magnitude of one vector by the magnitude of the other vector and then multiplying that result by the cosine of the angle between the two vectors.

How is a scalar product related to generalised coordinates?

A scalar product can be used to calculate the work done by a force in a given direction, which is important in the study of generalised coordinates. It is also used in the Lagrangian formulation of classical mechanics, where it is used to express the kinetic energy of a system in terms of generalised coordinates.

Can a scalar product be negative?

Yes, a scalar product can be negative if the angle between the two vectors is greater than 90 degrees. This indicates that the two vectors are pointing in opposite directions.

How is a scalar product different from a vector product?

A scalar product returns a single scalar value, while a vector product returns a vector that is perpendicular to both of the original vectors. Additionally, a scalar product is commutative (A · B = B · A), while a vector product is anti-commutative (A x B = -B x A).

How is a scalar product used in physics?

A scalar product has many applications in physics, including calculating work and energy, determining the angle between two vectors, and expressing physical quantities in terms of generalised coordinates. It is also used in the study of forces, motion, and energy in classical mechanics and electromagnetism.

Similar threads

Replies
12
Views
534
Replies
2
Views
2K
Replies
30
Views
6K
Replies
1
Views
1K
Replies
19
Views
2K
Back
Top