In the Hamiltonian formulation of classical mechanics a system with finitely many, say , degrees of freedom is described by *coordinates* determining the configuration of the system and *conjugate momenta* . In mathematical terms, serve as local coordinate functions on the *configuration space* which has the structure of a -dimensional smooth manifold and are local canonical coordinates on the cotangent bundle called the *phase space*. For example, a (mathematical) pendulum’s configuration is given by an angle and its momentum by a real number , thus having a circle as configuration space, and a cylinder as phase space, .

Dynamics is governed by a smooth real-valued function on the phase space called the *energy function* or *Hamiltonian* and is prescribed by a system of ODE’s, the equations of motion, which read as

This can be written in the concise matrix-vector form

where and is the matrix

The following properties of can be easily checked

To obtain a particular solution initial values must be specified. Transformations of the phase space which preserve Hamilton’s equations (2) are clearly of high importance. They’re called *canonical transformations*. For example, when a system evolves for some time , a canonical transformation is induced by taking every point as an initial value and mapping them into . Now let’s consider an arbitrary transformation of the phase space

Then the time derivative of along a solution reads as

and hence

where is the *Jacobian* of the transformation . Now, it is clear that is canonical iff satisfies the following condition

Such matrices are called *symplectic*^{(*)}. Let’s take a closer look at the structure of such a matrix by splitting it up into four blocks

Then condition (8) on can be reformulated for the blocks as

What’s the determinant of a symplectic matrix? Well, since the determinant is multiplicative it is immediate from (8) that . Actually, we can show that it’s .

**Claim.** *Every symplectic matrix has determinant .*

*Proof.* Assuming that the block is invertible can be written as a product

thus its determinant is

where and the multiplicative property of the determinant were also utilized. Now, using eqs. (10) and (12) we get

The proof is completed by noticing that matrices with form a dense subset of symplectic matrices and since the determinant is a continuous map we have for all symplectic matrices.

The above fact has a profound consequence. Canonical transformations preserve the phase space volume element! This is Liouville’s theorem. Furthermore, if the system has only bounded orbits we get Poincaré recurrence theorem which states that any neighbourhood of an initial value is infinitely many intersected by the solution starting from as goes to infinity.

In a previous post a funny application of the recurrence theorem to the academic administrative system was described. Here we mention another three applications which are at least as interesting as the one mentioned before:

- Pick an arbitrary point on the unit circle, , and consider the rotation around the origin through some angle . is clearly volume-preserving and the ‘orbit’ of any point is bounded. There are two different cases though:
- is rational: then for some .
- is irrational: then is dense in .

- Consider the first digits of the powers of (in base ten). What are the frequencies of among these digits? Any power can be written as
The question is the probability distribution of . Taking logarithm of both sides we get

where . Multiplying (17) by , we can rephrase the question as follows: How often will the orbit intersect the intervals , . These clearly are the length of the intervals, therefore

- A gas is prepared in one side of a two-compartment box. When the wall separating the compartments is removed the gas slowly, distributes equally among both halves of the box toward statistical equilibrium. As a consequence of Poincaré recurrence theorem there must be a time in the future when the gas will return back close to its initial condition with all molecules confined in one compartment. This page contains a simulation of randomly moving molecules in a box, thus Poincaré’s recurrence theorem applies. At t=0 the molecules are arranged in a nice square-shaped configuration. After 12800 (or 25600) steps a system returns to its initial state.

Here’s a video of pendulums of different lengths swinging around the same axis. One can clearly see that around 0:55 there are three sets of pendulums and in each set the pendulums are synchronized. Then at 1:23 there are two partitions and the recurrence time is ca. 2:45 minutes.

^{(*) The word ‘symplectic’ means complex and was coined by Weyl in 1939.}