const Loop::GF3D<const CCTK_REAL, 1, 1, 1> divb_(cctkGH, divb);
const auto nancheck = [&](const CCTK_REAL *restrict var,
const Loop::PointDesc &p) {
if (CCTK_isnan(var[p.idx]))
CCTK_VERROR("Found nan at [%d,%d,%d]", p.i, p.j, p.k);
};
Loop::loop_all<0, 0, 0>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(phi, p); });
Loop::loop_all<1, 0, 0>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(ax, p); });
Loop::loop_all<0, 1, 0>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(ay, p); });
Loop::loop_all<0, 0, 1>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(az, p); });
Loop::loop_all<1, 0, 0>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(ex, p); });
Loop::loop_all<0, 1, 0>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(ey, p); });
Loop::loop_all<0, 0, 1>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(ez, p); });
Loop::loop_all<0, 1, 1>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(bx, p); });
Loop::loop_all<1, 0, 1>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(by, p); });
Loop::loop_all<1, 1, 0>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(bz, p); });
Loop::loop_all<0, 0, 0>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(rho, p); });
Loop::loop_all<1, 0, 0>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(jx, p); });
Loop::loop_all<0, 1, 0>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(jy, p); });
Loop::loop_all<0, 0, 1>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(jz, p); });
Loop::loop_all<0, 0, 0>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(dive, p); });
Loop::loop_all<1, 1, 1>(cctkGH,
[&](const Loop::PointDesc &p) { nancheck(divb, p); });
}