diff options
author | schnetter <schnetter@850bcc8b-0e4f-0410-8c26-8d28fbf1eda9> | 2005-03-22 15:17:07 +0000 |
---|---|---|
committer | schnetter <schnetter@850bcc8b-0e4f-0410-8c26-8d28fbf1eda9> | 2005-03-22 15:17:07 +0000 |
commit | b3267c3188ef8be05d13a33e215b42277ccaf56b (patch) | |
tree | f70c13d0b4938b7d8114477ecfd762bb4218554c | |
parent | 7e72d1c33bc8aeed446ce1a0247189f9e53773b9 (diff) |
Correct checks for whether there are enough ghost zones
git-svn-id: http://svn.cactuscode.org/arrangements/CactusNumerical/Dissipation/trunk@7 850bcc8b-0e4f-0410-8c26-8d28fbf1eda9
-rw-r--r-- | src/dissipation.c | 2 | ||||
-rw-r--r-- | src/paramcheck.c | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/dissipation.c b/src/dissipation.c index 44a8eb2..6191cc0 100644 --- a/src/dissipation.c +++ b/src/dissipation.c @@ -49,7 +49,7 @@ apply (int const varindex, char const * const optstring, void * const arg) assert (varindex >= 0); for (d=0; d<cctk_dim; ++d) { - if (cctk_nghostzones[d] < order/2) { + if (cctk_nghostzones[d] < (order+1)/2) { CCTK_WARN (0, "This thorn requires at least order/2 ghost zones"); } } diff --git a/src/paramcheck.c b/src/paramcheck.c index 47d541a..e2ccc0d 100644 --- a/src/paramcheck.c +++ b/src/paramcheck.c @@ -15,8 +15,8 @@ void dissipation_paramcheck (CCTK_ARGUMENTS) } for (d=0; d<cctk_dim; ++d) { - if (cctk_nghostzones[d] < order/2) { - CCTK_PARAMWARN ("This thorn requires at least order/2 ghost zones"); + if (cctk_nghostzones[d] < (order+1)/2) { + CCTK_PARAMWARN ("This thorn requires at least (order+1)/2 ghost zones"); } } } |