aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/interpolate.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/interpolate.c b/src/interpolate.c
index fcaa51a..8c1f61b 100644
--- a/src/interpolate.c
+++ b/src/interpolate.c
@@ -297,7 +297,7 @@ ReflectionSymmetry_Interpolate (CCTK_POINTER_TO_CONST restrict const cctkGH_,
assert (groupname);
CCTK_VWarn (0, __LINE__, __FILE__, CCTK_THORNSTRING,
"Illegal tensor type alias \"%s\" for group \"%s\"",
- tensortypealias, groupname);
+ tensortypealias, groupname);
free (groupname);
}
@@ -434,23 +434,24 @@ ReflectionSymmetry_Interpolate (CCTK_POINTER_TO_CONST restrict const cctkGH_,
/* Are there negative parities? */
needs_checking = 0;
for (dir=0; dir<3; ++dir) {
- check_dir[dir] = do_reflection[2*dir] && parities[dir] < 0;
+ check_dir[dir] = do_reflection[2*dir] && parities[dir]*tensorparity < 0;
needs_checking |= check_dir[dir];
}
+
/* Loop over all points and unfold */
if (needs_checking) {
for (n=0; n<N_interp_points; ++n) {
- int parity = tensorparity;
+ int parity = 1; /* all types have their "natural" sign in the +++ octant */
/* Is the point outside the domain? */
for (dir=0; dir<3; ++dir) {
if (check_dir[dir]) {
CCTK_REAL const pos = ((CCTK_REAL const *)interp_coords[dir])[n];
if (pos < 0) {
/* Reflect the tensor component */
- parity *= -1;
+ parity *= -1; /* we only get here if parities[dir]*tensorparity < 0 */
}
}
}