sandbox/Antoonvh/ns4t.c
Tracers
First, b
is the buoyancy and c
is a tracer,
next it is reversed. Finally, both a active tracers, but represent the
buoyancy is different directions.
c
, b
and particle tracers
#include "nsf4t.h"
#include "tracer-particles.h"
#include "view.h"
#include "scatter2.h"
scalar b[], c[], * tracers = {b, c};
scalar zeros[]; // Just zeros
Particles parts;
int main() {
foreach_dimension()
periodic (left);
= 10;
L0 = Y0 = -L0/2;
X0 const scalar muz[] = 0.001;
= nu = muz;
kappa = 128;
N .x = zeros;
a.y = b;
arun();
.y = c;
arun();
.x = b;
arun();
}
event init (t = 0) {
= init_tp_circle (100);
parts foreach_particle_in(parts) {
double R = sqrt(sq(x) + sq(y));
().x /= R;
p().y /= R;
p}
() { foreach_vert
[] = exp (-sq(x) - sq(y)) ; b

constant field ācā must be declared (const)