arXiv ScienceSearch

arXiv · 2305.09163

Method for portable, scalable, and performant GPU-accelerated simulation of multiphase compressible flow

Abstract

Multiphase compressible flows are often characterized by a broad range of space and time scales. Thus entailing large grids and small time steps, simulations of these flows on CPU-based clusters can thus take several wall-clock days. Offloading the compute kernels to GPUs appears attractive but is memory-bound for standard finite-volume and -difference methods, damping speed-ups. Even when realized, faster GPU-based kernels lead to more intrusive communication and I/O times. We present a portable strategy for GPU acceleration of multiphase compressible flow solvers that addresses these challenges and obtains large speedups at scale. We use OpenACC for portable offloading of all compute kernels while maintaining low-level control when needed. An established Fortran preprocessor and metaprogramming tool, Fypp, enables otherwise hidden compile-time optimizations. This strategy exposes compile-time optimizations and high memory reuse while retaining readable, maintainable, and compact code. Remote direct memory access, realized via CUDA-aware MPI, reduces communication times. We implement this approach in the open-source solver MFC. Metaprogramming-based preprocessing results in an 8-times speedup of the most expensive kernels, 46% of peak FLOPs on NVIDIA GPUs, and high arithmetic intensity (about 10 FLOPs/byte). In representative simulations, a single A100 GPU is 300-times faster than an Intel Xeon CPU core, corresponding to a 9-times speedup for a single A100 compared to the entire CPU die. At the same time, near-ideal (97%) weak scaling is observed for at least 13824 GPUs on Summit. A strong scaling efficiency of 84% is retained for an 8-times increase in GPU count. Collective I/O, implemented via MPI3, helps ensure negligible contribution of data transfers. Large many-GPU simulations of compressible (solid-)liquid-gas flows demonstrate the practical utility of this strategy.

Explore related subjects

Keep this discovery

Explore connections, maps & timelines

BibTeXRIS

Anand Radhakrishnan, Henry Le Berre, Benjamin Wilfong, Jean-Sebastien Spratt, Mauro Rodriguez Jr., Tim Colonius, Spencer H. Bryngelson. 2024-02-03. Method for portable, scalable, and performant GPU-accelerated simulation of multiphase compressible flow. https://doi.org/10.1016/j.cpc.2024.109238

Cite the original work for its findings. Save a collection to share your selection of sources.

KEEP EXPLORING

Related papers

Mathematical modeling on peristaltic flow of a Prandtl fluid with effects of slip conditions and inclined magnetic field

The manuscript provides a description of a theoretical analysis of a non-Newtonian Prandtl fluid subject to peristaltic flow through an inclined asymmetric channel. We explore the effect of an inclined magnetic field on the peristaltic flow. This is relevant for applications involving fluid flow in narrow, inclined (tilted) tubes similar to blood vessels or the digestive system. The model also includes thermodynamic aspects such as heat diffusion (the Soret effect) and viscous dissipation resulting from wall-fluid slip conditions, which may help optimize medical devices such as lab-on-a-chip systems and dialysis machines. In this study, the concentration of a generic chemical, temperature, and fluid velocity are taken into account through mass, heat, and momentum balances, respectively. The solution is approximated using numerical techniques suitable for long wavelengths (low frequency) and low Reynolds numbers. The study also discusses trapping phenomena, which are crucial from a clinical point of view. The developed insights can improve the understanding of physiological flows in the gastrointestinal tract and blood vessels. By understanding how the fluid moves and how particles are trapped, these insights may contribute to the design of improved medical pumps and artificial organs. Graphical visualizations are provided for the fluid velocity profile, temperature distribution, and concentration of a generic chemical. Furthermore, the numerical results are validated through comparison with a closed-form solution from a benchmark problem.

physics.flu-dyn

Discovery of a dispersion model at high Peclet numbers

Peclet number characterises the transition from classical Taylor-Aris dispersion to convection-dominated longitudinal solute transport, with the classical model becoming inadequate at extremely high radial Peclet number $Pe_r$. We develop a novel explicit-closure one-dimensional (1-D) effective dispersion model for this high-$Pe_r$ regime by introducing two closure coefficients, $θ_u$ and $θ_d$, whose functional structures are identified using low-frequency transfer-function matching and a modified Kolmogorov-Arnold network (KAN). The resulting model captures the transition from classical Taylor-Aris dispersion at low $Pe_r$ to convection-dominated dispersion at high $Pe_r$. Analysis reveals that, in the high-$Pe_r$ regime, axial transport is redistributed between the effective convection flux and the dispersive flux, resulting in a reduced macroscopic convection velocity. Numerical validation demonstrates close agreement with the convection-diffusion model over the investigated high-$Pe_r$ conditions, while the classical Taylor-Aris model exhibits substantial deviations. Application of the proposed model to averaged flow velocity inversion further demonstrates improved velocity estimation, particularly in the high-$Pe_r$ regime. These results highlight the importance of accounting for non-classical dispersion for reliable contrast-agent-based arterial blood flow velocimetry and provide new insight into high-$Pe_r$ mass transport.

physics.flu-dyn

Optimization of fluid mixing by reinforcement learning using limit cycles of a dynamical system

We propose a method to overcome the difficulties encountered when applying reinforcement learning to fluid mixing processes. The proposed method has two main features: (i) it does not require detailed measurements of the flow state, and (ii) by effectively exploiting a stable limit cycle of a two-dimensional dynamical system (the Li'enard system), it can stably perform optimization without imposing explicit constraints on the control parameters. As an illustrative example, we optimize a process in which a fluid contained in a cylindrical vessel is mixed by periodically rotating the vessel. The resulting optimal vessel motion is physically reasonable: it reverses its direction of rotation before a solid-body rotation state is established. Furthermore, even when the fluid viscosity increases with time during the mixing process, the method can continuously adapt the control parameters to the changing viscosity.

physics.flu-dyn