# Variation of Lagrangian w/r to canonical momenta

• A
muscaria
Hi,
I've been working through Cornelius Lanczos book "The Variational Principles of Mechanics" and there's something I'm having difficulty understanding on page 168 of the Dover edition (which is attached). After introducing the Legendre transformation and transforming the Lagrangian equations of motion into their canonical form, he is now trying to motivate a ("extended") variational principle which gives rise directly to Hamilton's equations of motion, in which the action integral is varied w/r to the 2n positional phase space variables ##(q,p)##. Basically, I don't understand the passage from equation (64.1) to (64.2), where he considers the variation of $$L=\sum_{i=1}^n p_i\dot{q}_i - H,$$ with respect to the ##p_i##, which he writes as $$\delta L = \sum_{i=1}^n\left(\dot{q}_i - \frac{\partial H}{\partial p_i}\right)\delta p_i.$$ My problem is aren't the ##\dot{q}_i## a function of ##(q,p)##, so that there should be an extra term?

My attempt at understanding what is going on:
Because of the duality of the Legendre transform, we can write $$L= \sum_{i=1}^n p_i\frac{\partial H}{\partial p_i} - H,$$ so that the variation of ##L## w/r to the ##p_i## in this form, is what we had above but with an extra piece: $$\delta L = \sum_{i=1}^n\left(\dot{q}_i - \frac{\partial H}{\partial p_i}\right)\delta p_i + \sum_{i,j}p_i\frac{\partial^2H}{\partial p_j\partial p_i}\delta p_j.$$ The first term vanishes on account of the duality of the Legendre transformation but what's the meaning of the 2nd term, if there is any? If we follow the assumption that there is no coupling between different canonical momenta (which seems reasonable otherwise conservation of momentum would be violated, right?), then we will only have the diagonal terms of the double sum:##\sum_{i,j} p_i\frac{\partial^2H}{\partial p_j\partial p_i}\delta p_j = \sum_i p_i \frac{\partial^2 H}{\partial p_i^2}\delta p_i##, i.e $$\delta L = \sum_{i=1}^n\left(\dot{q}_i - \frac{\partial H}{\partial p_i}\right)\delta p_i + \frac{1}{2}\sum_i \frac{\partial^2 H}{\partial p_i^2}\delta (p_i)^2.$$ Is this suggesting in some way that a variation of the Lagrangian w/r to the ##p_i## only enters as a second order effect and can be put to 0 given that we are looking for stationary values of the action? Or is there something I'm missing or misinterpreting which will make all of this obvious?
As a side note, you can get to the result if you consider the variation of the action integral w/r to the ##p_i## (as opposed to variation of the bare Lagrangian) then integration by parts shows that there is no variation of the action from arbitrary variations of the ##p_i##, so all fine, you can still form the ##2n## differential equations in the way he does on page 169, but still, I'd like to understand how he can just go between those 2 equations.. To me it seems like what he is getting at only works if the variation is integrated out w/r to time, we need that integration by parts.
Thanks for your help and I hope this message reaches you in good spirits!

#### Attachments

• Canonical Integral_Lanczos.pdf
145.4 KB · Views: 190

secur
To compute the coefficient of the variation of p you use the partial derivative NOT the total derivative. The qdot's have no explicit dependence on p, so they're just constants. True, in the physical space there is a dependence - which would have to be taken into account if, for some reason, you were taking a total derivative here (which actually wouldn't make much sense). But for the partial, qdots are constants multiplying p so you get simply qdot for that first term in 64.2, coming from the first term in 64.1.

As for what you tried to do in your "attempt at understanding what is going on" - it may work out somehow; I didn't examine it. Certainly not the right way to go, though you get points for trying!

Last edited:
When I first learned about Lagrangian mechanics and that q and qdot were to be treated as formally independent variables, I was similarly confused. How can q and qdot be independent if qdot is fully determined by q? It finally made sense to me when I realized that the Lagrangian (and Hamiltonian) are defined not just along the path of the motion, but on all possible potential paths. In the case of Hamiltonian, H is a function of p and q, and p and q are just coordinates, not the actual position and momentum. You can ask, what is the energy at this instant if the position is q and the momentum is p, regardless of if the system will actually reach that point in phase space. Therefore, p and q are independent. The advantage of this formulism is that you can use it for quantum mechanics, where there is no precise trajectory.

muscaria
Hi guys, thank you for your responses and apologies for the rather late reply!
When I first learned about Lagrangian mechanics and that q and qdot were to be treated as formally independent variables, I was similarly confused. How can q and qdot be independent if qdot is fully determined by q?
This was not what I was confused about, ##\dot{q}## is only determined by ##q(t)##, i.e once you have solved the equations of motion.. they're independent dynamical variables which need to be specified independently of each other in order for a given solution trajectory to be taken - I get that. Without meaning to be presumptuous and I appreciate the response, from your reply I think you may have misunderstood/overlooked what I was asking. My question was basically, if the "new" dynamical space is the set of independent dynamical variables ##(q,p)##, then any function ##f## of the motion (be it actual or tentative) is a function of these dynamical variables -> ##f(q,p)##. The generalised velocities are no different in this respect, i.e. for each point in phase space there is a definite set of associated ##\dot{q}_i=\dot{q}_i(q_1,\cdots,q_n,p_1,\cdots,p_n)##; so my line of thinking was that OK well, a variation of ##p_i## will induce a variation of ##\dot{q}_i##. And so in considering ##\delta L## resulting from ##\delta p_i##, why does ##\delta\dot{q}_i## not play any part?
To compute the coefficient of the variation of p you use the partial derivative NOT the total derivative.
I don't see how I was computing a total derivative..? I computed a partial just in the same way as you would for the following situation say: Given some ##f(x,y)=xg(x,y)## (meant to represent ##p_i\dot{q}_i##), the variation ##\delta f## which results from varying ##x## is simply $$\delta f =\frac{\partial\left(xg(x,y)\right)}{\partial x}\delta x$$
But for the partial, qdots are constants multiplying p so you get simply qdot for that first term in 64.2, coming from the first term in 64.1.
But not because
The qdot's have no explicit dependence on p, so they're just constants
I think I've just finally got it actually, or just about.. the point seems to be that the ##\dot{q}_i## are slopes of a given function in ##(q,p)## space, namely ##\frac{\partial H(q,p)}{\partial p_i}##, so although ##\dot{q}_i=\dot{q}_i(q_1,\cdots,q_n,p_1,\cdots,p_n)## is true, there's a deeper structure which follows from the Legendre transform... It's not simply a point transformation we're carrying out on our dynamical space in going from Lagrangian to Hamiltonian, we're substituting a set of variables by the slope of a given function in this dynamical space. But given that the "new" set of variables correspond to (1st order) slopes in the "old" set of variables,a variation of these will only manifest as a second order effect in the reciprocal space, through the duality of the Legendre Transform and the E-L equations of motion. And the reciprocity is due to the structure of how the E-L e.o.m : ##\dot{p}_i =\frac{\partial L}{\partial q_i}## and the Legendre transform combine. Does this line of reasoning sound reasonable? I guess that's essentially what the calculation that came out in the original post is saying also, because I don't see how it is wrong..