error explanations for net charge warning err_0029

This commit is contained in:
James Michael Goff
2025-03-03 10:59:23 -07:00
parent 3138f62ac8
commit 2e3c1dfcc6
8 changed files with 46 additions and 10 deletions

View File

@ -323,8 +323,8 @@ void KSpace::qsum_qsq(int warning_flag)
if (fabs(qsum) > SMALL) {
std::string message = fmt::format("System is not charge neutral, net "
"charge = {:.8}",qsum);
if (!warn_nonneutral) error->all(FLERR,message);
if (warn_nonneutral == 1 && comm->me == 0) error->warning(FLERR,message);
if (!warn_nonneutral) error->all(FLERR,message + utils::errorurl(29));
if (warn_nonneutral == 1 && comm->me == 0) error->warning(FLERR,message + utils::errorurl(29));
warn_nonneutral = 2;
}
}