Excessive nonlinear iterations is reported as problem, not error.

This commit is contained in:
Atgeirr Flø Rasmussen 2017-04-06 14:52:19 +02:00
parent 431abb0012
commit e325dcd04b

View File

@ -150,13 +150,11 @@ namespace Opm
} while ( (!converged && (iteration <= maxIter())) || (iteration <= minIter())); } while ( (!converged && (iteration <= maxIter())) || (iteration <= minIter()));
if (!converged) { if (!converged) {
std::string msg = "Failed to complete a time step within " + std::to_string(maxIter()) + " iterations.";
if (model_->terminalOutputEnabled()) { if (model_->terminalOutputEnabled()) {
OPM_THROW(Opm::NumericalProblem, "Failed to complete a time step within "+std::to_string(maxIter())+" iterations."); OpmLog::problem(msg);
}
else
{
OPM_THROW_NOLOG(Opm::NumericalProblem, "Failed to complete a time step within "+std::to_string(maxIter())+" iterations.");
} }
OPM_THROW_NOLOG(Opm::NumericalProblem, msg);
} }
// Do model-specific post-step actions. // Do model-specific post-step actions.