In Lagrangian formalism, if (M,g)(M, g) is our configuration manifold, equipped with a Riemannian metric gHom(TMTM,R)g\in Hom(TM\otimes TM, \mathbb{R}) , Lagrangian function L:TM×R+R\mathcal{L}: TM\times \mathbb{R}_{+}\rightarrow \mathbb{R} is defined as L(x(t),x˙(t),t)=12mg(x˙(t),x˙(t))U(x(t),t).\mathcal{L}(x(t), \dot{x}(t), t)= \frac{1}{2}mg(\dot{x}(t), \dot{x}(t))-U(x(t), t). If our particle flows under the influence of gravity, then ddt(Lx˙)Lx=0.\frac{d}{dt}\biggr(\frac{\partial \mathcal{L}}{\partial \dot{x}}\biggr)-\frac{\partial \mathcal{L}}{\partial x} = 0. By using Lagrange multipliers , we could generalize this PDE for holonomic physical systems . Now here's my question: Apparently, there's no canonical way to use Lagrangian mechanics for non-holonomic physical systems . At this point, how does Hamiltonian mechanics behave?