src/test/mask.c
Checks that “half-mapped” fine/coarse cells do not cause trouble with boundary conditions.
#define TRASH 1
#include "grid/quadtree.h"
int main() {
(N);
init_grid
scalar s[];
face vector v[];
// mask (y > L0/4. ? top : none);
mask (sq(x - 0.5) + sq(y - 0.5) > sq(0.3) ? top : none);
output_cells (stdout);
for (int l = depth(); l > 0; l--)
(restriction,l)
foreach_halo fprintf (stderr, "%g %g %d\n", x, y, l);
fflush (stderr);
foreach()
[] = 1.;
sboundary ({s});
foreach_face()
.x[] = 1.;
vboundary ((scalar *){v});
((scalar *){v});
restriction }