TL;DR
Simulating chaotic, multiscale fluid flows with generative diffusion models yields high physical fidelity but requires hundreds of slow denoising steps. This paper introduces RecFlow, a framework adapting rectified flows to conditional PDEs that learns straight ODE trajectories from noise to solution states. Paired with a curvature-aware adaptive ODE integrator, RecFlow matches diffusion-quality statistics and energy spectra with just 8–10 solver steps—delivering up to a 22× inference speedup and converging significantly faster during training.
What Problem Does This Paper Address?
Simulating multiscale, chaotic fluid flows (like turbulent mixing or shock-wave interactions) requires resolving tiny vortices and high-frequency wave interactions. Standard deterministic surrogate models (like Fourier Neural Operators, FNO) trained via Mean Squared Error (MSE) suffer from "spectral collapse," over-smoothing fine-scale turbulence into an unphysical blur.
Recent generative surrogates based on conditional score-based diffusion (e.g., GenCFD) fix this by learning posterior distributions over flow states. However, diffusion models require simulating reverse-time stochastic differential equations (SDEs) over 100+ discretization steps. Because each step evaluates an expensive high-resolution neural network, real-time prediction and large-ensemble uncertainty quantification (UQ) remain computationally prohibitive.
Methods
The authors replace the curved stochastic reverse-SDE path of diffusion models with a deterministic Rectified Flow (RecFlow):
- Straight Transport via Rectified Flows: Instead of wandering through noise space, RecFlow learns an ODE velocity field $v_\theta(u_\tau, u_i, \tau)$ that pushes probability distributions along nearly straight linear interpolations $X_\tau = (1-\tau)u_0 + \tau u_1$. Straighter paths mean numerical ODE solvers can take drastically larger steps without accumulating truncation errors.
- Curvature-Aware Integration: The authors introduce an adaptive solver mechanism requiring no extra model training:
- An Exponential Moving Average (EMA) tracks velocity trends: $v^{\text{ema}}_t = \lambda v^{\text{ema}}_{t-\Delta \tau} + (1-\lambda) v_t$.
- A straightness score $s_t = \|v_t - v^{\text{ema}}_t\|_2$ flags regions where the trajectory curves.
- When $s_t$ spikes, a Tikhonov-regularized convex blend gently smooths the predicted velocity towards $v^{\text{ema}}$, and an adaptive step-size rule contracts the step size $\Delta \tau_t \propto 1 / \sqrt{\kappa_1 s_t + \kappa_2}$ to keep local truncation error bounded.
- Architecture: A UViT backbone (a U-Net with multi-head self-attention at the bottleneck and Feature-wise Linear Modulation / FiLM temporal conditioning) predicting the displacement field.
Datasets
The authors benchmark across three 2D multiscale fluid mechanics problems:
- SL2D (Shear Layer): Incompressible 2D Navier–Stokes system modeling shear-layer roll-up into vortices (spectral viscosity solver at $512^2$, downsampled to $128^2$; 79,200 samples).
- CS2D (Cloud-Shock Interaction): Compressible Euler equations modeling a planar shock wave striking a dense cloud (finite-volume ALSVINN solver at $256^2$, downsampled to $128^2$; 40,000 samples).
- RM2D (Richtmyer–Meshkov): Compressible Euler equations simulating shock-driven fluid interface instability and turbulent mixing (ALSVINN solver at $256^2$, downsampled to $128^2$; 64,000 samples).
Evaluation uses an ensemble-perturbation protocol: generating micro-ensembles (1,000 perturbed initial conditions within an $\varepsilon$-ball) evolved via high-fidelity PDE solvers to construct empirical ground-truth posterior distributions for chaotic regimes.
Key Insights and Ideas
- Straightening beats diffusion ODE tricks: Running a probability-flow ODE (PF-ODE) or standard non-rectified flow matching on pre-trained diffusion networks does not solve the problem—their velocity fields remain stiff and still require large step counts ($>8$) to capture spectra accurately. Rectifying the transport trajectories during training is what genuinely linearizes the dynamics.
- Curvature as a controller, not a detector: While prior diffusion work uses trajectory curvature for out-of-distribution (OOD) detection, RecFlow uses curvature as an active runtime control knob to regularize updates and adapt step sizes dynamically.
- Training efficiency gains: Rectified flows converge much faster than diffusion models in compute time. RecFlow outperformed a capacity-matched (22M parameter) GenCFD model across all metrics by ~100k training iterations, while GenCFD required 300k–600k iterations to reach comparable accuracy on several metrics (and never matched RecFlow on cross-velocity Wasserstein distance).
Key Results
- Inference Speed: RecFlow requires only 8–10 ODE integration steps (vs. $\ge 128$ steps for GenCFD / diffusion baselines), achieving up to a 22× wall-clock speedup.
- Statistical and Spectral Fidelity:
- On CS2D, RecFlow achieved a 1-point Wasserstein distance ($W_1$) of $0.0091$ on density $\rho$ (compared to GenCFD's $0.0151$ and FNO's $0.1455$).
- On SL2D, RecFlow reached $W_1 = 0.0214$ on $u_x$ and $0.0164$ on $u_y$, outperforming both GenCFD ($0.0276, 0.0213$) and deterministic FNO ($0.184, 0.150$).
- RecFlow captures high-wavenumber energy spectra in as few as 5 steps, accurately reproducing power-law turbulent decay where score-based diffusion remains noisy and under-resolved.
- Curvature-Aware Integration Impact: Applying the curvature-aware integration scheme produced an additional 2.6% error reduction on CS2D and 6.0% error reduction on SL2D over standard Euler integration.
Limitations and Future Work
- 2D Benchmarks: Validation is currently restricted to 2D incompressible and compressible flows; extending the framework to full 3D turbulence and multiphysics systems remains future work.
- Discretization and Architecture: While UViT scales well, developing more lightweight architectures for ultra-fast, real-time edge deployment is still an open area.
- UQ Integration: Further work is needed to integrate RecFlow directly into active uncertainty-quantification and PDE-constrained optimization pipelines.
Summary updated