vm_sph_grid struct

Uniform cell grid for SPH neighbor search.

Origin is the lower corner. cell should be the kernel support (2h). ny == nz == 1 is 1-D; nz == 1 is 2-D. Cell (i, j, k) covers [x0 + i cell, x0 + (i+1) cell) and the same in y and z. A particle on the far boundary is assigned to the last cell.

Public variables

vm_float_t x0
Lower corner, x.
vm_float_t y0
Lower corner, y.
vm_float_t z0
Lower corner, z.
vm_float_t cell
Cell size.
int nx
Cells in x.
int ny
Cells in y.
int nz
Cells in z.