Merge pull request #3874 from totto82/neg_pot_optional

only check if wells has negative potentials if check_well_operability=true(default)
This commit is contained in:
Tor Harald Sandve 2022-04-22 09:02:40 +02:00 committed by GitHub
commit 6f6eab3bf4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -313,11 +313,11 @@ namespace Opm
well_potentials[phase] *= sign;
total_potential += well_potentials[phase];
}
if (total_potential < 0.0) {
if (total_potential < 0.0 && this->param_.check_well_operability_) {
// wells with negative potentials are not operable
this->operability_status_.has_negative_potentials = true;
const std::string msg = std::string("well ") + this->name() + std::string(": has non negative potentials is not operable");
deferred_logger.info(msg);
deferred_logger.warning("NEGATIVE_POTENTIALS_INOPERABLE", msg);
}
}

View File

@ -1929,11 +1929,11 @@ namespace Opm
well_potentials[phase] *= sign;
total_potential += well_potentials[phase];
}
if (total_potential < 0.0) {
if (total_potential < 0.0 && this->param_.check_well_operability_) {
// wells with negative potentials are not operable
this->operability_status_.has_negative_potentials = true;
const std::string msg = std::string("well ") + this->name() + std::string(": has negative potentials and is not operable");
deferred_logger.info(msg);
deferred_logger.warning("NEGATIVE_POTENTIALS_INOPERABLE", msg);
}
}