Table of Contents
Fetching ...

Solver-in-the-Loop: Learning from Differentiable Physics to Interact with Iterative PDE-Solvers

Kiwon Um, Robert Brand, Yun, Fei, Philipp Holl, Nils Thuerey

TL;DR

This work tackles numerical errors in discretized PDE solvers by learning a correction function that interacts with the solver in a differentiable training loop. It formalizes a solver-in-the-loop framework with three interaction modes (NON, PRE, SOL) and demonstrates that long-horizon, differentiable-physics-guided training yields substantial accuracy gains across advection-diffusion, Navier–Stokes, buoyancy-driven flows, and CG solvers. The key finding is that training corrections inside the solver loop, with end-to-end backpropagation through solver steps, produces more accurate and robust corrections than pre-computed or non-interacting approaches, including in 3D flows and long rollout scenarios. The results show large reductions in error, improved frequency content alignment, and substantial runtime speed-ups when deploying the learned corrections, highlighting the practical potential for integrating neural corrections into numerical toolchains for PDEs and even weather prediction scenarios.

Abstract

Finding accurate solutions to partial differential equations (PDEs) is a crucial task in all scientific and engineering disciplines. It has recently been shown that machine learning methods can improve the solution accuracy by correcting for effects not captured by the discretized PDE. We target the problem of reducing numerical errors of iterative PDE solvers and compare different learning approaches for finding complex correction functions. We find that previously used learning approaches are significantly outperformed by methods that integrate the solver into the training loop and thereby allow the model to interact with the PDE during training. This provides the model with realistic input distributions that take previous corrections into account, yielding improvements in accuracy with stable rollouts of several hundred recurrent evaluation steps and surpassing even tailored supervised variants. We highlight the performance of the differentiable physics networks for a wide variety of PDEs, from non-linear advection-diffusion systems to three-dimensional Navier-Stokes flows.

Solver-in-the-Loop: Learning from Differentiable Physics to Interact with Iterative PDE-Solvers

TL;DR

This work tackles numerical errors in discretized PDE solvers by learning a correction function that interacts with the solver in a differentiable training loop. It formalizes a solver-in-the-loop framework with three interaction modes (NON, PRE, SOL) and demonstrates that long-horizon, differentiable-physics-guided training yields substantial accuracy gains across advection-diffusion, Navier–Stokes, buoyancy-driven flows, and CG solvers. The key finding is that training corrections inside the solver loop, with end-to-end backpropagation through solver steps, produces more accurate and robust corrections than pre-computed or non-interacting approaches, including in 3D flows and long rollout scenarios. The results show large reductions in error, improved frequency content alignment, and substantial runtime speed-ups when deploying the learned corrections, highlighting the practical potential for integrating neural corrections into numerical toolchains for PDEs and even weather prediction scenarios.

Abstract

Finding accurate solutions to partial differential equations (PDEs) is a crucial task in all scientific and engineering disciplines. It has recently been shown that machine learning methods can improve the solution accuracy by correcting for effects not captured by the discretized PDE. We target the problem of reducing numerical errors of iterative PDE solvers and compare different learning approaches for finding complex correction functions. We find that previously used learning approaches are significantly outperformed by methods that integrate the solver into the training loop and thereby allow the model to interact with the PDE during training. This provides the model with realistic input distributions that take previous corrections into account, yielding improvements in accuracy with stable rollouts of several hundred recurrent evaluation steps and surpassing even tailored supervised variants. We highlight the performance of the differentiable physics networks for a wide variety of PDEs, from non-linear advection-diffusion systems to three-dimensional Navier-Stokes flows.

Paper Structure

This paper contains 46 sections, 19 equations, 28 figures, 7 tables.

Figures (28)

  • Figure 1: A 3D fluid problem (shown in terms of vorticity) for which the regular simulation introduces numerical errors that deteriorate the resolved dynamics (a). Combining the same solver with a learned corrector trained via differentiable physics (b) significantly reduces errors w.r.t. the reference (c).
  • Figure 2: Transformed solutions of the reference sequence computed on $\mathscr{R}$ (blue) differ from solutions computed on the source manifold $\mathscr{S}$ (orange). A correction function $\mathcal{C}$ (green) updates the state after each iteration to more closely match the projected reference trajectory on $\mathscr{S}$.
  • Figure 3: Our PDE scenarios cover a wide range of behavior including (a) vortex shedding, (b) complex buoyancy effects, and (c) advection-diffusion systems. Shown are different time steps (l.t.r.) in terms of vorticity for (a), transported density for (b), and angle of velocity direction for (c).
  • Figure 4: (a)-(e) Numerical approximation error w.r.t. reference solution for unaltered simulations (SRC) and with learned corrections. The models trained with differentiable physics and look-ahead achieve significant gains over the other models. (f,g) Relative improvement over varying look-ahead horizons. (h) A frequency-based evaluation for the unsteady wake flow scenario.
  • Figure 5: Different models applied to five test cases over 500 time steps for the unsteady wake flow scenario. The SOL$_{32}$ reduces the error introduced by SRC by a factor of 11.2 on average.
  • ...and 23 more figures