aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/rotatingsymmetry90.c18
1 files changed, 17 insertions, 1 deletions
diff --git a/src/rotatingsymmetry90.c b/src/rotatingsymmetry90.c
index b73e29d..8e89689 100644
--- a/src/rotatingsymmetry90.c
+++ b/src/rotatingsymmetry90.c
@@ -419,11 +419,12 @@ int BndRot90VI (cGH const * restrict const cctkGH,
if (data.gsh[otherdir[q]] < data.nghostzones[dir[q]] + data.nghostzones[otherdir[q]] + offset[otherdir[q]]) {
assert (nvars > 0);
+ var = 0;
CCTK_VWarn (0, __LINE__, __FILE__, CCTK_THORNSTRING,
"The group \"%s\" has in the %c-direction only %d grid points. "
"This is not large enough for a 90 degree rotating symmetry boundary that is %d grid points wide in the %c-direction. "
"The group needs to have at least %d grid points in the %c-direction.",
- CCTK_GroupNameFromVarI(vis[0]), "xyz"[dir[q]], data.gsh[dir[q]],
+ CCTK_GroupNameFromVarI(vis[var]), "xyz"[dir[q]], data.gsh[dir[q]],
data.nghostzones[dir[q]], "xyz"[otherdir[q]],
data.nghostzones[dir[q]] + data.nghostzones[otherdir[q]] + offset[otherdir[q]], "xyz"[dir[q]]);
}
@@ -536,6 +537,21 @@ int BndRot90VI (cGH const * restrict const cctkGH,
}
}
break;
+ case CCTK_VARIABLE_COMPLEX:
+ {
+ CCTK_COMPLEX const czero = CCTK_Cmplx (0.0, 0.0);
+ for (k=imin[2]; k<imax[2]; ++k) {
+ for (j=imin[1]; j<imax[1]; ++j) {
+ for (i=imin[0]; i<imax[0]; ++i) {
+ const int ind = CCTK_GFINDEX3D(cctkGH, i, j, k);
+ CCTK_COMPLEX * restrict const ptr =
+ & ((CCTK_COMPLEX *) varptrs[var]) [ind];
+ * ptr = CCTK_CmplxSub (czero, * ptr);
+ }
+ }
+ }
+ }
+ break;
default:
assert (0);
} /* switch grouptype */