# Rotational Hamiltonian for Molecules

I would like to know where the classical rotational hamiltonian for rigid diatomic molecules comes from. In the reference I only find the expression

$$H_{\rm rot}=\frac{1}{2I} \left[ p_\theta^2 + \frac{p_\varphi^2}{\sin^2\!\theta} \right]$$

I understand that I have to separate in CM motion and rigid body rotation, but I not exactly how to do it with hamiltonian formalism

You are right, you need to separate the center-of-mass (COM) motion and the rotational motion. To achieve this you can derive the Lagrangian in a straight-forward way, and then do a Legendre transformation to get the Hamiltonian.

Because the question is tagged as homework-and exercises I will only sketch an outline without the calculational details. Consider a diatomic molecule. Let $$\mathbf{R}$$ be the COM position, and $$\mathbf{r}_1$$ and $$\mathbf{r}_2$$ the positions of the two atomic nuclei relative to the COM. Then the total kinetic energy is $$T=\frac{1}{2}m_1(\dot{\mathbf{R}}+\dot{\mathbf{r}}_1)^2 +\frac{1}{2}m_2(\dot{\mathbf{R}}+\dot{\mathbf{r}}_2)^2.$$

By expanding the squares and regrouping the terms you get $$T=\frac{1}{2}(m_1+m_2)\dot{\mathbf{R}}^2 +\frac{1}{2}(m_1\dot{\mathbf{r}}_1^2+m_2\dot{\mathbf{r}}_2^2) +\dot{\mathbf{R}}\underbrace{(m_1\dot{\mathbf{r}}_1+m_2\dot{\mathbf{r}}_2)}_{=\mathbf{0}}.$$

Here the last term is zero because the COM is defined by $$m_1\mathbf{r}_1+m_2\mathbf{r}_2=\mathbf{0}$$.

Rewriting $$\dot{\mathbf{r}}_1^2$$ and $$\dot{\mathbf{r}}_2^2$$ in spherical coordinates and using the abbreviations $$M=m_1+m_2$$ (the total mass) and $$I=m_1r_1^2+m_2r_2^2$$ (the moment of inertia) you get the total Lagrangian $$L=T=\frac{1}{2}M\dot{\mathbf{R}}^2+\frac{1}{2}I(\dot{\theta}^2+\dot{\varphi}^2\sin^2\theta)$$ where obviously the first term describes the COM motion and the second term describes the rotational motion.

Finally, from this total Lagrangian you calculate the total Hamiltonian (see Hamiltonian mechanics - Calculating a Hamiltonian from a Lagrangian) and get $$H=\frac{1}{2M}\mathbf{P}^2+\frac{1}{2I}\left(p_\theta^2+\frac{p_\varphi^2}{\sin^2\theta}\right).$$ Here again the first term describes the COM motion and the second term describes the rotational motion.