70

I thought the Hamiltonian was always equal to the total energy of a system but have read that this isn't always true. Is there an example of this and does the Hamiltonian have a physical interpretation in such a case?

Qmechanic
  • 201,751
Noah
  • 1,760
  • 10
    A large class of such examples comes from using accelerating and/or rotating frame of reference. See e.g. Herbert Goldstein, "Classical Mechanics", Chapter 2. – Qmechanic Jul 05 '11 at 21:51
  • See also this interesting answer: https://physics.stackexchange.com/a/194925/226902 – Quillo Apr 19 '23 at 12:18

6 Answers6

28

In an ideal, holonomic and monogenic system (the usual one in classical mechanics), Hamiltonian equals total energy when and only when both the constraint and Lagrangian are time-independent and generalized potential is absent.

So the condition for Hamiltonian equaling energy is quite stringent. Dan's example is one in which Lagrangian depends on time. A more frequent example would be the Hamiltonian for charged particles in electromagnetic field $$H=\frac{\left(\vec{P}-q\vec{A}\right)^2}{2m}+q\varphi$$ The first part equals kinetic energy($\vec{P}$ is canonical, not mechanical momentum), but the second part IS NOT necessarily potential energy, as in general $\varphi$ can be changed arbitrarily with a gauge.

Siyuan Ren
  • 4,932
  • 5
    @Dan: Non-conservative generalized force cannot be written in terms of $Q_i=-\frac{\partial V}{\partial q_i}$, but some of them may be written as $Q_{i}=-\frac{\partial U}{\partial q_{i}}+\frac{d}{dt}\left(\frac{\partial U}{\partial\dot{q_{i}}}\right) $, then if we let $L=T-U$, $L$ will still satisfy the Lagrangian equation. The generalized potential for a charged particle is $q\varphi-q\vec{v}\cdot\vec{A}$. – Siyuan Ren Jul 06 '11 at 05:21
  • 6
    Actually, the Hamiltonian for a charged particle in an electromagnetic field is usually interpreted as the total energy. – Qmechanic Jul 06 '11 at 14:24
  • 1
    @Qmechanic: I never encounter that kind of interpretation. As I said, the physical meaning of the first part is always kinetic energy, but the second part can be arbitrarily changed by a gauge fixing. Is total energy something variant with gauge? – Siyuan Ren Jul 07 '11 at 04:10
  • 4
    @Karsus Ren: As a reference to my above comment, see e.g. Herbert Goldstein, Classical Mechanics, eq. (8-26) in edition 2 or eq. (8.34) in edition 3. – Qmechanic Jul 09 '11 at 15:22
  • Can you give a source for the theorem stated in the answer? I'm curious how it is proven. – Brian Bi Feb 05 '18 at 08:25
  • @BrianBi Check Goldstein Classical Mechanics chapter 8 (3 ed). –  Jun 30 '18 at 21:50
24

The Hamiltonian is in general not equal to the energy when the coordinates explicitly depend on time. For example, we can take the system of a bead of mass $m$ confined to a circular ring of radius $R$. If we define the $0$ for the angle $\theta$ to be the bottom of the ring, the Lagrangian $$L=\frac{mR^2\dot{\theta}^2}{2}-mgR(1-\cos{(\theta)}).$$ The conjugate momentum $$p_{\theta}=\frac{\partial L}{\partial \dot{q}}=mR^2\dot{\theta}.$$ And the Hamiltonian $$H=\frac{p_{\theta}^{2}}{2mR^2}+mgR(1-\cos{\theta}), $$ which is equal to the energy.

However, if we define the $0$ for theta to be moving around the ring with an angular speed $\omega$, then the Lagrangian $$L=\frac{mR^2(\dot{\theta}-\omega)^2}{2}-mgR(1-\cos{(\theta-\omega t)}). $$

The conjugate momentum $$p_{\theta}=\frac{\partial L}{\partial \dot{q}}=mR^2\dot{\theta}-mR^2 \omega.$$

And the Hamiltonian $$H=\frac{p_{\theta}^{2}}{2mR^2}+p_{\theta}\omega+mgR(1-\cos(\theta-\omega t)), $$ which is not equal to the energy (in terms of $\dot{\theta}$ it has an explicit dependence on $\omega$).

Dan
  • 5,685
  • 1
    Your arguement appears incomplete. You write, "which is not equal to the energy (in terms of θ˙ it has an explicit dependence on ω)." I think your answere would be improved if you wrote the energy explicitly. I also think your answer would be clearer if you removed the parenthesis and elucdiated your thought in narrative form. – Michael Levy Sep 24 '22 at 15:27
12

Goldstein's Classical Mechanics (2nd Ed.) pg. 349, section 8.2 on cyclic coordinates and conservation theorems' has a good discussion on this. In his words:

The identification of H as a constant of the motion and as the total energy 
are two separate matters.  The conditions sufficient for one are not 
enough for the other.  

