Entropically Damped Artificial Compressibility (EDAC) for SPH
As opposed to the weakly compressible SPH scheme, which uses an equation of state, this scheme uses a pressure evolution equation to calculate the pressure
\[\frac{\mathrm{d} p_a}{\mathrm{d}t} = - \rho c_s^2 \nabla \cdot v + \nu \nabla^2 p,\]
which is derived by Clausen (2013). This equation is similar to the continuity equation (first term, see ContinuityDensity
), but also contains a pressure damping term (second term, similar to density diffusion see DensityDiffusion
), which reduces acoustic pressure waves through an entropy-generation mechanism.
The pressure evolution is discretized with the SPH method by Ramachandran (2019) as following:
The first term is equivalent to the classical artificial compressible methods, which are commonly motivated by assuming the artificial equation of state (StateEquationCole
with exponent=1
) and is discretized as
\[- \rho c_s^2 \nabla \cdot v = \sum_{b} m_b \frac{\rho_a}{\rho_b} c_s^2 v_{ab} \cdot \nabla_{r_a} W(\Vert r_a - r_b \Vert, h),\]
where $\rho_a$, $\rho_b$, $r_a$, $r_b$, denote the density and coordinates of particles $a$ and $b$ respectively, $c_s$ is the speed of sound and $v_{ab} = v_a - v_b$ is the difference in the velocity.
The second term smooths the pressure through the introduction of entropy and is discretized as
\[\nu \nabla^2 p = \frac{V_a^2 + V_b^2}{m_a} \tilde{\eta}_{ab} \frac{p_{ab}}{\Vert r_{ab}^2 \Vert + \eta h_{ab}^2} \nabla_{r_a} W(\Vert r_a - r_b \Vert, h) \cdot r_{ab},\]
where $V_a$, $V_b$ denote the volume of particles $a$ and $b$ respectively and $p_{ab}= p_a -p_b$ is the difference in the pressure.
The viscosity parameter $\eta_a$ for a particle $a$ is given as
\[\eta_a = \rho_a \frac{\alpha h c_s}{8},\]
where it is found in the numerical experiments of Ramachandran (2019) that $\alpha = 0.5$ is a good choice for a wide range of Reynolds numbers (0.0125 to 10000).
The EDAC formulation keeps the density constant and this eliminates the need for the continuity equation or the use of a summation density to find the pressure. However, in SPH discretizations, $m/\rho$ is typically used as a proxy for the particle volume. The density of the fluids can therefore be computed using the summation density approach.
Ramachandran (2019)
TrixiParticles.EntropicallyDampedSPHSystem
— TypeEntropicallyDampedSPHSystem(initial_condition, smoothing_kernel,
smoothing_length, sound_speed;
pressure_acceleration=inter_particle_averaged_pressure,
density_calculator=SummationDensity(),
alpha=0.5, viscosity=nothing,
acceleration=ntuple(_ -> 0.0, NDIMS), buffer_size=nothing,
source_terms=nothing)
System for particles of a fluid. As opposed to the weakly compressible SPH scheme, which uses an equation of state, this scheme uses a pressure evolution equation to calculate the pressure. See Entropically Damped Artificial Compressibility for SPH for more details on the method.
Arguments
initial_condition
: Initial condition representing the system's particles.sound_speed
: Speed of sound.smoothing_kernel
: Smoothing kernel to be used for this system. See Smoothing Kernels.smoothing_length
: Smoothing length to be used for this system. See Smoothing Kernels.
Keyword Arguments
viscosity
: Viscosity model for this system (default: no viscosity). Recommended:ViscosityAdami
.acceleration
: Acceleration vector for the system. (default: zero vector)pressure_acceleration
: Pressure acceleration formulation (default: inter-particle averaged pressure). When set tonothing
, the pressure acceleration formulation for the corresponding density calculator is chosen.density_calculator
: Density calculator (default:SummationDensity
)buffer_size
: Number of buffer particles. This is needed when simulating withOpenBoundarySPHSystem
.source_terms
: Additional source terms for this system. Has to be eithernothing
(by default), or a function of(coords, velocity, density, pressure, t)
(which are the quantities of a single particle), returning aTuple
orSVector
that is to be added to the acceleration of that particle. See, for example,SourceTermDamping
. Note that these source terms will not be used in the calculation of the boundary pressure when using a boundary withBoundaryModelDummyParticles
andAdamiPressureExtrapolation
. The keyword argumentacceleration
should be used instead for gravity-like source terms.
References
- Prabhu Ramachandran. "Entropically damped artificial compressibility for SPH". In: Computers and Fluids 179 (2019), pages 579–594. doi: 10.1016/j.compfluid.2018.11.023
- Jonathan R. Clausen. "Entropically damped form of artificial compressibility for explicit simulation of incompressible flow". In: American Physical Society 87 (2013), page 13309. doi: 10.1103/PhysRevE.87.013309