Let $I\subset\mathbb{R}$ and $U\subset\mathbb{R}^n$ be open, and let $D\subset I\times U$ be a simply connected [open set](/page/Open%20Set). Let $\Omega\subset I\times U\times\mathbb{R}^n$ be open, and let $L:\Omega\to\mathbb{R}$ be $C^2$. Assume that the Legendre transform is defined on the velocities used below: for a $C^1$ velocity field $q:D\to\mathbb{R}^n$, suppose $(x,y,q(x,y))\in\Omega$ for every $(x,y)\in D$, define the momentum field