Skip to content
Raul edited this page Sep 17, 2019 · 2 revisions

Smoothed Particle Hydrodynamics

See SPH.cuh or examples/SPH.cu

SPH is an Interactor module, any simplectic integrator can be used with it (i.e VerletNVE).

Computes a force on each particle as:
Fi = sum_j[ mj·(Pj/rhoj^2 + Pi/rhoi^2 + visij)·grad_i(Wij) ]

Where:

j: The neighbours of i (within a distance given by the support of Wij)  
m: mass  
P: Pressure  
rho: Density  
vis: Artificial viscosity  

W: Interpolation kernel, a smooth decaying function with a close support. See SPH_ns::Kernel  

The density on a given particle i is interpolated from its neighbours as:
rho_i = sum_j[ mj·Wij ]

The Pressure is given by an equation-of-state depending on interpolated properties of the particles. Currently:
Pi = K·(rho_i-rho0)

An artificial viscosity is introduced to allow shock phenomena ans stabilize the algorithm.
visij = -nu( vij·rij)/(rij^2+epsilon)
epsilon ~ 0.001
v: velocity
r: particle position

There are two examples using SPH, SPH.cu and dambreak.cu.

References:

[1] Smoothed particle hydrodynamics. JJ Monaghan. Rep. Prog. Phys. 68 (2005) 1703–1759 doi:10.1088/0034-4885/68/8/R01









Clone this wiki locally