Hamiltonian dynamics is a formulation of mechanics that can be a useful alternative to Newton's formulation. It is closely related to Lagrangian dynamics, and makes use of the Lagrangian and Hamiltonian functions. From a mathematical viewpoint, problems in dynamics can sometimes be simpler to solve when written in the Hamiltonian formulation. The formulation is also important because it allows deep connections between classical and quantum mechanics to be made.
Hamilton's equations are a set of 2n first order differential equations, which relate the co-ordinates qi and the generalized momenta: