Applications of Hamiltonian formalism to classical mechanics In many courses in theoretical classical mechanics  Hamiltonian formalism takes an important place. However I did not see it applied to problems of classical mechanics (unless one expands the scope of the latter to include some rather mathematical topics e.g. from symplectic geometry). For example in vol. 1 in the Landau-Lifshitz textbook discussing classical mechanics the Hamiltonian formalism is introduced in the last chapter and never used anymore for the classical mechanics. Rather it is applied in vol. 3 to quantum mechanics where it allows to guess the right form of the Schroedinger equation by comparing it with the analogous classical problem as a limit case.
I am wondering whether historically there were real applications of Hamiltonian formalism to classical mechanics, e.g. to planetary motion. What was Hamilton's original motivation to introduce it?
Remark. The discussion of Hamiltonian formalism in Arnold's "Mathematical methods of classical mechanics" is great, but it contains no applications in the spirit I am looking for.
 A: The Poincaré-von Zeipel method in celestial mechanics relies on canonical transformations of the Hamiltonian to separate fast and slow degrees of freedom in a solar system. See, for example, A note on the application of the von Zeipel method to degenerate Hamiltonians.
More generally, the method of canonical perturbation theory is formulated in a Hamiltonian framework, see for example On canonical perturbation theory in classical mechanics.
A: E.T. Whittaker's A Treatise on the Analytical Dynamics of Particles and Rigid Bodies (Cambridge, multiple editions from 1904 onwards) provides applications, particularly to celestial mechanics.
R. Abraham and J.E. Marsden Foundations of Mechanics (Addison-Wesley 1978) provides a modern treatment, with a focus on qualitative results.
A: Historical References:
"A History of Mechanics" by Rene Dugas is highly recommended reference, which includes discussion of Hamilton's work and its development. Below I will summarize some interesting findings of Dugas.
(Edited Jan 13, 2021)
Dugas writes that Hamilton's geometric optics was a new method of formalizing the collection of results that had already been obtained, and capable of being interpreted in terms of either wave propagation (in Huyghens' sense) or corpuscles (in the sense of the dynamical principle of least action).
"Whether we adopt the Newtonian or Huyghenian, or any other lines of luminous or visual communication, we may regard these laws themselves, and the properties and relations of these linear paths of light, as an important separate study, and as constituting  a separate science, called often mathematical optics". [Dugas, pp.391]
"But although the law of least action has thus attained a rank among the higest theorems of physics, yet its pretensions to a cosmological necessity, on the grounds of economy in the universe, are now generally rejected. And the rejection appears just, for this, among other reasons, that the quantity pretended to be economized is in fact often lavishly expended."
The principle of least action, as arising in the works of Fermat, Maupertuis, and criticized in Euler, Lagrange, was a great controversy. Hamilton found the stationary action, and thus recovered Fermat's law of least time in an acceptable variational setting.
Hamilton was astronomer who also apparently understood the calculus of variations. In his first article on dynamics
"On a General Method of Expressing the Paths of Light, & of the Planets, by the Coefficients of a Characteristic Function" is included an exact statement of Hamiltonian principle of optical stationary action:
"The optical quantity called action, for any luminous path having $i$ sudden branches by reflexion or refraction, and having therefore $i+1$ separate branches, is the sum of $i+1$ separate integrals $$ACTION=V=\sum \int dV_i=V_1+\cdots +V_{i+1}$$ of which each is determined by an equation of the form $$V_i=\int dV_i=\int v_i \sqrt{dx_i^2+dy_i^2+dz_i^2},$$ the quantity $v_i$ being dependant on material properties of medium $m_i$, e.g. refractive index.  This quantity $V$ is stationary in the propagation of light."
Hamilton also formulated exactly a law of varying action, which allows the ends of the optical (luminous) path to vary. He observed that the wave surfaces satisfy the equation $V=const$ and therefore the components $\partial V/\partial x$, $\partial V/\partial y$, $\partial V,\partial z$ are components of normal slowness. And redicovered the theorem of Huyghens (then disputed against the Newtonian corpuscular model) that the rays of a homogeneous system, starting from a single point or normal to a surface, remain normal to a family of surfaces after they have been subjected to any number of reflections or refractions.
Hamilton recovered Fermat's principle of least time via $$V=\int_{x',y',z'}^{x,y,z} \frac{ds}{u},$$ and $$\delta V=\delta \int v ds=0$$ corresponding to the extremal $\delta \int ds/u=0$ where $u$ is the wave (undulatory) velocity.
The above first article is on optics and variations of the optic action $V$.
In his "first essay on a general method in dynamics" he studies the living force action $V=\int_0^t  2T dt$, which is the living force (kinetic energy) accumulated from the origin of time to the time $t$.
He writes $T=U+H$, where $U=\sum m m' f (r)$ is the force between masses $m, m'$, and $$\sum m(x''\delta x + y'' \delta y + z'' \delta z)=\delta U.$$ Here $H$ is that so-called Hamiltonian term.
There's much more to say about Hamilton's work, and Dugas explains in detail.
Jacobi gave lectures in 1842-3 at Konigsberg, "Vorlesungen uber Dynamik" edited by Clebsch (1866) where Hamilton's theory is extended and simplified. In those same lectures Jacobi is credited with geometrising the principle, in which case the characteristic function (Hamiltonian) has trajectories corresponding to the same total energy.
Dugas writes that after Jacobi, further contributions were made by Liouville (1856), Lipschitz (1871), Thomson and Tait (1879), Levi-Civita (1896), and Darboux (last two chapters of his "Lecons sur la theorie generale des surfaces").
Levi-Civita's excellent text "The Absolute Differential Calculus"  contains discussion of geometric optics, Hamilton's principle, and describes how Einstein's general relativity attempts to generalize Hamilton's optics. See Part III, Chapter XI, pp. 287.
I might even say the applications of Hamilton-Jacobi equations to classical mechanics continues even today(!) in the form of Monge-Kantorovich (Alexandrov-Brenier-McCann-etc.) optimal transportation. Also interesting is Nassif Ghoussoub's theory of self-dual variational problems, which is based on the classic correspondance of Lagrangian and Hamiltonian via the Legendre-Fenchel transform.
A: About the phrasing of your question: it could be that mean to ask: before the introduction of QM, were there real applications of the Hamiltonian formalism in use, alongside the existing Lagrangian formalism?
Or it could be that you mean to ask: before QM, were there real applications of what we nowadays know as Hamilton's stationary action?

