Lagrangian Neural Networks
Miles Cranmer, Sam Greydanus, Stephan Hoyer, Peter Battaglia, David Spergel, Shirley Ho
TL;DR
The paper tackles learning physical dynamics with energy conservation when canonical coordinates are unavailable by introducing Lagrangian Neural Networks (LNNs) that learn a neural Lagrangian and derive dynamics via the Euler–Lagrange equation. It extends the approach to Lagrangian Graph Networks to handle graph-structured and PDE-like systems, such as the 1D wave equation. Across experiments, LNNs achieve superior energy conservation on a double pendulum, succeed in modeling a relativistic particle from noncanonical coordinates where Hamiltonian methods fail, and effectively model PDE-like dynamics in graphs. The work broadens the scope of physics-informed neural modeling by removing canonical-coordinate constraints and enabling energy-preserving dynamics in complex systems, with public code support.
Abstract
Accurate models of the world are built upon notions of its underlying symmetries. In physics, these symmetries correspond to conservation laws, such as for energy and momentum. Yet even though neural network models see increasing use in the physical sciences, they struggle to learn these symmetries. In this paper, we propose Lagrangian Neural Networks (LNNs), which can parameterize arbitrary Lagrangians using neural networks. In contrast to models that learn Hamiltonians, LNNs do not require canonical coordinates, and thus perform well in situations where canonical momenta are unknown or difficult to compute. Unlike previous approaches, our method does not restrict the functional form of learned energies and will produce energy-conserving models for a variety of tasks. We test our approach on a double pendulum and a relativistic particle, demonstrating energy conservation where a baseline approach incurs dissipation and modeling relativity without canonical coordinates where a Hamiltonian approach fails. Finally, we show how this model can be applied to graphs and continuous systems using a Lagrangian Graph Network, and demonstrate it on the 1D wave equation.
