|
__kernel void | entry (const __global int *imove, const __global int *imirrored, const __global vec *r, const __global vec *rmirrored, const __global vec *u, const __global vec *umirrored, const __global float *rho, const __global float *m, const __global float *p, const __global float *h_var, const __global float *Omega, __global vec *grad_p, __global vec *lap_u, __global float *div_u, __global float *shepard, __global uint *icell, __global uint *ihoc, uint N, uivec4 n_cells) |
| Particles interactions computation.
|
|
Particles interactions computation.
__kernel void entry |
( |
const __global int * |
imove, |
|
|
const __global int * |
imirrored, |
|
|
const __global vec * |
r, |
|
|
const __global vec * |
rmirrored, |
|
|
const __global vec * |
u, |
|
|
const __global vec * |
umirrored, |
|
|
const __global float * |
rho, |
|
|
const __global float * |
m, |
|
|
const __global float * |
p, |
|
|
const __global float * |
h_var, |
|
|
const __global float * |
Omega, |
|
|
__global vec * |
grad_p, |
|
|
__global vec * |
lap_u, |
|
|
__global float * |
div_u, |
|
|
__global float * |
shepard, |
|
|
__global uint * |
icell, |
|
|
__global uint * |
ihoc, |
|
|
uint |
N, |
|
|
uivec4 |
n_cells |
|
) |
| |
Particles interactions computation.
Compute the rates of variation due to the fluid (fixed particles will be included here).
During this stage some other operations are performed as well, like the values interpolation in the boundaries (for DeLeffe boundary conditions), the sensors meassurement, or the Shepard factor computation.
- Parameters
-
imove | Moving flags.
- imove > 0 for regular fluid particles.
- imove = 0 for sensors.
- imove < 0 for boundary elements/particles.
|
imirrored | 0 if the particle has not been mirrored, 1 otherwise. |
r | Position \( \mathbf{r} \). |
rmirrored | Mirrored position of the particle, r if imirrored is false (0). |
u | Velocity \( \mathbf{u} \). |
umirrored | Mirrored velocity of the particle, u if imirrored is false (0). |
rho | Density \( \rho \). |
m | Mass \( m \). |
p | Pressure \( p \). |
h_var | variable kernel lenght \( h \). |
Omega | \( \Omega \) term. |
grad_p | Pressure gradient \( \frac{\nabla p}{rho} \). |
lap_u | Velocity laplacian \( \frac{\Delta \mathbf{u}}{rho} \). |
div_u | Velocity divergence \( \rho \nabla \cdot \mathbf{u} \). |
shepard | Shepard term \( \gamma(\mathbf{x}) = \int_{\Omega}
W(\mathbf{y} - \mathbf{x}) \mathrm{d}\mathbf{x} \). |
icell | Cell where each particle is located. |
ihoc | Head of chain for each cell (first particle found). |
N | Number of particles. |
n_cells | Number of cells in each direction |