The optimal (Monge-Kantorovich) transportation problem is discussed from
several points of view. The Lagrangian formulation extends the action of the
{\em Lagrangian} $L(v,x,t)$ from the set of orbits in $\R^n$ to a set of
measure-valued orbits. The {\em Eulerian}, dual formulation leads an
optimization problem on the set of sub-solutions of the corresponding
Hamilton-Jacobi equation. Finally, the Monge problem and its Kantorovich
relaxation are obtained by reducing the optimization problem to the set of
measure preserving mappings and two point distribution measures subjected to an
appropriately defined cost function.
In this paper we concentrate on mechanical Lagrangians $L=|v|^2/2+P(x,t)$
leading, in general, to a non-homogeneous cost function. The main results yield
existence of a unique {\em flow} of homomorphisms which transport the optimal
measure valued orbit of the extended Lagrangian, as well as the existence of an
optimal solution to the dual Euler problem and its relation to the Monge- and
Kantorovich formulations.