bool some_sources_invalid = false;
for (int vi = 0; vi < groupdata.numvars; ++vi) {
if (!coarsegroupdata.valid.at(tl).at(vi).valid_int) {
CCTK_VWARN(CCTK_WARN_ALERT,
"Prolongation requires valid interior in coarse grid (level = %d), but found it invalid for '%s' on timelevel %d",
level - 1, CCTK_FullVarName(vi), tl);
some_sources_invalid = true;
}
if (!coarsegroupdata.valid.at(tl).at(vi).valid_outer) {
CCTK_VWARN(CCTK_WARN_ALERT,
"Prolongation requires valid boundary in coarse grid (level = %d), but found it invalid for '%s' on timelevel %d",
level - 1, CCTK_FullVarName(vi), tl);
some_sources_invalid = true;
}
if (!coarsegroupdata.valid.at(tl).at(vi).valid_ghosts) {
CCTK_VWARN(CCTK_WARN_ALERT,
"Prolongation requires valid ghosts in coarse grid (level = %d), but found it invalid for '%s' on timelevel %d",
level - 1, CCTK_FullVarName(vi), tl);
some_sources_invalid = true;
}
if (!groupdata.valid.at(tl).at(vi).valid_int) {
CCTK_VWARN(CCTK_WARN_ALERT,
"Prolongation expects valid interior in fine grid (level = %d), but found it invalid for '%s' on timelevel %d",
level, CCTK_FullVarName(vi), tl);
some_sources_invalid = true;
}
}
if (some_sources_invalid)
CCTK_ERROR("Some sources for prolongation were invalid");