The answer below is for the second question.


Max Planck believed that Hamilton's stationary action constitutes something special.
Wikisource has a series of Lectures by Max Planck, delivered in 1909, the title of the seventh lecture is General Dynamics. Principle of Least Action.


The answer by contributor JHM offers the information that 'Jacobi appears to have simplified several redundancies in Hamilton's formalism'.
It would appear: while Hamilton's stationary action originated with Hamilton, it was later treatment that brought it into the form in which we know it today.

Derivation from first principles
For the case of a point mass there is the following derivation of Hamilton's stationary action from first principles. It's short. it would appear this is the shortest possible.
We have the work-energy theorem:
$$\int_{s_0}^s F ds = \tfrac{1}{2}mv^2 - \tfrac{1}{2}mv_0^2 $$
One implication of the work-energy theorem: along an entire trajectory the rate of change of kinetic energy must match the rate of change of potential energy.
$$d(E_k) = -d(E_p)   \qquad (1) $$
(1) can be expressed as either a time derivative or a position derivative.
A trajectory is a true trajectory if the following is valid for every infinitisimally short subsection along the entire trajectory:
$$ \frac{d(E_k)}{dt} = -\frac{d(E_p)}{dt}   \qquad (2)  $$
$$ \frac{d(E_k)}{ds} = -\frac{d(E_p)}{ds}   \qquad (3)  $$
Again: (2) and (3) are two ways to express the same property.
(3) is the basis of Hamilton's stationary action:
Integration is a linear operation.
Therefore if for an entire trajectory (3) is satisfied then the following equation is automatically satisfied too:
$$ \frac{d(\int E_k dt)}{ds} = - \frac{d(\int E_p dt)}{ds}  \qquad (4) $$
(4) expresses the stationary condition of Hamilton's stationary action.

(Many derivations start with Hamilton's stationary action, and derive (3) from (4). However, (3) is already a direct consequence of the work-energy theorem.)
(Many people wonder: in Hamilton's stationary action, what role is played by the integration? This derivation explains that. Integration is a linear operation, that is the key.)
