aboutsummaryrefslogtreecommitdiff
path: root/ML_WaveToyFO/src/WTFO_RHS.cc
diff options
context:
space:
mode:
authorBarry Wardell <barry.wardell@gmail.com>2012-04-27 12:33:29 +0100
committerBarry Wardell <barry.wardell@gmail.com>2012-04-27 12:33:29 +0100
commitf87a82b998a429bcc88c928a06e175b633a916cc (patch)
treeffdd463b2a492151c0de29503589c9159acdf442 /ML_WaveToyFO/src/WTFO_RHS.cc
parente574bf527f6e15bc0df239404df428caae93d797 (diff)
Regenerate thorns.
Diffstat (limited to 'ML_WaveToyFO/src/WTFO_RHS.cc')
-rw-r--r--ML_WaveToyFO/src/WTFO_RHS.cc22
1 files changed, 13 insertions, 9 deletions
diff --git a/ML_WaveToyFO/src/WTFO_RHS.cc b/ML_WaveToyFO/src/WTFO_RHS.cc
index fb9af18..d197632 100644
--- a/ML_WaveToyFO/src/WTFO_RHS.cc
+++ b/ML_WaveToyFO/src/WTFO_RHS.cc
@@ -12,6 +12,7 @@
#include "cctk_Parameters.h"
#include "GenericFD.h"
#include "Differencing.h"
+#include "cctk_Loop.h"
#include "loopcontrol.h"
/* Define macros used in calculations */
@@ -45,8 +46,6 @@ static void WTFO_RHS_Body(cGH const * restrict const cctkGH, int const dir, int
DECLARE_CCTK_PARAMETERS;
- /* Declare finite differencing variables */
-
/* Include user-supplied include files */
/* Initialise finite differencing variables */
@@ -77,9 +76,9 @@ static void WTFO_RHS_Body(cGH const * restrict const cctkGH, int const dir, int
CCTK_REAL const p1o12dx = 0.0833333333333333333333333333333*INV(dx);
CCTK_REAL const p1o12dy = 0.0833333333333333333333333333333*INV(dy);
CCTK_REAL const p1o12dz = 0.0833333333333333333333333333333*INV(dz);
- CCTK_REAL const p1o144dxdy = 0.00694444444444444444444444444444*INV(dx)*INV(dy);
- CCTK_REAL const p1o144dxdz = 0.00694444444444444444444444444444*INV(dx)*INV(dz);
- CCTK_REAL const p1o144dydz = 0.00694444444444444444444444444444*INV(dy)*INV(dz);
+ CCTK_REAL const p1o144dxdy = 0.00694444444444444444444444444444*INV(dx*dy);
+ CCTK_REAL const p1o144dxdz = 0.00694444444444444444444444444444*INV(dx*dz);
+ CCTK_REAL const p1o144dydz = 0.00694444444444444444444444444444*INV(dy*dz);
CCTK_REAL const pm1o12dx2 = -0.0833333333333333333333333333333*INV(SQR(dx));
CCTK_REAL const pm1o12dy2 = -0.0833333333333333333333333333333*INV(SQR(dy));
CCTK_REAL const pm1o12dz2 = -0.0833333333333333333333333333333*INV(SQR(dz));
@@ -94,7 +93,7 @@ static void WTFO_RHS_Body(cGH const * restrict const cctkGH, int const dir, int
/* Loop over the grid points */
#pragma omp parallel
- LC_LOOP3 (WTFO_RHS,
+ CCTK_LOOP3(WTFO_RHS,
i,j,k, imin[0],imin[1],imin[2], imax[0],imax[1],imax[2],
cctk_lsh[0],cctk_lsh[1],cctk_lsh[2])
{
@@ -137,7 +136,7 @@ static void WTFO_RHS_Body(cGH const * restrict const cctkGH, int const dir, int
v2rhs[index] = v2rhsL;
v3rhs[index] = v3rhsL;
}
- LC_ENDLOOP3 (WTFO_RHS);
+ CCTK_ENDLOOP3(WTFO_RHS);
}
extern "C" void WTFO_RHS(CCTK_ARGUMENTS)
@@ -156,12 +155,17 @@ extern "C" void WTFO_RHS(CCTK_ARGUMENTS)
return;
}
- const char *groups[] = {"ML_WaveToyFO::WT_rho","ML_WaveToyFO::WT_rhorhs","ML_WaveToyFO::WT_urhs","ML_WaveToyFO::WT_v","ML_WaveToyFO::WT_vrhs"};
+ const char *const groups[] = {
+ "ML_WaveToyFO::WT_rho",
+ "ML_WaveToyFO::WT_rhorhs",
+ "ML_WaveToyFO::WT_urhs",
+ "ML_WaveToyFO::WT_v",
+ "ML_WaveToyFO::WT_vrhs"};
GenericFD_AssertGroupStorage(cctkGH, "WTFO_RHS", 5, groups);
GenericFD_EnsureStencilFits(cctkGH, "WTFO_RHS", 2, 2, 2);
- GenericFD_LoopOverInterior(cctkGH, &WTFO_RHS_Body);
+ GenericFD_LoopOverInterior(cctkGH, WTFO_RHS_Body);
if (verbose > 1)
{