AQUAgpusph 4.1.2
Loading...
Searching...
No Matches
Functions
PreInteractions.cl File Reference

Fixed ghost particles mirroring process. More...

#include "resources/Scripts/types/types.h"
#include "resources/Scripts/KernelFunctions/Kernel.h"
Include dependency graph for PreInteractions.cl:

Functions

__kernel void entry (const __global uint *iset, const __global int *imove, const __global uint *associations, const __global vec *r, const __global vec *normal, const __global vec *dudt, const __global vec *lap_u, const __global float *gp_p, const __global vec *gp_u, __global float *rho, __global float *p, __global vec *u, __constant float *visc_dyn, uint N, vec g)
 Pressure and velocity extensions for the computation of the differential operators, except the Laplacian of the velocity already computed.
 

Detailed Description

Fixed ghost particles mirroring process.

Function Documentation

◆ entry()

__kernel void entry ( const __global uint *  iset,
const __global int *  imove,
const __global uint *  associations,
const __global vec r,
const __global vec normal,
const __global vec dudt,
const __global vec lap_u,
const __global float *  gp_p,
const __global vec gp_u,
__global float *  rho,
__global float *  p,
__global vec u,
__constant float *  visc_dyn,
uint  N,
vec  g 
)

Pressure and velocity extensions for the computation of the differential operators, except the Laplacian of the velocity already computed.

For the Divergence of the velocity, the normmal velocity is mirrored (ASM), while the mirrored interpolated value is used for the tangential velocity (SSM).

For the pressure the following expression is used:

\( p(\mathbf{r}) = p(\hat{\mathbf{r}}) + \frac{\partial{p}}{\partial{\mathbf{n_b}}} \cdot \left( \hat{\mathbf{r}} - \mathbf{r}\right) \)

where the derivative of the pressure is computed as:

\( \frac{\partial{p}}{\partial{\mathbf{n_b}}} = \rho \left[ \mathbf{g} - \frac{\mathrm{d}\mathbf{u_b}}{\mathrm{d}t} + \frac{\mu}{\rho} \Delta \mathbf{u} \right] \cdot \mathbf{n_b} \)

Parameters
isetSet of particles index.
imoveMoving flags.
  • imove > 0 for regular fluid particles.
  • imove = 0 for sensors.
  • imove < 0 for boundary elements/particles.
associationsMirroring particles.
rPosition \( \mathbf{r} \).
normalNormal \( \mathbf{n} \).
dudtVelocity rate of change \( \left. \frac{d \mathbf{u}}{d t} \right\vert_{n+1} \).
lap_uVelocity laplacian \( \frac{\Delta \mathbf{u}}{rho} \).
gp_pInterpolated pressure in the mirrored position \( p \).
gp_uInterpolated velocity in the mirrored position \( \mathbf{u} \).
rhoDensity \( \rho \).
pPressure \( p \).
uVelocity \( \mathbf{u} \).
visc_dynDynamic viscosity \( \mu \).
NNumber of particles.
gGravity acceleration \( \mathbf{g} \).