Skip to content

Commit

Permalink
Merge pull request #47 from EinsteinToolkit/lwji/constraints
Browse files Browse the repository at this point in the history
  • Loading branch information
lwJi authored Nov 12, 2024
2 parents 3c3e5c6 + 534fba8 commit ac18216
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions Z4c/src/z4c_vars.hxx
Original file line number Diff line number Diff line change
Expand Up @@ -538,11 +538,14 @@ template <typename T> struct z4c_vars : z4c_vars_noderivs<T> {
// Constraints
// (13)
ZtC([&](int a) ARITH_INLINE { return (Gamt(a) - Gamtd(a)) / 2; }), //
// For the Hamiltonian and momentum constraints, the equations in
// 1212.2901 is incorrect, whereas the one in 0912.2920 is correct,
// as double-checked by Liwei Ji.
// (14)
HC(Rsc //
+ sum_symm<3>([&](int x, int y)
- sum_symm<3>([&](int x, int y)
ARITH_INLINE { return At(x, y) * Atu(x, y); }) //
- 2 / T(3) * pow2(Kh + 2 * Theta) //
+ 2 / T(3) * pow2(Kh + 2 * Theta) //
- 16 * T(M_PI) * rho),
// (15)
MtC([&](int a) ARITH_INLINE {
Expand All @@ -554,7 +557,7 @@ template <typename T> struct z4c_vars : z4c_vars_noderivs<T> {
return (delta3(a, x) + gammatu(a, x)) *
(dKh(x) + 2 * dTheta(x));
}) //
- 2 / T(3) * sum<3>([&](int x) ARITH_INLINE {
- 3 / T(2) * sum<3>([&](int x) ARITH_INLINE {
return Atu(a, x) * dchi(x) / (1 + chi);
}) //
- 8 * T(M_PI) * sum<3>([&](int x) ARITH_INLINE {
Expand Down

0 comments on commit ac18216

Please sign in to comment.