diff options
Diffstat (limited to 'ML_BSSN/src/ML_BSSN_constraints1.cc')
-rw-r--r-- | ML_BSSN/src/ML_BSSN_constraints1.cc | 248 |
1 files changed, 126 insertions, 122 deletions
diff --git a/ML_BSSN/src/ML_BSSN_constraints1.cc b/ML_BSSN/src/ML_BSSN_constraints1.cc index ee512c8..6b53b52 100644 --- a/ML_BSSN/src/ML_BSSN_constraints1.cc +++ b/ML_BSSN/src/ML_BSSN_constraints1.cc @@ -18,10 +18,14 @@ /* Define macros used in calculations */ #define INITVALUE (42) -#define QAD(x) (SQR(SQR(x))) +#define ScalarINV(x) ((CCTK_REAL)1.0 / (x)) +#define ScalarSQR(x) ((x) * (x)) +#define ScalarCUB(x) ((x) * ScalarSQR(x)) +#define ScalarQAD(x) (ScalarSQR(ScalarSQR(x))) #define INV(x) (kdiv(ToReal(1.0),x)) #define SQR(x) (kmul(x,x)) #define CUB(x) (kmul(x,SQR(x))) +#define QAD(x) (SQR(SQR(x))) extern "C" void ML_BSSN_constraints1_SelectBCs(CCTK_ARGUMENTS) { @@ -68,84 +72,84 @@ static void ML_BSSN_constraints1_Body(cGH const * restrict const cctkGH, int con CCTK_REAL_VEC const hdzi = kmul(ToReal(0.5), dzi); /* Initialize predefined quantities */ - CCTK_REAL_VEC const p1o1024dx = kmul(INV(dx),ToReal(0.0009765625)); - CCTK_REAL_VEC const p1o1024dy = kmul(INV(dy),ToReal(0.0009765625)); - CCTK_REAL_VEC const p1o1024dz = kmul(INV(dz),ToReal(0.0009765625)); - CCTK_REAL_VEC const p1o120dx = kmul(INV(dx),ToReal(0.00833333333333333333333333333333)); - CCTK_REAL_VEC const p1o120dy = kmul(INV(dy),ToReal(0.00833333333333333333333333333333)); - CCTK_REAL_VEC const p1o120dz = kmul(INV(dz),ToReal(0.00833333333333333333333333333333)); - CCTK_REAL_VEC const p1o12dx = kmul(INV(dx),ToReal(0.0833333333333333333333333333333)); - CCTK_REAL_VEC const p1o12dy = kmul(INV(dy),ToReal(0.0833333333333333333333333333333)); - CCTK_REAL_VEC const p1o12dz = kmul(INV(dz),ToReal(0.0833333333333333333333333333333)); - CCTK_REAL_VEC const p1o144dxdy = kmul(INV(kmul(dx,dy)),ToReal(0.00694444444444444444444444444444)); - CCTK_REAL_VEC const p1o144dxdz = kmul(INV(kmul(dx,dz)),ToReal(0.00694444444444444444444444444444)); - CCTK_REAL_VEC const p1o144dydz = kmul(INV(kmul(dy,dz)),ToReal(0.00694444444444444444444444444444)); - CCTK_REAL_VEC const p1o1680dx = kmul(INV(dx),ToReal(0.000595238095238095238095238095238)); - CCTK_REAL_VEC const p1o1680dy = kmul(INV(dy),ToReal(0.000595238095238095238095238095238)); - CCTK_REAL_VEC const p1o1680dz = kmul(INV(dz),ToReal(0.000595238095238095238095238095238)); - CCTK_REAL_VEC const p1o16dx = kmul(INV(dx),ToReal(0.0625)); - CCTK_REAL_VEC const p1o16dy = kmul(INV(dy),ToReal(0.0625)); - CCTK_REAL_VEC const p1o16dz = kmul(INV(dz),ToReal(0.0625)); - CCTK_REAL_VEC const p1o180dx2 = kmul(INV(SQR(dx)),ToReal(0.00555555555555555555555555555556)); - CCTK_REAL_VEC const p1o180dy2 = kmul(INV(SQR(dy)),ToReal(0.00555555555555555555555555555556)); - CCTK_REAL_VEC const p1o180dz2 = kmul(INV(SQR(dz)),ToReal(0.00555555555555555555555555555556)); - CCTK_REAL_VEC const p1o24dx = kmul(INV(dx),ToReal(0.0416666666666666666666666666667)); - CCTK_REAL_VEC const p1o24dy = kmul(INV(dy),ToReal(0.0416666666666666666666666666667)); - CCTK_REAL_VEC const p1o24dz = kmul(INV(dz),ToReal(0.0416666666666666666666666666667)); - CCTK_REAL_VEC const p1o256dx = kmul(INV(dx),ToReal(0.00390625)); - CCTK_REAL_VEC const p1o256dy = kmul(INV(dy),ToReal(0.00390625)); - CCTK_REAL_VEC const p1o256dz = kmul(INV(dz),ToReal(0.00390625)); - CCTK_REAL_VEC const p1o2dx = kmul(INV(dx),ToReal(0.5)); - CCTK_REAL_VEC const p1o2dy = kmul(INV(dy),ToReal(0.5)); - CCTK_REAL_VEC const p1o2dz = kmul(INV(dz),ToReal(0.5)); - CCTK_REAL_VEC const p1o3600dxdy = kmul(INV(kmul(dx,dy)),ToReal(0.000277777777777777777777777777778)); - CCTK_REAL_VEC const p1o3600dxdz = kmul(INV(kmul(dx,dz)),ToReal(0.000277777777777777777777777777778)); - CCTK_REAL_VEC const p1o3600dydz = kmul(INV(kmul(dy,dz)),ToReal(0.000277777777777777777777777777778)); - CCTK_REAL_VEC const p1o4dx = kmul(INV(dx),ToReal(0.25)); - CCTK_REAL_VEC const p1o4dxdy = kmul(INV(kmul(dx,dy)),ToReal(0.25)); - CCTK_REAL_VEC const p1o4dxdz = kmul(INV(kmul(dx,dz)),ToReal(0.25)); - CCTK_REAL_VEC const p1o4dy = kmul(INV(dy),ToReal(0.25)); - CCTK_REAL_VEC const p1o4dydz = kmul(INV(kmul(dy,dz)),ToReal(0.25)); - CCTK_REAL_VEC const p1o4dz = kmul(INV(dz),ToReal(0.25)); - CCTK_REAL_VEC const p1o5040dx2 = kmul(INV(SQR(dx)),ToReal(0.000198412698412698412698412698413)); - CCTK_REAL_VEC const p1o5040dy2 = kmul(INV(SQR(dy)),ToReal(0.000198412698412698412698412698413)); - CCTK_REAL_VEC const p1o5040dz2 = kmul(INV(SQR(dz)),ToReal(0.000198412698412698412698412698413)); - CCTK_REAL_VEC const p1o560dx = kmul(INV(dx),ToReal(0.00178571428571428571428571428571)); - CCTK_REAL_VEC const p1o560dy = kmul(INV(dy),ToReal(0.00178571428571428571428571428571)); - CCTK_REAL_VEC const p1o560dz = kmul(INV(dz),ToReal(0.00178571428571428571428571428571)); - CCTK_REAL_VEC const p1o60dx = kmul(INV(dx),ToReal(0.0166666666666666666666666666667)); - CCTK_REAL_VEC const p1o60dy = kmul(INV(dy),ToReal(0.0166666666666666666666666666667)); - CCTK_REAL_VEC const p1o60dz = kmul(INV(dz),ToReal(0.0166666666666666666666666666667)); - CCTK_REAL_VEC const p1o64dx = kmul(INV(dx),ToReal(0.015625)); - CCTK_REAL_VEC const p1o64dy = kmul(INV(dy),ToReal(0.015625)); - CCTK_REAL_VEC const p1o64dz = kmul(INV(dz),ToReal(0.015625)); - CCTK_REAL_VEC const p1o705600dxdy = kmul(INV(kmul(dx,dy)),ToReal(1.41723356009070294784580498866e-6)); - CCTK_REAL_VEC const p1o705600dxdz = kmul(INV(kmul(dx,dz)),ToReal(1.41723356009070294784580498866e-6)); - CCTK_REAL_VEC const p1o705600dydz = kmul(INV(kmul(dy,dz)),ToReal(1.41723356009070294784580498866e-6)); - CCTK_REAL_VEC const p1o840dx = kmul(INV(dx),ToReal(0.00119047619047619047619047619048)); - CCTK_REAL_VEC const p1o840dy = kmul(INV(dy),ToReal(0.00119047619047619047619047619048)); - CCTK_REAL_VEC const p1o840dz = kmul(INV(dz),ToReal(0.00119047619047619047619047619048)); - CCTK_REAL_VEC const p1odx = INV(dx); - CCTK_REAL_VEC const p1odx2 = INV(SQR(dx)); - CCTK_REAL_VEC const p1ody = INV(dy); - CCTK_REAL_VEC const p1ody2 = INV(SQR(dy)); - CCTK_REAL_VEC const p1odz = INV(dz); - CCTK_REAL_VEC const p1odz2 = INV(SQR(dz)); - CCTK_REAL_VEC const pm1o120dx = kmul(INV(dx),ToReal(-0.00833333333333333333333333333333)); - CCTK_REAL_VEC const pm1o120dy = kmul(INV(dy),ToReal(-0.00833333333333333333333333333333)); - CCTK_REAL_VEC const pm1o120dz = kmul(INV(dz),ToReal(-0.00833333333333333333333333333333)); - CCTK_REAL_VEC const pm1o12dx2 = kmul(INV(SQR(dx)),ToReal(-0.0833333333333333333333333333333)); - CCTK_REAL_VEC const pm1o12dy2 = kmul(INV(SQR(dy)),ToReal(-0.0833333333333333333333333333333)); - CCTK_REAL_VEC const pm1o12dz2 = kmul(INV(SQR(dz)),ToReal(-0.0833333333333333333333333333333)); - CCTK_REAL_VEC const pm1o2dx = kmul(INV(dx),ToReal(-0.5)); - CCTK_REAL_VEC const pm1o2dy = kmul(INV(dy),ToReal(-0.5)); - CCTK_REAL_VEC const pm1o2dz = kmul(INV(dz),ToReal(-0.5)); - CCTK_REAL_VEC const pm1o4dx = kmul(INV(dx),ToReal(-0.25)); - CCTK_REAL_VEC const pm1o4dy = kmul(INV(dy),ToReal(-0.25)); - CCTK_REAL_VEC const pm1o4dz = kmul(INV(dz),ToReal(-0.25)); - CCTK_REAL_VEC const pm1o60dx = kmul(INV(dx),ToReal(-0.0166666666666666666666666666667)); - CCTK_REAL_VEC const pm1o60dy = kmul(INV(dy),ToReal(-0.0166666666666666666666666666667)); - CCTK_REAL_VEC const pm1o60dz = kmul(INV(dz),ToReal(-0.0166666666666666666666666666667)); + CCTK_REAL_VEC const p1o1024dx = kdiv(ToReal(0.0009765625),dx); + CCTK_REAL_VEC const p1o1024dy = kdiv(ToReal(0.0009765625),dy); + CCTK_REAL_VEC const p1o1024dz = kdiv(ToReal(0.0009765625),dz); + CCTK_REAL_VEC const p1o120dx = kdiv(ToReal(0.00833333333333333333333333333333),dx); + CCTK_REAL_VEC const p1o120dy = kdiv(ToReal(0.00833333333333333333333333333333),dy); + CCTK_REAL_VEC const p1o120dz = kdiv(ToReal(0.00833333333333333333333333333333),dz); + CCTK_REAL_VEC const p1o12dx = kdiv(ToReal(0.0833333333333333333333333333333),dx); + CCTK_REAL_VEC const p1o12dy = kdiv(ToReal(0.0833333333333333333333333333333),dy); + CCTK_REAL_VEC const p1o12dz = kdiv(ToReal(0.0833333333333333333333333333333),dz); + CCTK_REAL_VEC const p1o144dxdy = kdiv(ToReal(0.00694444444444444444444444444444),kmul(dy,dx)); + CCTK_REAL_VEC const p1o144dxdz = kdiv(ToReal(0.00694444444444444444444444444444),kmul(dz,dx)); + CCTK_REAL_VEC const p1o144dydz = kdiv(ToReal(0.00694444444444444444444444444444),kmul(dz,dy)); + CCTK_REAL_VEC const p1o1680dx = kdiv(ToReal(0.000595238095238095238095238095238),dx); + CCTK_REAL_VEC const p1o1680dy = kdiv(ToReal(0.000595238095238095238095238095238),dy); + CCTK_REAL_VEC const p1o1680dz = kdiv(ToReal(0.000595238095238095238095238095238),dz); + CCTK_REAL_VEC const p1o16dx = kdiv(ToReal(0.0625),dx); + CCTK_REAL_VEC const p1o16dy = kdiv(ToReal(0.0625),dy); + CCTK_REAL_VEC const p1o16dz = kdiv(ToReal(0.0625),dz); + CCTK_REAL_VEC const p1o180dx2 = kdiv(ToReal(0.00555555555555555555555555555556),kmul(dx,dx)); + CCTK_REAL_VEC const p1o180dy2 = kdiv(ToReal(0.00555555555555555555555555555556),kmul(dy,dy)); + CCTK_REAL_VEC const p1o180dz2 = kdiv(ToReal(0.00555555555555555555555555555556),kmul(dz,dz)); + CCTK_REAL_VEC const p1o24dx = kdiv(ToReal(0.0416666666666666666666666666667),dx); + CCTK_REAL_VEC const p1o24dy = kdiv(ToReal(0.0416666666666666666666666666667),dy); + CCTK_REAL_VEC const p1o24dz = kdiv(ToReal(0.0416666666666666666666666666667),dz); + CCTK_REAL_VEC const p1o256dx = kdiv(ToReal(0.00390625),dx); + CCTK_REAL_VEC const p1o256dy = kdiv(ToReal(0.00390625),dy); + CCTK_REAL_VEC const p1o256dz = kdiv(ToReal(0.00390625),dz); + CCTK_REAL_VEC const p1o2dx = kdiv(ToReal(0.5),dx); + CCTK_REAL_VEC const p1o2dy = kdiv(ToReal(0.5),dy); + CCTK_REAL_VEC const p1o2dz = kdiv(ToReal(0.5),dz); + CCTK_REAL_VEC const p1o3600dxdy = kdiv(ToReal(0.000277777777777777777777777777778),kmul(dy,dx)); + CCTK_REAL_VEC const p1o3600dxdz = kdiv(ToReal(0.000277777777777777777777777777778),kmul(dz,dx)); + CCTK_REAL_VEC const p1o3600dydz = kdiv(ToReal(0.000277777777777777777777777777778),kmul(dz,dy)); + CCTK_REAL_VEC const p1o4dx = kdiv(ToReal(0.25),dx); + CCTK_REAL_VEC const p1o4dxdy = kdiv(ToReal(0.25),kmul(dy,dx)); + CCTK_REAL_VEC const p1o4dxdz = kdiv(ToReal(0.25),kmul(dz,dx)); + CCTK_REAL_VEC const p1o4dy = kdiv(ToReal(0.25),dy); + CCTK_REAL_VEC const p1o4dydz = kdiv(ToReal(0.25),kmul(dz,dy)); + CCTK_REAL_VEC const p1o4dz = kdiv(ToReal(0.25),dz); + CCTK_REAL_VEC const p1o5040dx2 = kdiv(ToReal(0.000198412698412698412698412698413),kmul(dx,dx)); + CCTK_REAL_VEC const p1o5040dy2 = kdiv(ToReal(0.000198412698412698412698412698413),kmul(dy,dy)); + CCTK_REAL_VEC const p1o5040dz2 = kdiv(ToReal(0.000198412698412698412698412698413),kmul(dz,dz)); + CCTK_REAL_VEC const p1o560dx = kdiv(ToReal(0.00178571428571428571428571428571),dx); + CCTK_REAL_VEC const p1o560dy = kdiv(ToReal(0.00178571428571428571428571428571),dy); + CCTK_REAL_VEC const p1o560dz = kdiv(ToReal(0.00178571428571428571428571428571),dz); + CCTK_REAL_VEC const p1o60dx = kdiv(ToReal(0.0166666666666666666666666666667),dx); + CCTK_REAL_VEC const p1o60dy = kdiv(ToReal(0.0166666666666666666666666666667),dy); + CCTK_REAL_VEC const p1o60dz = kdiv(ToReal(0.0166666666666666666666666666667),dz); + CCTK_REAL_VEC const p1o64dx = kdiv(ToReal(0.015625),dx); + CCTK_REAL_VEC const p1o64dy = kdiv(ToReal(0.015625),dy); + CCTK_REAL_VEC const p1o64dz = kdiv(ToReal(0.015625),dz); + CCTK_REAL_VEC const p1o705600dxdy = kdiv(ToReal(1.41723356009070294784580498866e-6),kmul(dy,dx)); + CCTK_REAL_VEC const p1o705600dxdz = kdiv(ToReal(1.41723356009070294784580498866e-6),kmul(dz,dx)); + CCTK_REAL_VEC const p1o705600dydz = kdiv(ToReal(1.41723356009070294784580498866e-6),kmul(dz,dy)); + CCTK_REAL_VEC const p1o840dx = kdiv(ToReal(0.00119047619047619047619047619048),dx); + CCTK_REAL_VEC const p1o840dy = kdiv(ToReal(0.00119047619047619047619047619048),dy); + CCTK_REAL_VEC const p1o840dz = kdiv(ToReal(0.00119047619047619047619047619048),dz); + CCTK_REAL_VEC const p1odx = kdiv(ToReal(1),dx); + CCTK_REAL_VEC const p1odx2 = kdiv(ToReal(1),kmul(dx,dx)); + CCTK_REAL_VEC const p1ody = kdiv(ToReal(1),dy); + CCTK_REAL_VEC const p1ody2 = kdiv(ToReal(1),kmul(dy,dy)); + CCTK_REAL_VEC const p1odz = kdiv(ToReal(1),dz); + CCTK_REAL_VEC const p1odz2 = kdiv(ToReal(1),kmul(dz,dz)); + CCTK_REAL_VEC const pm1o120dx = kdiv(ToReal(-0.00833333333333333333333333333333),dx); + CCTK_REAL_VEC const pm1o120dy = kdiv(ToReal(-0.00833333333333333333333333333333),dy); + CCTK_REAL_VEC const pm1o120dz = kdiv(ToReal(-0.00833333333333333333333333333333),dz); + CCTK_REAL_VEC const pm1o12dx2 = kdiv(ToReal(-0.0833333333333333333333333333333),kmul(dx,dx)); + CCTK_REAL_VEC const pm1o12dy2 = kdiv(ToReal(-0.0833333333333333333333333333333),kmul(dy,dy)); + CCTK_REAL_VEC const pm1o12dz2 = kdiv(ToReal(-0.0833333333333333333333333333333),kmul(dz,dz)); + CCTK_REAL_VEC const pm1o2dx = kdiv(ToReal(-0.5),dx); + CCTK_REAL_VEC const pm1o2dy = kdiv(ToReal(-0.5),dy); + CCTK_REAL_VEC const pm1o2dz = kdiv(ToReal(-0.5),dz); + CCTK_REAL_VEC const pm1o4dx = kdiv(ToReal(-0.25),dx); + CCTK_REAL_VEC const pm1o4dy = kdiv(ToReal(-0.25),dy); + CCTK_REAL_VEC const pm1o4dz = kdiv(ToReal(-0.25),dz); + CCTK_REAL_VEC const pm1o60dx = kdiv(ToReal(-0.0166666666666666666666666666667),dx); + CCTK_REAL_VEC const pm1o60dy = kdiv(ToReal(-0.0166666666666666666666666666667),dy); + CCTK_REAL_VEC const pm1o60dz = kdiv(ToReal(-0.0166666666666666666666666666667),dz); /* Jacobian variable pointers */ bool const use_jacobian = (!CCTK_IsFunctionAliased("MultiPatch_GetMap") || MultiPatch_GetMap(cctkGH) != jacobian_identity_map) @@ -204,7 +208,7 @@ static void ML_BSSN_constraints1_Body(cGH const * restrict const cctkGH, int con #pragma omp parallel LC_LOOP3VEC(ML_BSSN_constraints1, i,j,k, imin[0],imin[1],imin[2], imax[0],imax[1],imax[2], - cctk_lsh[0],cctk_lsh[1],cctk_lsh[2], + cctk_ash[0],cctk_ash[1],cctk_ash[2], CCTK_REAL_VEC_SIZE) { ptrdiff_t const index = di*i + dj*j + dk*k; @@ -859,67 +863,67 @@ static void ML_BSSN_constraints1_Body(cGH const * restrict const cctkGH, int con kmadd(J13L,PDstandardNth1Xt3,kmadd(J23L,PDstandardNth2Xt3,kmul(J33L,PDstandardNth3Xt3))); JacPDstandardNth11gt11 = - kmadd(dJ111L,PDstandardNth1gt11,kmadd(dJ211L,PDstandardNth2gt11,kmadd(dJ311L,PDstandardNth3gt11,kmadd(PDstandardNth11gt11,SQR(J11L),kmadd(PDstandardNth22gt11,SQR(J21L),kmadd(PDstandardNth33gt11,SQR(J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12gt11,kmul(J31L,PDstandardNth13gt11)),kmul(J21L,kmul(J31L,PDstandardNth23gt11))),ToReal(2)))))))); + kmadd(dJ111L,PDstandardNth1gt11,kmadd(dJ211L,PDstandardNth2gt11,kmadd(dJ311L,PDstandardNth3gt11,kmadd(PDstandardNth11gt11,kmul(J11L,J11L),kmadd(PDstandardNth22gt11,kmul(J21L,J21L),kmadd(PDstandardNth33gt11,kmul(J31L,J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12gt11,kmul(J31L,PDstandardNth13gt11)),kmul(J21L,kmul(J31L,PDstandardNth23gt11))),ToReal(2)))))))); JacPDstandardNth11gt12 = - kmadd(dJ111L,PDstandardNth1gt12,kmadd(dJ211L,PDstandardNth2gt12,kmadd(dJ311L,PDstandardNth3gt12,kmadd(PDstandardNth11gt12,SQR(J11L),kmadd(PDstandardNth22gt12,SQR(J21L),kmadd(PDstandardNth33gt12,SQR(J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12gt12,kmul(J31L,PDstandardNth13gt12)),kmul(J21L,kmul(J31L,PDstandardNth23gt12))),ToReal(2)))))))); + kmadd(dJ111L,PDstandardNth1gt12,kmadd(dJ211L,PDstandardNth2gt12,kmadd(dJ311L,PDstandardNth3gt12,kmadd(PDstandardNth11gt12,kmul(J11L,J11L),kmadd(PDstandardNth22gt12,kmul(J21L,J21L),kmadd(PDstandardNth33gt12,kmul(J31L,J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12gt12,kmul(J31L,PDstandardNth13gt12)),kmul(J21L,kmul(J31L,PDstandardNth23gt12))),ToReal(2)))))))); JacPDstandardNth11gt13 = - kmadd(dJ111L,PDstandardNth1gt13,kmadd(dJ211L,PDstandardNth2gt13,kmadd(dJ311L,PDstandardNth3gt13,kmadd(PDstandardNth11gt13,SQR(J11L),kmadd(PDstandardNth22gt13,SQR(J21L),kmadd(PDstandardNth33gt13,SQR(J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12gt13,kmul(J31L,PDstandardNth13gt13)),kmul(J21L,kmul(J31L,PDstandardNth23gt13))),ToReal(2)))))))); + kmadd(dJ111L,PDstandardNth1gt13,kmadd(dJ211L,PDstandardNth2gt13,kmadd(dJ311L,PDstandardNth3gt13,kmadd(PDstandardNth11gt13,kmul(J11L,J11L),kmadd(PDstandardNth22gt13,kmul(J21L,J21L),kmadd(PDstandardNth33gt13,kmul(J31L,J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12gt13,kmul(J31L,PDstandardNth13gt13)),kmul(J21L,kmul(J31L,PDstandardNth23gt13))),ToReal(2)))))))); JacPDstandardNth11gt22 = - kmadd(dJ111L,PDstandardNth1gt22,kmadd(dJ211L,PDstandardNth2gt22,kmadd(dJ311L,PDstandardNth3gt22,kmadd(PDstandardNth11gt22,SQR(J11L),kmadd(PDstandardNth22gt22,SQR(J21L),kmadd(PDstandardNth33gt22,SQR(J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12gt22,kmul(J31L,PDstandardNth13gt22)),kmul(J21L,kmul(J31L,PDstandardNth23gt22))),ToReal(2)))))))); + kmadd(dJ111L,PDstandardNth1gt22,kmadd(dJ211L,PDstandardNth2gt22,kmadd(dJ311L,PDstandardNth3gt22,kmadd(PDstandardNth11gt22,kmul(J11L,J11L),kmadd(PDstandardNth22gt22,kmul(J21L,J21L),kmadd(PDstandardNth33gt22,kmul(J31L,J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12gt22,kmul(J31L,PDstandardNth13gt22)),kmul(J21L,kmul(J31L,PDstandardNth23gt22))),ToReal(2)))))))); JacPDstandardNth11gt23 = - kmadd(dJ111L,PDstandardNth1gt23,kmadd(dJ211L,PDstandardNth2gt23,kmadd(dJ311L,PDstandardNth3gt23,kmadd(PDstandardNth11gt23,SQR(J11L),kmadd(PDstandardNth22gt23,SQR(J21L),kmadd(PDstandardNth33gt23,SQR(J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12gt23,kmul(J31L,PDstandardNth13gt23)),kmul(J21L,kmul(J31L,PDstandardNth23gt23))),ToReal(2)))))))); + kmadd(dJ111L,PDstandardNth1gt23,kmadd(dJ211L,PDstandardNth2gt23,kmadd(dJ311L,PDstandardNth3gt23,kmadd(PDstandardNth11gt23,kmul(J11L,J11L),kmadd(PDstandardNth22gt23,kmul(J21L,J21L),kmadd(PDstandardNth33gt23,kmul(J31L,J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12gt23,kmul(J31L,PDstandardNth13gt23)),kmul(J21L,kmul(J31L,PDstandardNth23gt23))),ToReal(2)))))))); JacPDstandardNth11gt33 = - kmadd(dJ111L,PDstandardNth1gt33,kmadd(dJ211L,PDstandardNth2gt33,kmadd(dJ311L,PDstandardNth3gt33,kmadd(PDstandardNth11gt33,SQR(J11L),kmadd(PDstandardNth22gt33,SQR(J21L),kmadd(PDstandardNth33gt33,SQR(J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12gt33,kmul(J31L,PDstandardNth13gt33)),kmul(J21L,kmul(J31L,PDstandardNth23gt33))),ToReal(2)))))))); + kmadd(dJ111L,PDstandardNth1gt33,kmadd(dJ211L,PDstandardNth2gt33,kmadd(dJ311L,PDstandardNth3gt33,kmadd(PDstandardNth11gt33,kmul(J11L,J11L),kmadd(PDstandardNth22gt33,kmul(J21L,J21L),kmadd(PDstandardNth33gt33,kmul(J31L,J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12gt33,kmul(J31L,PDstandardNth13gt33)),kmul(J21L,kmul(J31L,PDstandardNth23gt33))),ToReal(2)))))))); JacPDstandardNth11phi = - kmadd(dJ111L,PDstandardNth1phi,kmadd(dJ211L,PDstandardNth2phi,kmadd(dJ311L,PDstandardNth3phi,kmadd(PDstandardNth11phi,SQR(J11L),kmadd(PDstandardNth22phi,SQR(J21L),kmadd(PDstandardNth33phi,SQR(J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12phi,kmul(J31L,PDstandardNth13phi)),kmul(J21L,kmul(J31L,PDstandardNth23phi))),ToReal(2)))))))); + kmadd(dJ111L,PDstandardNth1phi,kmadd(dJ211L,PDstandardNth2phi,kmadd(dJ311L,PDstandardNth3phi,kmadd(PDstandardNth11phi,kmul(J11L,J11L),kmadd(PDstandardNth22phi,kmul(J21L,J21L),kmadd(PDstandardNth33phi,kmul(J31L,J31L),kmul(kmadd(J11L,kmadd(J21L,PDstandardNth12phi,kmul(J31L,PDstandardNth13phi)),kmul(J21L,kmul(J31L,PDstandardNth23phi))),ToReal(2)))))))); JacPDstandardNth22gt11 = - kmadd(dJ122L,PDstandardNth1gt11,kmadd(dJ222L,PDstandardNth2gt11,kmadd(dJ322L,PDstandardNth3gt11,kmadd(PDstandardNth11gt11,SQR(J12L),kmadd(PDstandardNth22gt11,SQR(J22L),kmadd(PDstandardNth33gt11,SQR(J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12gt11,kmul(J32L,PDstandardNth13gt11)),kmul(J22L,kmul(J32L,PDstandardNth23gt11))),ToReal(2)))))))); + kmadd(dJ122L,PDstandardNth1gt11,kmadd(dJ222L,PDstandardNth2gt11,kmadd(dJ322L,PDstandardNth3gt11,kmadd(PDstandardNth11gt11,kmul(J12L,J12L),kmadd(PDstandardNth22gt11,kmul(J22L,J22L),kmadd(PDstandardNth33gt11,kmul(J32L,J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12gt11,kmul(J32L,PDstandardNth13gt11)),kmul(J22L,kmul(J32L,PDstandardNth23gt11))),ToReal(2)))))))); JacPDstandardNth22gt12 = - kmadd(dJ122L,PDstandardNth1gt12,kmadd(dJ222L,PDstandardNth2gt12,kmadd(dJ322L,PDstandardNth3gt12,kmadd(PDstandardNth11gt12,SQR(J12L),kmadd(PDstandardNth22gt12,SQR(J22L),kmadd(PDstandardNth33gt12,SQR(J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12gt12,kmul(J32L,PDstandardNth13gt12)),kmul(J22L,kmul(J32L,PDstandardNth23gt12))),ToReal(2)))))))); + kmadd(dJ122L,PDstandardNth1gt12,kmadd(dJ222L,PDstandardNth2gt12,kmadd(dJ322L,PDstandardNth3gt12,kmadd(PDstandardNth11gt12,kmul(J12L,J12L),kmadd(PDstandardNth22gt12,kmul(J22L,J22L),kmadd(PDstandardNth33gt12,kmul(J32L,J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12gt12,kmul(J32L,PDstandardNth13gt12)),kmul(J22L,kmul(J32L,PDstandardNth23gt12))),ToReal(2)))))))); JacPDstandardNth22gt13 = - kmadd(dJ122L,PDstandardNth1gt13,kmadd(dJ222L,PDstandardNth2gt13,kmadd(dJ322L,PDstandardNth3gt13,kmadd(PDstandardNth11gt13,SQR(J12L),kmadd(PDstandardNth22gt13,SQR(J22L),kmadd(PDstandardNth33gt13,SQR(J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12gt13,kmul(J32L,PDstandardNth13gt13)),kmul(J22L,kmul(J32L,PDstandardNth23gt13))),ToReal(2)))))))); + kmadd(dJ122L,PDstandardNth1gt13,kmadd(dJ222L,PDstandardNth2gt13,kmadd(dJ322L,PDstandardNth3gt13,kmadd(PDstandardNth11gt13,kmul(J12L,J12L),kmadd(PDstandardNth22gt13,kmul(J22L,J22L),kmadd(PDstandardNth33gt13,kmul(J32L,J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12gt13,kmul(J32L,PDstandardNth13gt13)),kmul(J22L,kmul(J32L,PDstandardNth23gt13))),ToReal(2)))))))); JacPDstandardNth22gt22 = - kmadd(dJ122L,PDstandardNth1gt22,kmadd(dJ222L,PDstandardNth2gt22,kmadd(dJ322L,PDstandardNth3gt22,kmadd(PDstandardNth11gt22,SQR(J12L),kmadd(PDstandardNth22gt22,SQR(J22L),kmadd(PDstandardNth33gt22,SQR(J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12gt22,kmul(J32L,PDstandardNth13gt22)),kmul(J22L,kmul(J32L,PDstandardNth23gt22))),ToReal(2)))))))); + kmadd(dJ122L,PDstandardNth1gt22,kmadd(dJ222L,PDstandardNth2gt22,kmadd(dJ322L,PDstandardNth3gt22,kmadd(PDstandardNth11gt22,kmul(J12L,J12L),kmadd(PDstandardNth22gt22,kmul(J22L,J22L),kmadd(PDstandardNth33gt22,kmul(J32L,J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12gt22,kmul(J32L,PDstandardNth13gt22)),kmul(J22L,kmul(J32L,PDstandardNth23gt22))),ToReal(2)))))))); JacPDstandardNth22gt23 = - kmadd(dJ122L,PDstandardNth1gt23,kmadd(dJ222L,PDstandardNth2gt23,kmadd(dJ322L,PDstandardNth3gt23,kmadd(PDstandardNth11gt23,SQR(J12L),kmadd(PDstandardNth22gt23,SQR(J22L),kmadd(PDstandardNth33gt23,SQR(J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12gt23,kmul(J32L,PDstandardNth13gt23)),kmul(J22L,kmul(J32L,PDstandardNth23gt23))),ToReal(2)))))))); + kmadd(dJ122L,PDstandardNth1gt23,kmadd(dJ222L,PDstandardNth2gt23,kmadd(dJ322L,PDstandardNth3gt23,kmadd(PDstandardNth11gt23,kmul(J12L,J12L),kmadd(PDstandardNth22gt23,kmul(J22L,J22L),kmadd(PDstandardNth33gt23,kmul(J32L,J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12gt23,kmul(J32L,PDstandardNth13gt23)),kmul(J22L,kmul(J32L,PDstandardNth23gt23))),ToReal(2)))))))); JacPDstandardNth22gt33 = - kmadd(dJ122L,PDstandardNth1gt33,kmadd(dJ222L,PDstandardNth2gt33,kmadd(dJ322L,PDstandardNth3gt33,kmadd(PDstandardNth11gt33,SQR(J12L),kmadd(PDstandardNth22gt33,SQR(J22L),kmadd(PDstandardNth33gt33,SQR(J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12gt33,kmul(J32L,PDstandardNth13gt33)),kmul(J22L,kmul(J32L,PDstandardNth23gt33))),ToReal(2)))))))); + kmadd(dJ122L,PDstandardNth1gt33,kmadd(dJ222L,PDstandardNth2gt33,kmadd(dJ322L,PDstandardNth3gt33,kmadd(PDstandardNth11gt33,kmul(J12L,J12L),kmadd(PDstandardNth22gt33,kmul(J22L,J22L),kmadd(PDstandardNth33gt33,kmul(J32L,J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12gt33,kmul(J32L,PDstandardNth13gt33)),kmul(J22L,kmul(J32L,PDstandardNth23gt33))),ToReal(2)))))))); JacPDstandardNth22phi = - kmadd(dJ122L,PDstandardNth1phi,kmadd(dJ222L,PDstandardNth2phi,kmadd(dJ322L,PDstandardNth3phi,kmadd(PDstandardNth11phi,SQR(J12L),kmadd(PDstandardNth22phi,SQR(J22L),kmadd(PDstandardNth33phi,SQR(J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12phi,kmul(J32L,PDstandardNth13phi)),kmul(J22L,kmul(J32L,PDstandardNth23phi))),ToReal(2)))))))); + kmadd(dJ122L,PDstandardNth1phi,kmadd(dJ222L,PDstandardNth2phi,kmadd(dJ322L,PDstandardNth3phi,kmadd(PDstandardNth11phi,kmul(J12L,J12L),kmadd(PDstandardNth22phi,kmul(J22L,J22L),kmadd(PDstandardNth33phi,kmul(J32L,J32L),kmul(kmadd(J12L,kmadd(J22L,PDstandardNth12phi,kmul(J32L,PDstandardNth13phi)),kmul(J22L,kmul(J32L,PDstandardNth23phi))),ToReal(2)))))))); JacPDstandardNth33gt11 = - kmadd(dJ133L,PDstandardNth1gt11,kmadd(dJ233L,PDstandardNth2gt11,kmadd(dJ333L,PDstandardNth3gt11,kmadd(PDstandardNth11gt11,SQR(J13L),kmadd(PDstandardNth22gt11,SQR(J23L),kmadd(PDstandardNth33gt11,SQR(J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12gt11,kmul(J33L,PDstandardNth13gt11)),kmul(J23L,kmul(J33L,PDstandardNth23gt11))),ToReal(2)))))))); + kmadd(dJ133L,PDstandardNth1gt11,kmadd(dJ233L,PDstandardNth2gt11,kmadd(dJ333L,PDstandardNth3gt11,kmadd(PDstandardNth11gt11,kmul(J13L,J13L),kmadd(PDstandardNth22gt11,kmul(J23L,J23L),kmadd(PDstandardNth33gt11,kmul(J33L,J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12gt11,kmul(J33L,PDstandardNth13gt11)),kmul(J23L,kmul(J33L,PDstandardNth23gt11))),ToReal(2)))))))); JacPDstandardNth33gt12 = - kmadd(dJ133L,PDstandardNth1gt12,kmadd(dJ233L,PDstandardNth2gt12,kmadd(dJ333L,PDstandardNth3gt12,kmadd(PDstandardNth11gt12,SQR(J13L),kmadd(PDstandardNth22gt12,SQR(J23L),kmadd(PDstandardNth33gt12,SQR(J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12gt12,kmul(J33L,PDstandardNth13gt12)),kmul(J23L,kmul(J33L,PDstandardNth23gt12))),ToReal(2)))))))); + kmadd(dJ133L,PDstandardNth1gt12,kmadd(dJ233L,PDstandardNth2gt12,kmadd(dJ333L,PDstandardNth3gt12,kmadd(PDstandardNth11gt12,kmul(J13L,J13L),kmadd(PDstandardNth22gt12,kmul(J23L,J23L),kmadd(PDstandardNth33gt12,kmul(J33L,J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12gt12,kmul(J33L,PDstandardNth13gt12)),kmul(J23L,kmul(J33L,PDstandardNth23gt12))),ToReal(2)))))))); JacPDstandardNth33gt13 = - kmadd(dJ133L,PDstandardNth1gt13,kmadd(dJ233L,PDstandardNth2gt13,kmadd(dJ333L,PDstandardNth3gt13,kmadd(PDstandardNth11gt13,SQR(J13L),kmadd(PDstandardNth22gt13,SQR(J23L),kmadd(PDstandardNth33gt13,SQR(J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12gt13,kmul(J33L,PDstandardNth13gt13)),kmul(J23L,kmul(J33L,PDstandardNth23gt13))),ToReal(2)))))))); + kmadd(dJ133L,PDstandardNth1gt13,kmadd(dJ233L,PDstandardNth2gt13,kmadd(dJ333L,PDstandardNth3gt13,kmadd(PDstandardNth11gt13,kmul(J13L,J13L),kmadd(PDstandardNth22gt13,kmul(J23L,J23L),kmadd(PDstandardNth33gt13,kmul(J33L,J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12gt13,kmul(J33L,PDstandardNth13gt13)),kmul(J23L,kmul(J33L,PDstandardNth23gt13))),ToReal(2)))))))); JacPDstandardNth33gt22 = - kmadd(dJ133L,PDstandardNth1gt22,kmadd(dJ233L,PDstandardNth2gt22,kmadd(dJ333L,PDstandardNth3gt22,kmadd(PDstandardNth11gt22,SQR(J13L),kmadd(PDstandardNth22gt22,SQR(J23L),kmadd(PDstandardNth33gt22,SQR(J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12gt22,kmul(J33L,PDstandardNth13gt22)),kmul(J23L,kmul(J33L,PDstandardNth23gt22))),ToReal(2)))))))); + kmadd(dJ133L,PDstandardNth1gt22,kmadd(dJ233L,PDstandardNth2gt22,kmadd(dJ333L,PDstandardNth3gt22,kmadd(PDstandardNth11gt22,kmul(J13L,J13L),kmadd(PDstandardNth22gt22,kmul(J23L,J23L),kmadd(PDstandardNth33gt22,kmul(J33L,J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12gt22,kmul(J33L,PDstandardNth13gt22)),kmul(J23L,kmul(J33L,PDstandardNth23gt22))),ToReal(2)))))))); JacPDstandardNth33gt23 = - kmadd(dJ133L,PDstandardNth1gt23,kmadd(dJ233L,PDstandardNth2gt23,kmadd(dJ333L,PDstandardNth3gt23,kmadd(PDstandardNth11gt23,SQR(J13L),kmadd(PDstandardNth22gt23,SQR(J23L),kmadd(PDstandardNth33gt23,SQR(J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12gt23,kmul(J33L,PDstandardNth13gt23)),kmul(J23L,kmul(J33L,PDstandardNth23gt23))),ToReal(2)))))))); + kmadd(dJ133L,PDstandardNth1gt23,kmadd(dJ233L,PDstandardNth2gt23,kmadd(dJ333L,PDstandardNth3gt23,kmadd(PDstandardNth11gt23,kmul(J13L,J13L),kmadd(PDstandardNth22gt23,kmul(J23L,J23L),kmadd(PDstandardNth33gt23,kmul(J33L,J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12gt23,kmul(J33L,PDstandardNth13gt23)),kmul(J23L,kmul(J33L,PDstandardNth23gt23))),ToReal(2)))))))); JacPDstandardNth33gt33 = - kmadd(dJ133L,PDstandardNth1gt33,kmadd(dJ233L,PDstandardNth2gt33,kmadd(dJ333L,PDstandardNth3gt33,kmadd(PDstandardNth11gt33,SQR(J13L),kmadd(PDstandardNth22gt33,SQR(J23L),kmadd(PDstandardNth33gt33,SQR(J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12gt33,kmul(J33L,PDstandardNth13gt33)),kmul(J23L,kmul(J33L,PDstandardNth23gt33))),ToReal(2)))))))); + kmadd(dJ133L,PDstandardNth1gt33,kmadd(dJ233L,PDstandardNth2gt33,kmadd(dJ333L,PDstandardNth3gt33,kmadd(PDstandardNth11gt33,kmul(J13L,J13L),kmadd(PDstandardNth22gt33,kmul(J23L,J23L),kmadd(PDstandardNth33gt33,kmul(J33L,J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12gt33,kmul(J33L,PDstandardNth13gt33)),kmul(J23L,kmul(J33L,PDstandardNth23gt33))),ToReal(2)))))))); JacPDstandardNth33phi = - kmadd(dJ133L,PDstandardNth1phi,kmadd(dJ233L,PDstandardNth2phi,kmadd(dJ333L,PDstandardNth3phi,kmadd(PDstandardNth11phi,SQR(J13L),kmadd(PDstandardNth22phi,SQR(J23L),kmadd(PDstandardNth33phi,SQR(J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12phi,kmul(J33L,PDstandardNth13phi)),kmul(J23L,kmul(J33L,PDstandardNth23phi))),ToReal(2)))))))); + kmadd(dJ133L,PDstandardNth1phi,kmadd(dJ233L,PDstandardNth2phi,kmadd(dJ333L,PDstandardNth3phi,kmadd(PDstandardNth11phi,kmul(J13L,J13L),kmadd(PDstandardNth22phi,kmul(J23L,J23L),kmadd(PDstandardNth33phi,kmul(J33L,J33L),kmul(kmadd(J13L,kmadd(J23L,PDstandardNth12phi,kmul(J33L,PDstandardNth13phi)),kmul(J23L,kmul(J33L,PDstandardNth23phi))),ToReal(2)))))))); JacPDstandardNth12gt11 = kmadd(J12L,kmadd(J11L,PDstandardNth11gt11,kmadd(J21L,PDstandardNth12gt11,kmul(J31L,PDstandardNth13gt11))),kmadd(J11L,kmadd(J22L,PDstandardNth12gt11,kmul(J32L,PDstandardNth13gt11)),kmadd(dJ112L,PDstandardNth1gt11,kmadd(J22L,kmadd(J21L,PDstandardNth22gt11,kmul(J31L,PDstandardNth23gt11)),kmadd(dJ212L,PDstandardNth2gt11,kmadd(J32L,kmadd(J21L,PDstandardNth23gt11,kmul(J31L,PDstandardNth33gt11)),kmul(dJ312L,PDstandardNth3gt11))))))); @@ -1224,22 +1228,22 @@ static void ML_BSSN_constraints1_Body(cGH const * restrict const cctkGH, int con CCTK_REAL_VEC detgt = ToReal(1); CCTK_REAL_VEC gtu11 = - kmul(INV(detgt),kmsub(gt22L,gt33L,SQR(gt23L))); + kdiv(kmsub(gt22L,gt33L,kmul(gt23L,gt23L)),detgt); CCTK_REAL_VEC gtu12 = - kmul(INV(detgt),kmsub(gt13L,gt23L,kmul(gt12L,gt33L))); + kdiv(kmsub(gt13L,gt23L,kmul(gt12L,gt33L)),detgt); CCTK_REAL_VEC gtu13 = - kmul(INV(detgt),kmsub(gt12L,gt23L,kmul(gt13L,gt22L))); + kdiv(kmsub(gt12L,gt23L,kmul(gt13L,gt22L)),detgt); CCTK_REAL_VEC gtu22 = - kmul(INV(detgt),kmsub(gt11L,gt33L,SQR(gt13L))); + kdiv(kmsub(gt11L,gt33L,kmul(gt13L,gt13L)),detgt); CCTK_REAL_VEC gtu23 = - kmul(INV(detgt),kmsub(gt12L,gt13L,kmul(gt11L,gt23L))); + kdiv(kmsub(gt12L,gt13L,kmul(gt11L,gt23L)),detgt); CCTK_REAL_VEC gtu33 = - kmul(INV(detgt),kmsub(gt11L,gt22L,SQR(gt12L))); + kdiv(kmsub(gt11L,gt22L,kmul(gt12L,gt12L)),detgt); CCTK_REAL_VEC Gtl111 = kmul(JacPDstandardNth1gt11,ToReal(0.5)); @@ -1431,9 +1435,9 @@ static void ML_BSSN_constraints1_Body(cGH const * restrict const cctkGH, int con kmadd(Gt311,gtu11,kmadd(Gt322,gtu22,kmadd(Gt333,gtu33,kmul(kmadd(Gt312,gtu12,kmadd(Gt313,gtu13,kmul(Gt323,gtu23))),ToReal(2))))); CCTK_REAL_VEC e4phi = IfThen(conformalMethod == - 1,INV(SQR(phiL)),kexp(kmul(phiL,ToReal(4)))); + 1,kdiv(ToReal(1),kmul(phiL,phiL)),kexp(kmul(phiL,ToReal(4)))); - CCTK_REAL_VEC em4phi = INV(e4phi); + CCTK_REAL_VEC em4phi = kdiv(ToReal(1),e4phi); CCTK_REAL_VEC gu11 = kmul(em4phi,gtu11); @@ -1466,7 +1470,7 @@ static void ML_BSSN_constraints1_Body(cGH const * restrict const cctkGH, int con kmul(ToReal(0.5),knmsub(gtu11,JacPDstandardNth11gt33,knmsub(gtu22,JacPDstandardNth22gt33,knmsub(gtu33,JacPDstandardNth33gt33,knmsub(gtu12,kadd(JacPDstandardNth21gt33,JacPDstandardNth12gt33),knmsub(gtu13,kadd(JacPDstandardNth31gt33,JacPDstandardNth13gt33),knmsub(gtu23,kadd(JacPDstandardNth32gt33,JacPDstandardNth23gt33),kmadd(gt23L,kmul(JacPDstandardNth3Xt2,ToReal(2)),kmadd(gt33L,kmul(JacPDstandardNth3Xt3,ToReal(2)),kmadd(Gtl313,kmul(Xtn1,ToReal(2)),kmadd(Gtl323,kmul(Xtn2,ToReal(2)),kmadd(Gtl333,kmul(Xtn3,ToReal(2)),kmadd(ToReal(2),kmadd(Gt133,Gtlu133,kmadd(Gt213,Gtlu231,kmadd(Gt223,Gtlu232,kmadd(Gt233,Gtlu233,kmadd(gt13L,JacPDstandardNth3Xt1,kmadd(Gt113,kmadd(Gtlu311,ToReal(2),Gtlu131),kmul(Gt123,kmadd(Gtlu312,ToReal(2),Gtlu132)))))))),kmadd(kmadd(Gt133,Gtlu313,kmadd(Gt213,Gtlu321,kmadd(Gt223,Gtlu322,kmul(Gt233,Gtlu323)))),ToReal(4),kmul(kmadd(Gt313,Gtlu331,kmadd(Gt323,Gtlu332,kmul(Gt333,Gtlu333))),ToReal(6)))))))))))))))); CCTK_REAL_VEC fac1 = IfThen(conformalMethod == - 1,kmul(INV(phiL),ToReal(-0.5)),ToReal(1)); + 1,kdiv(ToReal(-0.5),phiL),ToReal(1)); CCTK_REAL_VEC cdphi1 = kmul(fac1,JacPDstandardNth1phi); @@ -1475,10 +1479,10 @@ static void ML_BSSN_constraints1_Body(cGH const * restrict const cctkGH, int con CCTK_REAL_VEC cdphi3 = kmul(fac1,JacPDstandardNth3phi); CCTK_REAL_VEC fac2 = IfThen(conformalMethod == - 1,kmul(INV(SQR(phiL)),ToReal(0.5)),ToReal(0)); + 1,kdiv(ToReal(0.5),kmul(phiL,phiL)),ToReal(0)); CCTK_REAL_VEC cdphi211 = - kmadd(fac2,SQR(JacPDstandardNth1phi),kmul(fac1,ksub(JacPDstandardNth11phi,kmadd(Gt111,JacPDstandardNth1phi,kmadd(Gt311,JacPDstandardNth3phi,kmul(Gt211,JacPDstandardNth2phi)))))); + kmadd(fac2,kmul(JacPDstandardNth1phi,JacPDstandardNth1phi),kmul(fac1,ksub(JacPDstandardNth11phi,kmadd(Gt111,JacPDstandardNth1phi,kmadd(Gt311,JacPDstandardNth3phi,kmul(Gt211,JacPDstandardNth2phi)))))); CCTK_REAL_VEC cdphi212 = kmadd(fac2,kmul(JacPDstandardNth1phi,JacPDstandardNth2phi),kmul(fac1,ksub(JacPDstandardNth12phi,kmadd(Gt112,JacPDstandardNth1phi,kmadd(Gt312,JacPDstandardNth3phi,kmul(Gt212,JacPDstandardNth2phi)))))); @@ -1487,31 +1491,31 @@ static void ML_BSSN_constraints1_Body(cGH const * restrict const cctkGH, int con kmadd(fac2,kmul(JacPDstandardNth1phi,JacPDstandardNth3phi),kmul(fac1,ksub(JacPDstandardNth13phi,kmadd(Gt113,JacPDstandardNth1phi,kmadd(Gt313,JacPDstandardNth3phi,kmul(Gt213,JacPDstandardNth2phi)))))); CCTK_REAL_VEC cdphi222 = - kmsub(fac2,SQR(JacPDstandardNth2phi),kmul(fac1,kmadd(Gt122,JacPDstandardNth1phi,kmadd(Gt222,JacPDstandardNth2phi,kmsub(Gt322,JacPDstandardNth3phi,JacPDstandardNth22phi))))); + kmsub(fac2,kmul(JacPDstandardNth2phi,JacPDstandardNth2phi),kmul(fac1,kmadd(Gt122,JacPDstandardNth1phi,kmadd(Gt222,JacPDstandardNth2phi,kmsub(Gt322,JacPDstandardNth3phi,JacPDstandardNth22phi))))); CCTK_REAL_VEC cdphi223 = kmsub(fac2,kmul(JacPDstandardNth2phi,JacPDstandardNth3phi),kmul(fac1,kmadd(Gt123,JacPDstandardNth1phi,kmadd(Gt223,JacPDstandardNth2phi,kmsub(Gt323,JacPDstandardNth3phi,JacPDstandardNth23phi))))); CCTK_REAL_VEC cdphi233 = - kmsub(fac2,SQR(JacPDstandardNth3phi),kmul(fac1,kmadd(Gt133,JacPDstandardNth1phi,kmadd(Gt233,JacPDstandardNth2phi,kmsub(Gt333,JacPDstandardNth3phi,JacPDstandardNth33phi))))); + kmsub(fac2,kmul(JacPDstandardNth3phi,JacPDstandardNth3phi),kmul(fac1,kmadd(Gt133,JacPDstandardNth1phi,kmadd(Gt233,JacPDstandardNth2phi,kmsub(Gt333,JacPDstandardNth3phi,JacPDstandardNth33phi))))); CCTK_REAL_VEC Rphi11 = - kmul(ToReal(-2),kadd(cdphi211,kmadd(SQR(cdphi1),kmul(kmadd(gt11L,gtu11,ToReal(-1)),ToReal(2)),kmul(gt11L,kmadd(cdphi211,gtu11,kmadd(cdphi233,gtu33,kmadd(kmadd(cdphi212,gtu12,kmadd(cdphi213,gtu13,kmadd(cdphi223,gtu23,kmul(gtu33,SQR(cdphi3))))),ToReal(2),kmadd(gtu22,kmadd(SQR(cdphi2),ToReal(2),cdphi222),kmul(kmadd(cdphi1,kmadd(cdphi2,gtu12,kmul(cdphi3,gtu13)),kmul(cdphi2,kmul(cdphi3,gtu23))),ToReal(4)))))))))); + kmul(ToReal(-2),kadd(cdphi211,kmadd(kmul(cdphi1,cdphi1),kmul(kmadd(gt11L,gtu11,ToReal(-1)),ToReal(2)),kmul(gt11L,kmadd(cdphi211,gtu11,kmadd(cdphi233,gtu33,kmadd(kmadd(cdphi212,gtu12,kmadd(cdphi213,gtu13,kmadd(cdphi223,gtu23,kmul(gtu33,kmul(cdphi3,cdphi3))))),ToReal(2),kmadd(gtu22,kmadd(kmul(cdphi2,cdphi2),ToReal(2),cdphi222),kmul(kmadd(cdphi1,kmadd(cdphi2,gtu12,kmul(cdphi3,gtu13)),kmul(cdphi2,kmul(cdphi3,gtu23))),ToReal(4)))))))))); CCTK_REAL_VEC Rphi12 = - kmul(ToReal(-2),kadd(cdphi212,kmadd(gt12L,kmadd(cdphi211,gtu11,kmadd(kmadd(cdphi212,gtu12,kmadd(cdphi213,gtu13,kmadd(cdphi223,gtu23,kmul(gtu11,SQR(cdphi1))))),ToReal(2),kmadd(gtu22,kmadd(SQR(cdphi2),ToReal(2),cdphi222),kmadd(gtu33,kmadd(SQR(cdphi3),ToReal(2),cdphi233),kmul(cdphi2,kmul(cdphi3,kmul(gtu23,ToReal(4)))))))),kmul(cdphi1,kmadd(gt12L,kmul(cdphi3,kmul(gtu13,ToReal(4))),kmul(cdphi2,kmadd(gt12L,kmul(gtu12,ToReal(4)),ToReal(-2)))))))); + kmul(ToReal(-2),kadd(cdphi212,kmadd(gt12L,kmadd(cdphi211,gtu11,kmadd(kmadd(cdphi212,gtu12,kmadd(cdphi213,gtu13,kmadd(cdphi223,gtu23,kmul(gtu11,kmul(cdphi1,cdphi1))))),ToReal(2),kmadd(gtu22,kmadd(kmul(cdphi2,cdphi2),ToReal(2),cdphi222),kmadd(gtu33,kmadd(kmul(cdphi3,cdphi3),ToReal(2),cdphi233),kmul(cdphi2,kmul(cdphi3,kmul(gtu23,ToReal(4)))))))),kmul(cdphi1,kmadd(gt12L,kmul(cdphi3,kmul(gtu13,ToReal(4))),kmul(cdphi2,kmadd(gt12L,kmul(gtu12,ToReal(4)),ToReal(-2)))))))); CCTK_REAL_VEC Rphi13 = - kmul(ToReal(-2),kadd(cdphi213,kmadd(gt13L,kmadd(cdphi211,gtu11,kmadd(kmadd(cdphi212,gtu12,kmadd(cdphi213,gtu13,kmadd(cdphi223,gtu23,kmul(gtu11,SQR(cdphi1))))),ToReal(2),kmadd(gtu22,kmadd(SQR(cdphi2),ToReal(2),cdphi222),kmadd(gtu33,kmadd(SQR(cdphi3),ToReal(2),cdphi233),kmul(cdphi2,kmul(cdphi3,kmul(gtu23,ToReal(4)))))))),kmul(cdphi1,kmadd(gt13L,kmul(cdphi2,kmul(gtu12,ToReal(4))),kmul(cdphi3,kmadd(gt13L,kmul(gtu13,ToReal(4)),ToReal(-2)))))))); + kmul(ToReal(-2),kadd(cdphi213,kmadd(gt13L,kmadd(cdphi211,gtu11,kmadd(kmadd(cdphi212,gtu12,kmadd(cdphi213,gtu13,kmadd(cdphi223,gtu23,kmul(gtu11,kmul(cdphi1,cdphi1))))),ToReal(2),kmadd(gtu22,kmadd(kmul(cdphi2,cdphi2),ToReal(2),cdphi222),kmadd(gtu33,kmadd(kmul(cdphi3,cdphi3),ToReal(2),cdphi233),kmul(cdphi2,kmul(cdphi3,kmul(gtu23,ToReal(4)))))))),kmul(cdphi1,kmadd(gt13L,kmul(cdphi2,kmul(gtu12,ToReal(4))),kmul(cdphi3,kmadd(gt13L,kmul(gtu13,ToReal(4)),ToReal(-2)))))))); CCTK_REAL_VEC Rphi22 = - kmul(ToReal(-2),kadd(cdphi222,kmadd(SQR(cdphi2),kmul(kmadd(gt22L,gtu22,ToReal(-1)),ToReal(2)),kmul(gt22L,kmadd(cdphi222,gtu22,kmadd(cdphi233,gtu33,kmadd(kmadd(cdphi212,gtu12,kmadd(cdphi213,gtu13,kmadd(cdphi223,gtu23,kmul(gtu33,SQR(cdphi3))))),ToReal(2),kmadd(gtu11,kmadd(SQR(cdphi1),ToReal(2),cdphi211),kmul(kmadd(cdphi1,kmul(cdphi3,gtu13),kmul(cdphi2,kmadd(cdphi1,gtu12,kmul(cdphi3,gtu23)))),ToReal(4)))))))))); + kmul(ToReal(-2),kadd(cdphi222,kmadd(kmul(cdphi2,cdphi2),kmul(kmadd(gt22L,gtu22,ToReal(-1)),ToReal(2)),kmul(gt22L,kmadd(cdphi222,gtu22,kmadd(cdphi233,gtu33,kmadd(kmadd(cdphi212,gtu12,kmadd(cdphi213,gtu13,kmadd(cdphi223,gtu23,kmul(gtu33,kmul(cdphi3,cdphi3))))),ToReal(2),kmadd(gtu11,kmadd(kmul(cdphi1,cdphi1),ToReal(2),cdphi211),kmul(kmadd(cdphi1,kmul(cdphi3,gtu13),kmul(cdphi2,kmadd(cdphi1,gtu12,kmul(cdphi3,gtu23)))),ToReal(4)))))))))); CCTK_REAL_VEC Rphi23 = - kmul(ToReal(-2),kadd(cdphi223,kmadd(gt23L,kmadd(cdphi222,gtu22,kmadd(kmadd(cdphi212,gtu12,kmadd(cdphi213,gtu13,kmadd(cdphi223,gtu23,kmul(gtu22,SQR(cdphi2))))),ToReal(2),kmadd(gtu11,kmadd(SQR(cdphi1),ToReal(2),cdphi211),kmadd(gtu33,kmadd(SQR(cdphi3),ToReal(2),cdphi233),kmul(cdphi1,kmul(cdphi3,kmul(gtu13,ToReal(4)))))))),kmul(cdphi2,kmadd(gt23L,kmul(cdphi1,kmul(gtu12,ToReal(4))),kmul(cdphi3,kmadd(gt23L,kmul(gtu23,ToReal(4)),ToReal(-2)))))))); + kmul(ToReal(-2),kadd(cdphi223,kmadd(gt23L,kmadd(cdphi222,gtu22,kmadd(kmadd(cdphi212,gtu12,kmadd(cdphi213,gtu13,kmadd(cdphi223,gtu23,kmul(gtu22,kmul(cdphi2,cdphi2))))),ToReal(2),kmadd(gtu11,kmadd(kmul(cdphi1,cdphi1),ToReal(2),cdphi211),kmadd(gtu33,kmadd(kmul(cdphi3,cdphi3),ToReal(2),cdphi233),kmul(cdphi1,kmul(cdphi3,kmul(gtu13,ToReal(4)))))))),kmul(cdphi2,kmadd(gt23L,kmul(cdphi1,kmul(gtu12,ToReal(4))),kmul(cdphi3,kmadd(gt23L,kmul(gtu23,ToReal(4)),ToReal(-2)))))))); CCTK_REAL_VEC Rphi33 = - kmul(ToReal(-2),kadd(cdphi233,kmadd(SQR(cdphi3),kmul(kmadd(gt33L,gtu33,ToReal(-1)),ToReal(2)),kmul(gt33L,kmadd(cdphi233,gtu33,kmadd(kmadd(cdphi213,gtu13,kmul(cdphi223,gtu23)),ToReal(2),kmadd(gtu11,kmadd(SQR(cdphi1),ToReal(2),cdphi211),kmadd(gtu22,kmadd(SQR(cdphi2),ToReal(2),cdphi222),kmadd(cdphi3,kmul(kmadd(cdphi1,gtu13,kmul(cdphi2,gtu23)),ToReal(4)),kmul(gtu12,kmadd(cdphi212,ToReal(2),kmul(cdphi1,kmul(cdphi2,ToReal(4)))))))))))))); + kmul(ToReal(-2),kadd(cdphi233,kmadd(kmul(cdphi3,cdphi3),kmul(kmadd(gt33L,gtu33,ToReal(-1)),ToReal(2)),kmul(gt33L,kmadd(cdphi233,gtu33,kmadd(kmadd(cdphi213,gtu13,kmul(cdphi223,gtu23)),ToReal(2),kmadd(gtu11,kmadd(kmul(cdphi1,cdphi1),ToReal(2),cdphi211),kmadd(gtu22,kmadd(kmul(cdphi2,cdphi2),ToReal(2),cdphi222),kmadd(cdphi3,kmul(kmadd(cdphi1,gtu13,kmul(cdphi2,gtu23)),ToReal(4)),kmul(gtu12,kmadd(cdphi212,ToReal(2),kmul(cdphi1,kmul(cdphi2,ToReal(4)))))))))))))); CCTK_REAL_VEC R11 = kadd(Rphi11,Rt11); @@ -1556,10 +1560,10 @@ static void ML_BSSN_constraints1_Body(cGH const * restrict const cctkGH, int con kmadd(At13L,gtu13,kmadd(At23L,gtu23,kmul(At33L,gtu33))); CCTK_REAL_VEC rho = - kmul(INV(SQR(alphaL)),kadd(eTttL,kmadd(eTxxL,SQR(beta1L),kmadd(eTyyL,SQR(beta2L),kmadd(eTzzL,SQR(beta3L),kmadd(kmadd(beta2L,eTtyL,kmul(beta3L,eTtzL)),ToReal(-2),kmul(kmadd(beta2L,kmul(beta3L,eTyzL),kmul(beta1L,kmadd(beta2L,eTxyL,kmsub(beta3L,eTxzL,eTtxL)))),ToReal(2)))))))); + kdiv(kadd(eTttL,kmadd(eTxxL,kmul(beta1L,beta1L),kmadd(eTyyL,kmul(beta2L,beta2L),kmadd(eTzzL,kmul(beta3L,beta3L),kmadd(kmadd(beta2L,eTtyL,kmul(beta3L,eTtzL)),ToReal(-2),kmul(kmadd(beta2L,kmul(beta3L,eTyzL),kmul(beta1L,kmadd(beta2L,eTxyL,kmsub(beta3L,eTxzL,eTtxL)))),ToReal(2))))))),kmul(alphaL,alphaL)); CCTK_REAL_VEC HL = - kadd(trR,kmadd(kmadd(Atm12,Atm21,kmadd(Atm13,Atm31,kmul(Atm23,Atm32))),ToReal(-2),ksub(ksub(ksub(kmadd(SQR(trKL),ToReal(0.666666666666666666666666666667),kmul(rho,kmul(ToReal(-16),ToReal(Pi)))),SQR(Atm33)),SQR(Atm22)),SQR(Atm11)))); + kadd(trR,kmadd(kmadd(Atm12,Atm21,kmadd(Atm13,Atm31,kmul(Atm23,Atm32))),ToReal(-2),knmsub(Atm11,Atm11,knmsub(Atm22,Atm22,knmsub(Atm33,Atm33,kmadd(kmul(trKL,trKL),ToReal(0.666666666666666666666666666667),kmul(rho,ToReal(-16*Pi)))))))); /* Copy local copies back to grid functions */ vec_store_partial_prepare(i,lc_imin,lc_imax); |