Example: Particle in 3D Potential \bgroup\color{black}$ V(x,y,z)$\egroup

Lets write the Hamiltonian and Hamilton's equations for a particle in Cartesian coordinates.

$\displaystyle L$ $\displaystyle = T-U= {1 \over 2} m(\dot{x}^2+\dot{y}^2+\dot{z}^2) - V(x,y,z)$    
$\displaystyle p_x$ $\displaystyle = {\partial L\over \partial \dot{x}}= m\dot{x}$ we know these momenta    
$\displaystyle p_y$ $\displaystyle = m\dot{y}$    
$\displaystyle p_z$ $\displaystyle = m\dot{z}$    
$\displaystyle H(q_i,p_i)$ $\displaystyle = \sum\limits_{i=1}^n p_i \dot{q}_i - L$ check $\displaystyle T+U$ this time    
$\displaystyle H$ $\displaystyle = p_x\dot{x}+p_y\dot{y}+p_z\dot{z} -L$    
$\displaystyle H$ $\displaystyle = {p_x^2+p_y^2+p_z^2\over 2m} + V(x,y,z) =T+U$    
$\displaystyle \dot{q}_i$ $\displaystyle ={\partial H\over\partial p_i}$ gives us $\displaystyle p$    in terms of $\displaystyle v$    
$\displaystyle \vec{v}$ $\displaystyle = {\vec{p}\over m}$    
$\displaystyle \dot{p}_i$ $\displaystyle =-{\partial H\over\partial q_i }$ gives us equation of motion    
$\displaystyle \dot{\vec{p}}$ $\displaystyle = -\vec{\nabla} V(x,y,z)$    

One equation defines the momentum and the other simply gives Newton's law in a potential. The Hamiltonian is the total energy. So, again, the Hamiltonian formalism gives us the same results as does Newton's laws, however, sometimes it is more convenient.

Jim Branson 2012-10-21