For a classical mechanical system we are usually given a manifold \(M\) as its "configuration (or state) space", that is a space to which "positions" (also known as "generalised coordinates") of the elements of the system belong: \(q \in M\).
There are two very well-known ways to describe dynamics of such a system:
Lagrangian mechanics starts with a Lagrangian function: \(L : TM \times \mathbb{R} \to \mathbb{R}\). Here \(TM\) is the tangent bundle of \(M\), which consists of \(M\) with a tangent space attached at every point. Elements of \(TM\) are pairs \((q, \dot q)\), where \(\dot q\) is a velocity vector. All of this is a round-about way to say that the Lagrangian is a function \(L(q, \dot q, t)\), where \(q\) and \(\dot q\) are vectors of coordinates and velocities. Once the Lagrangian is given, the behavior of the system is fully described by the Euler-Lagrange equations:
$$\frac{\mathrm{d}}{\mathrm{d}t}\frac{\partial L}{\partial \dot q} - \frac{\partial L}{\partial q} = 0$$Hamiltonian mechanics, on the other hand, instead of velocities \(\dot q\), that is vectors, living the tangent space, uses conjugate momenta \(p\), which are velocities that live in the cotangent space \(T^*M\). The translation from one space to another is given by the Legendre transformation. Instead of a Lagrangian, you are given a Hamiltonian function \(H : T^*M \times \mathbb{R} \to \mathbb{R}\), such that \(H(q, p, t)\) gives you the energy of the system. And then you have Hamilton's equations that describe the evolution of the system:
$$\dot q = \frac{\partial H}{\partial p}$$ $$\dot p = - \frac{\partial H}{\partial q}$$Lagrangian velocity is a vector, that is a tensor of type \((1, 0)\), that can be written in the component notation as \(\dot q = v^i\). Hamiltonian velocity is a covector, a tensor of type \((0, 1)\), written as \(p = v_i\). In classical mechanics, they are related as \(p = m \cdot \dot q\) or
$$v_i = m \cdot v^i$$where \(m\) is mass. That is, mass lowers (or raises as in \(v^i = m^{-1} \cdot v_i\)) indices. But this is exactly what the metric tensor does in the Riemann setting:
$$v_i = g_{ij} \cdot v^j$$Mass looks suspiciously similar to metric. The central idea of the general theory of relativity, that distribution of mass determines the geometry of space and thus the movement of matter, was always there from the earliest days of analytical mechanics. Hamilton might have seen it, darkly; Clifford most likely did.