0
$\begingroup$

In my classical mechanics course, I was tasked with finding the Hamiltonian of a pendulum of variable length $l$, where $\frac{dl}{dt} = -\alpha$ ($\alpha$ is a constant, so $l = c - \alpha t$.).

I identified two coordinates, $l$ and $\theta$ and got the Lagrangian in terms of these coordinates. I then obtained the Hamiltonian as $$H = p_{\theta}\dot{\theta} + p_l\dot{l} - L$$

However, this turned out to be wrong. Apparently, I should have neglected $l$ and only used $\theta$ so that $$H = p_{\theta}\dot{\theta} - L$$

How do I know that $l$ should be neglected in this case? In general, how can I know which coordinates may be included or neglected when calculating a Hamiltonian?

$\endgroup$
0

1 Answer 1

1
$\begingroup$

In general, the lagrangian of a simple pendulum of longitude $l$ that moves in radial and angular directions is: $$\mathcal{L}(r, \theta) = \frac{1}{2}m(\dot{r}^2 + r\dot{\theta}^2) - mgr(1-\cos(\theta)),$$

where, for your case $r = l - \alpha t$, leading to the following lagrangian: $$\mathcal{L}(\theta, t) = \frac{1}{2}m(\alpha^2 + (l-\alpha t)\dot{\theta}^2) - mg(l - \alpha t)(1-\cos(\theta)).$$

As we can see, the radial coordinate is not a dynamical variable since we have explicit its time dependence. In fact, what you have done is a reparametrization of the Lagrangian: $\mathcal{L(r(t), \theta(t))} \to \mathcal{L(t, \theta(t))}$. This reparametrizacion implies, for example, that the energy is not conserved anymore and also, that the Hamiltonian do not corresponds with the energy of the system.

Now, the only dynamical variable is the angle $\theta$, because $l$ and $\alpha$ are constants. Computing the Hamiltonian we will have $$\mathcal{H}(\theta, t) = p_{\theta}\dot{\theta} - L(\theta, t).$$

In general, I recommend you to write down your lagrangians in the most general form depending in the best-suited coordinates for your system (i.e. polar, cylindrical, spherical…), each coordinate is a dynamical variable, a priori. Then apply the constraints to the lagrangian and check what are the remaining coordinates on it, each of them will have associated a momentum when calculating the Hamiltonian.

$\endgroup$