diff options
Diffstat (limited to 'src/Ricci.c')
-rw-r--r-- | src/Ricci.c | 45 |
1 files changed, 22 insertions, 23 deletions
diff --git a/src/Ricci.c b/src/Ricci.c index e311ce5..74b11a9 100644 --- a/src/Ricci.c +++ b/src/Ricci.c @@ -10,9 +10,7 @@ @@*/ #include "cctk.h" - #include "cctk_Arguments.h" -#include "cctk_Parameters.h" #include "ADMAnalysis.h" @@ -68,17 +66,16 @@ void ADMAnalysis_Ricci(CCTK_ARGUMENTS) { DECLARE_CCTK_ARGUMENTS; - DECLARE_CCTK_PARAMETERS; - CCTK_INT i,j,k, ijk, di, dj, dk; + CCTK_INT i,j,k, ijk, di, dj, dk, err, sw[3]; #include "CactusEinstein/ADMMacros/src/macro/RICCI_declare.h" - for (k = 0; k < cctk_lsh[2]; k++) + for (k = 1; k < cctk_lsh[2]-1; k++) { - for (j = 0; j < cctk_lsh[1]; j++) + for (j = 1; j < cctk_lsh[1]-1; j++) { - for (i = 0; i < cctk_lsh[0]; i++) + for (i = 1; i < cctk_lsh[0]-1; i++) { ijk = CCTK_GFINDEX3D(cctkGH,i,j,k); @@ -101,6 +98,24 @@ void ADMAnalysis_Ricci(CCTK_ARGUMENTS) #include "CactusEinstein/ADMMacros/src/macro/RICCI_undefine.h" + /* Execute Symmetry Conditions */ + CartSymGN(cctkGH,"ADMAnalysis::ricci_scalar"); + CartSymGN(cctkGH,"ADMAnalysis::ricci_tensor"); + + /* Apply Flat Boundary Condition */ + sw[0] = 1; sw[1] = 1; sw[2] = 1; + err = BndFlatGN(cctkGH,sw,"ADMAnalysis::ricci_scalar"); + err = BndFlatGN(cctkGH,sw,"ADMAnalysis::ricci_tensor"); + if (err < 0) + { + CCTK_WARN(2,"Error in applying flat boundary condition to Ricci tensor"); + } + + /* WARNING: Only flat boundary conditions are used here. If the + * value of the Ricci tensor is going to be used for something other + * than output, then the boundaries should be handled more properly. + */ + ADMAnalysis_Trace(cctk_lsh, gxx, gxy, gxz, gyy, gyz, gzz, Ricci11, Ricci12, Ricci13, Ricci22, Ricci23, Ricci33, Ricci, detg); @@ -112,19 +127,3 @@ void ADMAnalysis_Ricci(CCTK_ARGUMENTS) /******************************************************************** ********************* Local Routines ************************* ********************************************************************/ - - - - - - - - - - - - - - - - |