Abstract
SPHinXsys (Smoothed Particle Hydrodynamics for industrial compleX sysstems) is an open-source, multi-resolution, and multi-physics library designed to model coupled industrial dynamic systems. Developed under the Apache License (2.0), SPHinXsys provides a unified C++ API for simulating fluids, solids, multi-body dynamics, and electromechanics. By leveraging a multi-resolution framework, the library allows different physical components to operate at distinct spatial and temporal scales, significantly enhancing computational efficiency. This paper details the library's architecture, its core numerical formulations—including Riemann-based SPH and Total Lagrangian formulations—and its performance across various validation benchmarks.
Introduction
Modern industrial design increasingly requires the simulation of complex systems where multiple physical domains interact. Examples range from automotive engineering, involving fluid-thermal-structural interactions, to biomechanics, where electrical signals trigger muscle contractions and blood flow. Traditional mesh-based methods, such as Finite Element Analysis (FEA), often encounter difficulties when dealing with large deformations or complex moving boundaries.
Smoothed Particle Hydrodynamics (SPH), a meshless Lagrangian particle method, offers a robust alternative for these challenges. However, the adoption of SPH in industrial contexts has been hindered by the lack of unified, efficient, and open-source tools. SPHinXsys addresses this gap by providing a flexible C++ library capable of handling multi-physics interactions within a single, cohesive framework.
Core Methodology
SPHinXsys is built upon a Lagrangian particle-based framework where the computational "mesh" moves with the material. This approach is inherently suited for tracking interfaces and handling large deformations. The library introduces several key technical innovations:
Riemann-based SPH for Fluids
To minimize numerical dissipation—a common issue in traditional SPH—SPHinXsys employs Riemann solvers. This is particularly effective for capturing high-energy, violent free-surface flows, such as breaking waves or dambreak scenarios, with high fidelity.
Total Lagrangian Formulation for Solids
For solid mechanics, the library utilizes a Total Lagrangian formulation. This allows for the accurate modeling of large deformations and the implementation of complex constitutive laws, such as the Holzapfel-Ogden model used in cardiac tissue simulation.
Multi-Resolution FSI Coupling
The defining feature of SPHinXsys is its multi-resolution capability. In Fluid-Structure Interaction (FSI) problems, the fluid and solid components can be assigned different particle spacings and time steps. This allows researchers to use a coarse resolution for large fluid domains while maintaining a fine resolution for thin or complex elastic structures, optimizing computational resources.
Numerical Stability and Integration
To ensure physical accuracy, the library uses a Position-Based Verlet scheme for time integration, which maintains strict momentum conservation during FSI. Additionally, for "stiff" equations found in reaction-diffusion problems (e.g., cardiac electrophysiology), an operator-splitting method is employed to handle reaction terms efficiently.
Validation and Performance
The library has been rigorously validated against a suite of established benchmarks:
- Fluid Dynamics: 2D and 3D dambreak flows and sloshing tank simulations.
- Solid Dynamics: Oscillating beams and 3D cantilever bending.
- Fluid-Structure Interaction (FSI): Hydrostatic water columns acting on elastic plates and flow-induced vibrations of flexible beams.
- Diffusion & Electromechanics: Isotropic/anisotropic mass diffusion and a complex biventricular heart model simulating excitation-induced contraction.
The multi-resolution approach provides dramatic performance improvements. In FSI benchmarks, increasing the fluid-to-structure resolution ratio from 2 to 4 resulted in speedups ranging from 240x to 960x compared to traditional single-resolution solvers.
Conclusion and Future Directions
SPHinXsys v0.2.0 establishes a powerful, open-source foundation for multi-physics simulation. By decoupling spatial and temporal scales, it allows for high-fidelity modeling of complex systems without the prohibitive computational costs of uniform high-resolution grids.
Future development focuses on three main areas: implementing GPGPU (General-Purpose Graphics Processing Unit) acceleration to further increase performance, expanding industrial modules for applications like wave energy converters, and evolving the electromechanics module into a full-scale "open heart simulator."
Reference: Zhang, C., et al. (2020). SPHinXsys: an open-source multi-physics and multi-resolution library based on smoothed particle hydrodynamics. Computer Physics Communications.
Summary updated