Neural DAEs: Constrained neural networks
Tue Boesen, Eldad Haber, Uri Michael Ascher
TL;DR
This work addresses how to preserve algebraic constraint information in neural network models of dynamical systems by embedding constraint data into architectures rather than relying on data alone. It introduces four approaches—auxiliary regularization, end constraints, smooth constraints, and stabilization by penalty—to enforce constraints expressed as $c(K z(tau)) = 0$, demonstrating their effectiveness on multi-body pendulums, water MD simulations, and divergence-free vector-field denoising. Across these domains, projection-based methods, especially when applied smoothly through the network, yield the strongest improvements in constraint satisfaction and often improve predictive accuracy, highlighting the practical impact of constraint-aware learning in physics-informed contexts. The results suggest a robust, architecture-agnostic strategy for integrating hard physical constraints into neural models, with tradeoffs in computational cost and implementation complexity and clear directions for future refinement, such as advanced solvers, analytic backpropagation for projections, and higher-order constraint information.
Abstract
This article investigates the effect of explicitly adding auxiliary algebraic trajectory information to neural networks for dynamical systems. We draw inspiration from the field of differential-algebraic equations and differential equations on manifolds and implement related methods in residual neural networks, despite some fundamental scenario differences. Constraint or auxiliary information effects are incorporated through stabilization as well as projection methods, and we show when to use which method based on experiments involving simulations of multi-body pendulums and molecular dynamics scenarios. Several of our methods are easy to implement in existing code and have limited impact on training performance while giving significant boosts in terms of inference.