He then goes on to provide an example of a 1-d system in which he chooses two different generalized coordinate systems. For the first choice, H is the total energy while for the second choice H ends up being just a conserved quantity and NOT the total energy of the system.

Check it out. It's a very nice example.

  • 4
    What is the definition of energy here? Is it more than 'what Noethers theorem give you if you consider time translations'? I thought this quantity always is the Hamiltonian. – Nikolaj-K Feb 12 '12 at 18:39
  • 1
    @Nikolaj-K The total energy is simply $T+V$, i.e., kinetic plus potential energy. The quantity you describe resulting from time translation symmetry is the Hamiltonian, i.e., the Legendre transform of the Lagrangian. – UglyMousanova19 Aug 29 '18 at 23:38
  • 4
    For those looking a decade later at this thread and owns the 3rd edition of the book, the abovementioned passage can be found on pg. 345. – Tobias Holm Oct 24 '21 at 08:54
6

A little complicated but interesting is the Lagrangian of damped harmonic oscillator (Havas' Lagrangian [1]):

$$ L = \frac{2m\dot{x} +kx}{x\sqrt{4mK-k^2}}\tan^{-1}\left(\frac{2m\dot{x} + kx}{x\sqrt{4mK -k^2}} \right) - $$ $$ - \frac{1}{2}\ln (m\dot{x}^2 + kx\dot{x} + Kx^2) $$

The Lagrangian is time-independent, so the corresponding Havas' Hamiltonian

$$ H = - \frac{kpx}{2m} - \ln \cos\bigg(\frac{px}{2m}\sqrt{4mK-k^2}\bigg) + \ln x $$ is conserved. Since total energy of a damped harmonic oscillator decreases in time, this $H$ can't be total energy.

[1] Havas P., The Range of Application of the Lagrange Formalism - I,Nuovo Cim. 5(Suppl.), 363 (1957)

  • I thought energy was simply the generator of time translations (which would make it the Noether charge of time symmetry and undefined when there is no time symmetry). Is this not the general definition of energy? – Ryder Rude Sep 29 '23 at 14:09
  • No, an Hamiltonian is a "generator of time translations". Energy has many forms and many definitions. In mechanics, energy is T+U, sum of kinetic and potential energy. Hamiltonian need not have this value. – Ján Lalinský Oct 03 '23 at 21:55
3

Page 60-64 Goldstein, Poole and Safko (3rd Edition) goes into a really nice derivation and description of the Energy Function. In the footnotes it states that this is equivalent to the Hamiltonian (it is just not in the correct generalized coordinates for the Hamiltonian). If this function is derived from scleronomous (equations of constraints are time independent) and there is no $\dot{q}$ dependence in the potential energy, then you can show that h=T+V. These conditions make sure that T is 2nd degree homogeneous according to Euler's Theorem, and this is the condition that allows transformation to T+V.

This is all shown very nicely in Goldstein.

1

The Hamiltonian of a system is equivalent to the total energy of the system, if and only if, the following condition(s) are satisfied:

Keep in mind, that Hamiltonian being the $Legendre$ $Transformation$ of the $Lagrangian$, we need to consider the structure of the $Lagrangian$, in order to determine the $Hamiltonian$ of a system.

$1.$ The Lagrangian: $L$, must have the form, $L$ = ($T$ - $V$), and in order to have this, we need to consider the $d'Alembert's Principle$, which gives:

$$\frac{\mathrm{d} }{\mathrm{d}t}{(\frac{\partial T}{\partial \dot{q_i}}) - \frac{\mathrm{d}T}{\mathrm{d}q_i} = Q_j}{ ...... (\alpha)}$$

Where this $Q_j$ is the generalize force component for the $j$-th generalized co-ordinate, which is the forces of constraint(s).

Clearly, for:

Constraints of motion being explicit time-dependent (Force exerted on the system can have explicit time dependence) it is different, but for very general purposes, where the force(s) acting on the system can be directly derived from its respective scaler potential i.e. for

Conservative force field, we can write, $$Q_j = F_j = -\nabla_j (V) $$, i.e. the scaler potential, and simplifying the $(\alpha)$, we get $L = (T-V)$

$Note$ $that$: In cases of presence of vector potential, like for EM field, there's another case of explicit time-dependence, when fields are dependent on time, which constitutes another aspect, i.e. for time-varying potential, we cannot explicitly write the $Lagrangian$ in that fashion. But the $Hamiltonian$ formed in this way, will still satisfy being the total energy of the system.

Now, we can conclude that, for time-dependent constraint(s) of a motion, we cannot say that $Hamiltonian$ is equivalent to the $Total$ $Energy$ of the system.

prikarsartam
  • 130
  • 1
  • 10
  • I am learning Advanced Mechanics, and if there's something I have explained is not right, kindly point me out, because I need to clear out my understandings on that. – prikarsartam May 01 '20 at 13:24