A solver-in-the-loop framework for end-to-end differentiable coastal hydrodynamics
Pith reviewed 2026-05-10 18:00 UTC · model grok-4.3
The pith
A fully differentiable non-hydrostatic shallow-water solver allows end-to-end optimization for coastal hydrodynamics tasks.
A machine-rendered reading of the paper's core claim, the machinery that carries it, and where it could break.
Core claim
By implementing the full time-marching physics loop inside a reverse-mode automatic differentiation system, the solver makes forward simulation and inverse optimization interchangeable operations within a single framework, demonstrated on neural model correction, continuous topology optimization, in-the-loop neural control, and direct inversion of bathymetry and landslide sources.
What carries the argument
AegirJAX, the fully differentiable implementation of the non-hydrostatic shallow-water equations that embeds the entire simulation time loop as a single computational graph supporting reverse-mode differentiation.
Load-bearing premise
The full time-marching loop of the non-hydrostatic shallow-water solver can be stably embedded as a single computational graph in reverse-mode automatic differentiation without prohibitive memory costs, numerical instability, or loss of physical accuracy.
What would settle it
Running long time integrations where the memory footprint grows prohibitively or where computed gradients fail to match finite-difference checks would show the approach is not yet practical.
Figures
read the original abstract
Numerical simulation of wave propagation and run-up is a cornerstone of coastal engineering and tsunami hazard assessment. However, applying these forward models to inverse problems, such as bathymetry estimation, source inversion, and structural optimization, remains notoriously difficult due to the rigidity and high computational cost of deriving discrete adjoints. In this paper, we introduce AegirJAX, a fully differentiable hydrodynamic solver based on the depth-integrated, non-hydrostatic shallow-water equations. By implementing the solver entirely within a reverse-mode automatic differentiation framework, AegirJAX treats the time-marching physics loop as a continuous computational graph. We demonstrate the framework's versatility across a suite of scientific machine learning tasks: (1) discovering regime-specific neural corrections for model misspecifications in highly dispersive wave propagation; (2) performing continuous topology optimization for breakwater design; (3) training recurrent neural networks in-the-loop for active wave cancellation; and (4) inverting hidden bathymetry and submarine landslide kinematics directly from downstream sensor data. The proposed differentiable paradigm fundamentally blurs the line between forward simulation and inverse optimization, offering a unified, end-to-end framework for coastal hydrodynamics.
Editorial analysis
A structured set of objections, weighed in public.
Referee Report
Summary. The manuscript introduces AegirJAX, a fully differentiable hydrodynamic solver for the depth-integrated non-hydrostatic shallow-water equations implemented entirely in JAX to enable reverse-mode automatic differentiation through the time-marching loop. It claims this framework unifies forward simulation and inverse optimization, with demonstrations on four tasks: neural corrections for dispersive wave model misspecifications, continuous topology optimization of breakwaters, in-the-loop training of recurrent networks for active wave cancellation, and direct inversion of bathymetry and submarine landslide kinematics from sensor data.
Significance. If the implementation successfully embeds the full non-hydrostatic time-marching loop with stable gradients and manageable memory cost, the work could meaningfully advance end-to-end differentiable physics for coastal engineering inverse problems, reducing reliance on hand-derived adjoints. The breadth of the four claimed demonstrations suggests potential for high impact in scientific machine learning applications, though this hinges on unshown validation.
major comments (2)
- [Abstract] Abstract: the four demonstration tasks are enumerated but the text supplies no quantitative results, error metrics, convergence checks, baseline comparisons, or implementation details, so the central claim that the framework successfully enables these tasks cannot be verified from the provided material.
- [Solver description] The viability of treating the entire forward physics loop (depth-integrated non-hydrostatic SWE with free-surface evolution and pressure correction) as one unbroken computational graph in reverse-mode AD is load-bearing for all applications, yet no discussion appears of memory mitigation (e.g., checkpointing), custom vector-Jacobian products, or stability analysis for the dispersive and non-hydrostatic terms that could introduce stiffness and gradient amplification over realistic coastal time horizons.
minor comments (1)
- [Abstract] The acronym AegirJAX is introduced without etymology or relation to prior coastal solvers.
Simulated Author's Rebuttal
We thank the referee for their constructive and detailed review of our manuscript on AegirJAX. We address each major comment below and have revised the manuscript to strengthen the presentation of results and implementation details.
read point-by-point responses
-
Referee: [Abstract] Abstract: the four demonstration tasks are enumerated but the text supplies no quantitative results, error metrics, convergence checks, baseline comparisons, or implementation details, so the central claim that the framework successfully enables these tasks cannot be verified from the provided material.
Authors: We agree that the original abstract was high-level and did not include quantitative indicators. In the revised manuscript we have expanded the abstract to summarize key quantitative outcomes for each of the four tasks (e.g., relative L2 errors for neural corrections, convergence of the topology optimization objective, wave-cancellation attenuation factors, and bathymetry inversion RMSE). Full error metrics, baseline comparisons (including non-differentiable adjoint and finite-difference approaches), convergence diagnostics, and implementation specifics (JAX version, hardware, checkpointing settings) are now explicitly referenced in the abstract and detailed in Sections 4–5 and the supplementary material. revision: yes
-
Referee: [Solver description] The viability of treating the entire forward physics loop (depth-integrated non-hydrostatic SWE with free-surface evolution and pressure correction) as one unbroken computational graph in reverse-mode AD is load-bearing for all applications, yet no discussion appears of memory mitigation (e.g., checkpointing), custom vector-Jacobian products, or stability analysis for the dispersive and non-hydrostatic terms that could introduce stiffness and gradient amplification over realistic coastal time horizons.
Authors: The referee correctly highlights that memory cost and gradient stability are central to the practicality of the approach. The original manuscript described the JAX implementation but did not elaborate on these engineering aspects. We have added a new subsection (Section 3.4) that (i) details the checkpointing strategy used to keep memory linear in the number of time steps rather than quadratic, (ii) describes custom vector-Jacobian products implemented for the non-hydrostatic pressure Poisson solve to avoid full Jacobian materialization, and (iii) presents numerical experiments quantifying gradient amplification for the dispersive and non-hydrostatic terms over the time horizons employed in the demonstrations (up to several thousand steps). We note that for significantly longer simulations additional techniques such as adjoint checkpointing or reduced-order modeling may be required, but the reported results demonstrate stable gradients for the coastal-engineering time scales considered. revision: yes
Circularity Check
No circularity: AegirJAX is a new JAX implementation of the non-hydrostatic SWE solver with independent demonstrations.
full rationale
The paper introduces a fully differentiable solver by embedding the depth-integrated non-hydrostatic shallow-water equations and time-marching loop directly into reverse-mode AD in JAX. No derivation reduces a claimed result to its own fitted parameters or inputs by construction. The four demonstration tasks (neural corrections, topology optimization, RNN-in-the-loop cancellation, bathymetry inversion) are applications of the framework rather than re-derivations of its core equations. No self-citation is invoked as a uniqueness theorem or to justify the central differentiability claim; the implementation itself supplies the end-to-end graph. The framework is therefore self-contained against external benchmarks and does not exhibit any of the enumerated circularity patterns.
Axiom & Free-Parameter Ledger
axioms (2)
- domain assumption Depth-integrated non-hydrostatic shallow-water equations are sufficient to capture the target wave propagation and run-up phenomena
- domain assumption Reverse-mode automatic differentiation can be applied to the full time-marching physics loop as a single continuous graph
invented entities (1)
-
AegirJAX
no independent evidence
Lean theorems connected to this paper
-
IndisputableMonolith/Cost/FunctionalEquation.leanwashburn_uniqueness_aczel unclear?
unclearRelation between the paper passage and the cited Recognition theorem.
By implementing the solver entirely within a reverse-mode automatic differentiation framework, AegirJAX treats the time-marching physics loop as a continuous computational graph.
-
IndisputableMonolith/Foundation/RealityFromDistinction.leanreality_from_one_distinction unclear?
unclearRelation between the paper passage and the cited Recognition theorem.
the entire unrolled fluid simulation is a differentiable computational graph
What do these tags mean?
- matches
- The paper's claim is directly supported by a theorem in the formal canon.
- supports
- The theorem supports part of the paper's argument, but the paper may add assumptions or extra steps.
- extends
- The paper goes beyond the formal theorem; the theorem is a base layer rather than the whole result.
- uses
- The paper appears to rely on the theorem as machinery.
- contradicts
- The paper's claim conflicts with a theorem or certificate in the canon.
- unclear
- Pith found a possible connection, but the passage is too broad, indirect, or ambiguous to say the theorem truly supports the claim.
Reference graph
Works this paper leans on
-
[1]
M. G. Alhashim, K. Hausknecht, and M. P. Brenner. Control of flow behavior in complex fluids using automatic differentiation.Proc. Natl. Acad. Sci. U.S.A, 122(8):e2403644122, 2025. 1https://github.com/abihlo/AegirJAX 18
work page 2025
-
[2]
E. Anderlini, S. Husain, G. G. Parker, M. Abusara, and G. Thomas. Towards real-time reinforcement learning control of a wave energy converter.J. Mar . Sci. Eng., 8(11):845, 2020
work page 2020
-
[3]
R. Anelli. Physics-informed neural networks for shallow water equations, 2021
work page 2021
-
[4]
V . Babovic and M. Keijzer. Genetic programming as a model induction engine.J. Hydroinform., 2(1):35–60, 2000
work page 2000
-
[5]
A. G. Baydin, B. A. Pearlmutter, A. A. Radul, and J. M. Siskind. Automatic differentiation in machine learning: a survey.J. Mach. Learn. Res., 18:Paper No. 153, 2018
work page 2018
-
[6]
S. Beji and J. A. Battjes. Experimental investigation of wave propagation over a bar.Coast. Eng., 19(1-2):151–162, 1993
work page 1993
-
[7]
M. P. Bendsoe and O. Sigmund.Topology optimization: theory, methods, and applications. Springer Science & Business Media, 2013
work page 2013
-
[8]
A. Bihlo and S. MacLachlan. Well-balanced mesh-based and meshless schemes for the shallow-water equations.BIT Numer . Math., 58:579–598, 2018
work page 2018
-
[9]
A. Bihlo and R. O. Popovych. Physics-informed neural networks for the shallow-water equations on the sphere.J. of Comput. Phys., 456:111024, 2022
work page 2022
-
[10]
O. Bokhove. Flooding and drying in discontinuous Galerkin finite-element discretizations of shallow-water equations. Part 1: one dimension.J. Sci. Comput., 22:47–82, 2005
work page 2005
- [11]
-
[12]
J. Bradbury, R. Frostig, P. Hawkins, M. J. Johnson, C. Leary, D. Maclaurin, G. Necula, A. Paszke, J. VanderPlas, S. Wanderman-Milne, and Q. Zhang. JAX: composable transformations of Python+NumPy programs, 2018
work page 2018
- [13]
- [14]
-
[15]
M. J. Briggs, C. E. Synolakis, G. S. Harkins, and D. R. Green. Laboratory experiments of tsunami runup on a circular island. InTsunamis: 1992–1994, pages 569–593. Springer, 1995
work page 1992
-
[16]
K. Cho, B. Van Merriënboer, Ç. Gulçehre, D. Bahdanau, F. Bougares, H. Schwenk, and Y . Bengio. Learning phrase representations using rnn encoder–decoder for statistical machine translation. InProceedings of the 2014 conference on empirical methods in natural language processing (EMNLP), pages 1724–1734, 2014
work page 2014
- [17]
-
[18]
M. B. Giles. Discrete adjoint approximations with shocks. InHyperbolic Problems: Theory, Numerics, Applications: Proceedings of the Ninth International Conference on Hyperbolic Problems held in CalTech, Pasadena, March 25–29, 2002, pages 185–194. Springer, 2003
work page 2002
-
[19]
C. Goto, Y . Ogawa, N. Shuto, and F. Imamura. IUGG/IOC time project: Numerical method of tsunami simulation with the leap-frog scheme. Technical report, IOC Manuals and Guides, UNESCO, Paris, 1997
work page 1997
-
[20]
S. T. Grilli and P. Watts. Tsunami generation by submarine mass failure. I: Modeling, experimental validation, and sensitivity analyses.J. Waterw. Port Coast. Ocean Eng., 131(6):283–297, 2005
work page 2005
-
[21]
P. Holl, N. Thuerey, and V . Koltun. Learning to Control PDEs with Differentiable Physics. InInternational Conference on Learning Representations, 2020
work page 2020
-
[22]
M. J. Hossen, A. Gusman, K. Satake, and P. R. Cummins. An adjoint sensitivity method applied to time reverse imaging of tsunami source for the 2009 samoa earthquake.Geophys. Res. Lett., 45(2):627–636, 2018
work page 2009
-
[23]
R. Keppler, R. Fensholt, and J. Koch. Learning 2D shallow water equations with physics-informed neural operator networks.Authorea Preprints, 2025
work page 2025
-
[24]
D. Kochkov, J. A. Smith, A. Alieva, Q. Wang, M. P. Brenner, and S. Hoyer. Machine learning–accelerated computational fluid dynamics.Proc. Natl. Acad. Sci. U.S.A, 118(21):e2101784118, 2021
work page 2021
-
[25]
D. Kochkov, J. Yuval, I. Langmore, P. Norgaard, J. Smith, G. Mooers, M. Klöwer, J. Lottes, S. Rasp, P. Düben, et al. Neural general circulation models for weather and climate.Nature, 632(8027):1060–1066, 2024
work page 2024
- [26]
-
[27]
R. Leiteritz, M. Hurler, and D. Pflüger. Learning free-surface flow with physics-informed neural networks. In2021 20th IEEE International Conference on Machine Learning and Applications (ICMLA), pages 1668–1673. IEEE, 2021
work page 2021
-
[28]
C. M. Liu, D. Rim, R. Baraldi, and R. J. LeVeque. Comparison of machine learning approaches for tsunami forecasting from sparse observations.Pure Appl. Geophys., 178(12):5129–5153, 2021. 19
work page 2021
-
[29]
P. L.-F. Liu, Y .-S. Cho, M. J. Briggs, U. Kanoglu, and C. E. Synolakis. Runup of solitary waves on a circular island.J. Fluid Mech., 302:259–285, 1995
work page 1995
-
[30]
P. J. Lynett, T.-R. Wu, and P. L.-F. Liu. Modeling wave runup with depth-integrated equations.Coast. Eng., 46(2):89–107, 2002
work page 2002
-
[31]
P. A. Madsen, R. Murray, and O. R. Sørensen. A new form of the Boussinesq equations with improved linear dispersion characteristics.Coast. Eng., 15(4):371–388, 1991
work page 1991
-
[32]
S. Marras and K. T. Mandli. Modeling and simulation of tsunami impact: a short review of recent advances and future challenges.Geosciences, 11(1):5, 2020
work page 2020
-
[33]
M. Matsuyama and H. Tanaka. An experimental study of the highest run-up height in the 1993 Hokkaido Nansei-oki earthquake tsunami. InProceedings of the International Tsunami Symposium (7–10 August 2001, Seattle, WA), pages 879–889, 2001
work page 1993
-
[34]
Jerome Monnier, Frédéric Couderc, Denis Dartus, Kévin Larnier, Ronan Madec, and J-P Vila. Inverse algorithms for 2D shallow water equations in presence of wet dry fronts: Application to flood plain dynamics.Adv. Water Resour ., 97:11–24, 2016
work page 2016
-
[35]
I. E. Mulia, A. R. Gusman, and K. Satake. Applying a deep learning algorithm to tsunami inundation database of megathrust earthquakes.J. Geophys. Res. Solid Earth, 125(9):e2020JB019690, 2020
work page 2020
-
[36]
I. E. Mulia, N. Ueda, T. Miyoshi, A. R. Gusman, and K. Satake. Machine learning-based tsunami inundation prediction derived from offshore observations.Nat. Commun., 13(1):5489, 2022
work page 2022
-
[37]
I. M. Navon. Practical and theoretical aspects of adjoint parameter estimation and identifiability in meteorology and oceanography.Dynam. Atmos. Ocean., 27(1-4):55–79, 1998
work page 1998
-
[38]
C. Pires and P. Miranda. Tsunami waveform inversion by adjoint methods.J. Geophys. Res. Oceans, 106(C9):19773–19796, 2001
work page 2001
-
[39]
X. Qi, G. A. M. de Almeida, and S. Maldonado. Physics-informed neural networks for solving flow problems modeled by the 2D shallow water equations without labeled data.J. Hydrol, page 131263, 2024
work page 2024
-
[40]
Universal Differential Equations for Scientific Machine Learning
C. Rackauckas, Y . Ma, J. Martensen, C. Warner, K. Zubov, R. Supekar, D. Skinner, A. Ramadhan, and A. Edelman. Universal differential equations for scientific machine learning.arXiv preprint arXiv:2001.04385, 2020
work page internal anchor Pith review arXiv 2001
-
[41]
J. V . Ringwood, G. Bacelli, and F. Fusco. Energy-maximizing control of wave-energy converters: The development of control system technology to optimize their operation.IEEE Control Syst., 34(5):30–55, 2014
work page 2014
-
[42]
B. F. Sanders and N. D. Katopodes. Adjoint sensitivity analysis for shallow-water wave control.J. Eng. Mech., 126(9):909–919, 2000
work page 2000
-
[43]
F. Sapienza, J. Bolibar, F. Schäfer, B. Groenke, A. Pal, V . Boussange, P. Heimbach, G. Hooker, F. Pérez, P.-O. Persson, et al. Differentiable programming for differential equations: A review.arXiv preprint arXiv:2406.09699, 2024
-
[44]
M. Someya and T. Furumura. Physics-informed neural networks for offshore tsunami data assimilation. Geophys. J. Int., 242(3):ggaf243, 2025
work page 2025
-
[45]
P. St-Germain, I. Nistor, R. Townsend, and T. Shibayama. Smoothed-particle hydrodynamics numerical modeling of structures impacted by tsunami bores.J. Waterw. Port Coast. Ocean Eng.g, 140(1):66–81, 2014
work page 2014
-
[46]
G. Stelling and M. Zijlema. An accurate and efficient finite-difference algorithm for non-hydrostatic free-surface flow with application to wave propagation.Int. J. Numer . Methods Fluids, 43(1):1–23, 2003
work page 2003
-
[47]
R. S. Sutton and A. G. Barto.Reinforcement learning: An introduction, volume 1. MIT press Cambridge, 1998
work page 1998
-
[48]
V . V . Titov and F. I. Gonzalez. Implementation and testing of the method of splitting tsunami (MOST) model. Technical report, NOAA Technical Memorandum ERL PMEL-112, 1997
work page 1997
-
[49]
V . V . Titov and C. E. Synolakis. Numerical modeling of tidal wave runup.J. Waterway, Port, Coastal, Ocean Eng., 124(4):157–171, 1998
work page 1998
-
[50]
K. Um, R. Brand, Y . R. Fei, P. Holl, and N. Thuerey. Solver-in-the-loop: Learning from differentiable physics to interact with iterative pde-solvers.Advances in neural information processing systems, 33:6111– 6122, 2020
work page 2020
- [51]
-
[52]
S. Wang, X. Yu, and P. Perdikaris. When and why PINNs fail to train: a neural tangent kernel perspective. J. Comput. Phys., 449:110768, 2022
work page 2022
-
[53]
T. Whittaker, S. Taylor, E. Cardoso-Bihlo, A. Di Luca, and A. Bihlo. Learning vertical coordinates via automatic differentiation of a dynamical core.arXiv preprint arXiv:2512.17877, 2025
-
[54]
J. Wu, X. Hao, T. Li, and L. Shen. Adjoint-based high-order spectral method of wave simulation for coastal bathymetry reconstruction.J. Fluid Mech., 972:A41, 2023. 20
work page 2023
-
[55]
Y . Yamazaki, Z. Kowalik, and K.F. Cheung. Depth-integrated, non-hydrostatic model for wave breaking and run-up.Int. J. Numer . Methods Fluids, 61(5):473–497, 2009
work page 2009
-
[56]
M. Zijlema and G. S. Stelling. Efficient computation of surf zone waves using the nonlinear shallow water equations with non-hydrostatic pressure.Coast. Eng., 55(10):780–790, 2008. A Implementation and training details All experiments were implemented using the AegirJAX solver, written natively in Python utilizing the JAX library for reverse-mode automati...
work page 2008
discussion (0)
Sign in with ORCID, Apple, or X to comment. Anyone can read and Pith papers without signing in.