arriemeijer-creator/AeroJAX
AeroJAX: A differentiable, structure-preserving framework for real-time flow simulation, control, and inverse design. Architected for neural operator integration and latent-space acceleration. Built with JAX.
What it solves
AeroJAX transforms Computational Fluid Dynamics (CFD) from a batch-oriented process into an interactive experience. Traditional CFD requires configuring a simulation, running it to completion, and analyzing results afterward; AeroJAX allows users to modify solver parameters, boundary conditions, and geometries in real-time without restarting the simulation.
How it works
Built on JAX, the framework implements an end-to-end differentiable pipeline. It supports both incompressible Navier-Stokes (finite-difference) and Lattice Boltzmann (D2Q9/D2Q7) solvers. To achieve real-time performance on CPUs, it uses decoupled solver, render, and metrics threads with shared-memory zero-copy buffers. It employs Brinkman penalization for immersed boundaries, allowing users to draw obstacles or move airfoils live. For numerical stability and accuracy, it offers various advection schemes (RK2/RK3) and pressure solvers (FFT, Conjugate Gradient, Multigrid), alongside Smagorinsky LES models for turbulence.
Who it’s for
It is designed for flow research, control, and inverse design, particularly for those prototyping 2D fluid simulations or researching neural operators for CFD.
Highlights
- Interactive Geometry: Draw custom obstacles with a mouse or drag NACA airfoils across the domain during runtime.
- Differentiable Solver: JAX-native implementation enables gradient-based inverse design (e.g., optimizing airfoil shapes to minimize drag) without a separate adjoint solver.
- Numerical Transparency: A Solver Trace Viewer allows step-by-step inspection of the numerical pipeline, exposing intermediate fields and LaTeX-rendered equations.
- Neural Operator Integration: Includes experimental tools to generate datasets, train neural operators, and swap the standard pressure solver for a trained model mid-simulation.
- High CPU Performance: Optimized for real-time use, reaching ~297 FPS on a laptop CPU for a 512×96 grid.
Related
- Project
- Project
- Project
- Project