Classical Mechanics – Why Kinetic Energy Can’t Be Replaced by Total Energy Minus Potential Energy in a Lagrangian

actionclassical-mechanicsenergy-conservationlagrangian-formalismvariational-principle

TL;DR: Why can't we write $\mathcal{L} = E – 2V$ where $E = T + V = $ Total Energy?

Let us consider the case of a particle in a gravitational field starting from rest.

Initially, Kinetic energy $T$ is $zero$ and Potential energy $V$ is $mgh$.

At any time $t$, Kinetic energy $T = \frac{m\dot x^2}{2}$ and Potential energy $V$ is $mgx$.

$$\mathcal{L} = T-V = \frac{m\dot x^2}{2}-mgx.$$

If we write $T = mgh-mgx$, the Lagrangian becomes $\mathcal{L} = T-V = mgh-2mgx$ which is independent of $\dot x$ . Here $\frac{d}{dt}\frac{\partial \mathcal{L}}{\partial \dot x} = 0$ while $\frac{\partial \mathcal{L}}{\partial x} = -2mg$.

Why does this simple change of form of Lagrangian not work?

I do understand that this form does not have $\dot x$ but what is the deeper reason for this to not work?

How do I know that my Lagrangian is correct (for any arbitrary problem)?

Best Answer

OP is essentially asking:

Why can't we replace the Lagrangian $L=T-V$ with $L=E-2V$ by using energy conservation $T+V=E$, where $E$ is an integration constant?

Answer: Generically an action principle gets destroyed if we apply EOMs in the action.

Specifically, OP used energy conservation $T+V=E$, which were derived from EOMs. Here it is important to understand that the stationary action principle must be defined for all (sufficiently smooth) paths. Not just the classical trajectories, which satisfy the EOMs. Note in particular, that the off-shell/virtual paths are not required to obey energy conservation.

Alternatively, it is easy to check that OP's proposed Lagrangian $L=E-2V$ would lead to wrong EOMs.

For examples, see this & this related Phys.SE posts.