# Calculus of Variations. Lagrangian Hamiltonian Mechanics Mathpages.

Over at http://www.mathpages.com/home/kmath523/kmath523.htm is an article about Lagrangian and Hamiltonian Mechanics with a derivation of the Euler-Lagrange equations of motion.

Mid-way through is this statement:

"Variations in x,y,z and X at constant t are independent of t (since each of these variables is strictly a function of t), so we have"

$\frac{\partial x} {\partial X} = \frac {\partial \dot x} {\partial \dot X}$ ; $\frac{\partial y} {\partial X} = \frac {\partial \dot y} {\partial \dot X}$ ; $\frac{\partial z} {\partial X} = \frac {\partial \dot z} {\partial \dot X}$

Can someone please explain why this is true. To me it seems wrong because by applying the chain rule I get:

$\frac {\partial \dot x} { \partial \dot X} = \frac {\partial (\frac {dx} {dt})} {\partial (\frac {dX} {dt})}$ $= \frac {\partial (\frac {\partial x} {\partial X}\frac {dX} {dt} + \frac {\partial x} {\partial Y}\frac {dY} {dt}) } {\partial (\frac {dX} {dt})}$ $= \frac {\partial (\frac {\partial x}{\partial X}\frac{dX}{dt})} { \partial (\frac {dX} {dt})} + \frac {\partial (\frac {\partial x} {\partial Y}\frac {dY} {dt}) } {\partial (\frac {dX} {dt})}$ $= \frac {\partial x} { \partial X} + \frac {\frac {\partial x} {\partial Y} \dot Y } {\dot X}$ $\ne \frac {\partial x} { \partial X}$

Thanks

• FYI you can format your equations better with Mathjax. – Null Dec 19 '14 at 3:33
• Feel free to add your solution as an answer to this question. This will help the system understand that this question has an answer, and you can gain more reputation for it. – Null Dec 19 '14 at 5:31

It is confusing because there is some serious abuse of notation going on in classical mechanics and it results in unclarity when taking partial derivatives. Let's see what's going on:

We have two coordinate systems $(x,y), (X,Y)$ related by a transformation $(x,y)=(x(X,Y),y(X,Y))$ and we have a curve $\displaystyle (X,Y)=(X(t),Y(t))$ (see I have already abused notation), so we have a curve $\displaystyle (x,y)=(x(X(t),Y(t)),y(X(t),Y(t)))\,.$ Using chain rule we get $\displaystyle \dot{x}=\frac{\partial x}{\partial X}\dot{X}+\frac{\partial x}{\partial Y}\dot{Y}.$ There has been some abuse of notation so far, but I can make sense of everything, and in fact this notation is unfortunately standard. Now doing the obvious thing gives you what you want.

But the last part is one which I find confusing; what does $\displaystyle \frac{\partial \dot{x}}{\partial\dot{X}}$ really mean? Is it a directional derivative of some sort? I think this part was never really clear to me.

• x,y,z are cartesian coordinates and X,Y are generalized coordinates, for example X could be the angle of one pendulum and Y could be the angle of a second pendulum suspended from the first one, all in a system where those two angles are the only degrees of freedom. So $\frac {\partial \dot x} {\partial \dot X}$ is how much the velocity in the x direction would vary given a variation in the velocity of the pendulum. – czachoczacho Dec 19 '14 at 16:32

I think I answered my own question after writing this in MathJax. If I had

$\frac {\partial{(Ax + By)}} {\partial x} = A$

Then

$\frac {\partial \dot x} { \partial \dot X} = \frac {\partial (\frac {dx} {dt})} {\partial (\frac {dX} {dt})}$ $= \frac {\partial (\frac {\partial x} {\partial X}\frac {dX} {dt} + \frac {\partial x} {\partial Y}\frac {dY} {dt}) } {\partial (\frac {dX} {dt})}$ $= \frac {\partial (\frac {\partial x}{\partial X}\frac{dX}{dt})} { \partial (\frac {dX} {dt})} + 0$ $= \frac {\partial x} { \partial X}$

Since the differentiation is with respect to $\frac {dX}{dt}$, which does not appear in the terms involving Y.