Course & textbook · INSA Toulouse, Applied Mathematics & Master Mod'IA - Scientific ML

Data Assimilation, Adjoint Methods and Learning

Inverse Problems for Physics-Based Models, from Optimal Control to Hybrid Machine Learning

How to fuse physics-based models (ODEs, PDEs) with observations? The course covers the estimation of model parameters, initial or boundary conditions and forcing terms; the computation of gradients in large dimension by the adjoint method, and their validation; and the many bridges between data assimilation and machine learning: neural networks as parametric models, learned inversion, PINNs, backpropagation, reinforcement learning, hybrid physics–ML models.

Moodle, open access:

The course in three pictures

Diagram of the VDA principle: input parameters feed a model and its computational code; the model output is compared to observations through a cost function, and the discrepancy is fed back to the uncertain inputs.
1. The principle: from direct modeling to model calibration. A physics-based model (ODE or PDE, here the 2D shallow-water equations) depends on uncertain inputs: empirical coefficients, initial and boundary conditions. Its output is compared to observations (satellite, airborne or in-situ) through a cost function, which variational data assimilation (VDA) minimizes with respect to the inputs. The key ingredient is the gradient with respect to possibly millions of inputs: the adjoint model provides it for about the cost of one extra model run (Parts II–IV).
Lorenz-63 twin experiment: the free run diverges from the truth while the EnKF and 4D-Var analyses track it; bottom panel shows RMSE below the observation error.
2. Variational vs sequential DA on a chaotic system. Lorenz-63 twin experiment: noisy observations (red dots) are generated from a known true trajectory (black). Started from a slightly wrong initial state, the model alone (orange) soon loses track of the truth — the hallmark of chaos. An ensemble Kalman filter and a cycled 4D-Var (adjoint gradient, L-BFGS) both follow it, with errors below the observation noise (bottom), since the dynamics propagates past information. 4D-Var is the most accurate; the EnKF also estimates its own uncertainty (Chapters 5, 13, 15).
Hybrid model vs neural ODE on a damped oscillator: (a) fit and extrapolation in time, (b) new initial condition, (c) learned friction law versus the true one.
3. Physics + learning: hybrid model vs pure neural network. A damped oscillator with unknown friction is observed on a short window (grey band). Two models are trained by the same adjoint-based gradient: a neural ODE, whose whole dynamics is a network (black box), and a hybrid model which keeps the known physics and learns only the friction (grey box). (a) Both fit the data, but the neural ODE learned the trajectory, not the law: its extrapolation error is 10 times larger. (b) From a new initial state, both degrade; (c) the learned friction is accurate only over the velocities seen in the data. A two-parameter physical law extrapolates more robustly. Lessons of Chapter 7: physics improves generalization, learned terms are reliable only where data exist.

Contents

Part I · Ch. 1–4Inverse problems and learning from data

Ill-posedness (Hadamard), why a naive inversion fails; least squares, SVD, Tikhonov regularization, choice of the parameter (Morozov, L-curve, GCV), Gauss–Newton; neural networks as parametric models, surrogates and learned inversion; the running example: river bathymetry.

Part II · Ch. 5–8Variational DA and the adjoint method

Overview of DA and a Lorenz-63 twin experiment; VDA in finite dimension, 3D-Var, preconditioning; optimal control of ODEs: Pontryagin, direct and indirect methods, Riccati, dynamic programming and reinforcement learning, neural ODEs and hybrid models; PINNs vs VDA.

Part III · Ch. 9–11Gradients: computation & validation

Backpropagation is the adjoint method, a dictionary between VDA and deep learning; automatic differentiation, forward and reverse modes, checkpointing (Lorenz-96 illustration); validating gradients and adjoint codes, twin experiments.

Part IV · Ch. 12–13PDE models and 4D-Var

Optimal control of stationary PDEs: Lagrangian, adjoint method, applications to classical PDEs; VDA for time-dependent PDEs: discrete and continuous optimality systems, 4D-Var, incremental 4D-Var.

Part V · Ch. 14–16Statistical estimation & sequential DA

Bayesian inversion: posterior, MAP, Laplace approximation, MCMC sampling; BLUE, Kalman filters, ensemble methods, equivalence 4D-Var / Kalman in the linear-Gaussian case; modeling background error covariances.

Part VI · Ch. 17 & appendicesPerspectives: hybridizing DA and ML

Networks in the model (corrections, parameter maps), instead of the model (emulators), in the prior, as the inverse map; PINNs as hybrids; Lorenz-96 illustration. Appendices: calculus, optimization, statistics, classical PDE models, the two practicals, solutions of the exercises.

Each chapter comes with exercises and Python codes; "learning corners" connect the topic to machine learning.

Practicals

River bathymetry from water-surface data Appendix E

A real-world inverse problem in spatial hydrology, solved by VDA (Python, FEniCS finite elements).

Optimal control, adjoint and learning Appendix F

Controlling a dynamical system, computing and validating the adjoint, and comparing with learning approaches (Python).

Statements, codes and course sessions are on the Moodle page. For research use in hydrology, see the open-source DassHydro platform.

How to cite

Jérôme Monnier. Data Assimilation, Adjoint Methods and Learning. Inverse Problems for Physics-Based Models, from Optimal Control to Hybrid Machine Learning. Lecture notes, INSA Toulouse, 2026. ⟨hal-03040047⟩

BibTeX
@misc{Monnier-DA-course,
  author       = {Monnier, J{\'e}r{\^o}me},
  title        = {Data Assimilation, Adjoint Methods and Learning.
                  Inverse Problems for Physics-Based Models,
                  from Optimal Control to Hybrid Machine Learning},
  howpublished = {Lecture notes, INSA Toulouse},
  year         = {2026},
  note         = {HAL: hal-03040047},
  url          = {https://hal.science/hal-03040047}
}

Prerequisites

Basic approximation methods, differential calculus, numerical optimization, classical PDE models (weak forms are a plus), numerical schemes (finite differences; finite elements are a plus), artificial neural networks, Python programming.

The textbook (485 pages) is a living document (25 November 2026 version), revised as the course progresses. Questions and feedback are welcome by e-mail.