mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
avoid re-opening previously stopped wells
This commit is contained in:
@@ -1621,9 +1621,12 @@ namespace Opm
|
|||||||
const auto well_status_orig = this->wellStatus_;
|
const auto well_status_orig = this->wellStatus_;
|
||||||
const auto operability_orig = this->operability_status_;
|
const auto operability_orig = this->operability_status_;
|
||||||
auto well_status_cur = well_status_orig;
|
auto well_status_cur = well_status_orig;
|
||||||
// only allow switcing if well is not under zero-rate target and is open from schedule
|
// don't allow opening wells that are stopped from schedule or has a stopped well state
|
||||||
bool allow_switching = !this->wellUnderZeroRateTarget(summary_state, well_state) && (this->well_ecl_.getStatus() == WellStatus::OPEN);
|
const bool allow_open = this->well_ecl_.getStatus() == WellStatus::OPEN &&
|
||||||
allow_switching = allow_switching && (!fixed_control || !fixed_status);
|
well_state.well(this->index_of_well_).status == WellStatus::OPEN;
|
||||||
|
// don't allow switcing for wells under zero rate target or requested fixed status and control
|
||||||
|
const bool allow_switching = !this->wellUnderZeroRateTarget(summary_state, well_state) &&
|
||||||
|
(!fixed_control || !fixed_status) && allow_open;
|
||||||
bool changed = false;
|
bool changed = false;
|
||||||
bool final_check = false;
|
bool final_check = false;
|
||||||
// well needs to be set operable or else solving/updating of re-opened wells is skipped
|
// well needs to be set operable or else solving/updating of re-opened wells is skipped
|
||||||
|
|||||||
@@ -2339,9 +2339,12 @@ namespace Opm
|
|||||||
const auto operability_orig = this->operability_status_;
|
const auto operability_orig = this->operability_status_;
|
||||||
auto well_status_cur = well_status_orig;
|
auto well_status_cur = well_status_orig;
|
||||||
int status_switch_count = 0;
|
int status_switch_count = 0;
|
||||||
// only allow switcing if well is not under zero-rate target and is open from schedule
|
// don't allow opening wells that are stopped from schedule or has a stopped well state
|
||||||
bool allow_switching = !this->wellUnderZeroRateTarget(summary_state, well_state) && (this->well_ecl_.getStatus() == WellStatus::OPEN);
|
const bool allow_open = this->well_ecl_.getStatus() == WellStatus::OPEN &&
|
||||||
allow_switching = allow_switching && (!fixed_control || !fixed_status);
|
well_state.well(this->index_of_well_).status == WellStatus::OPEN;
|
||||||
|
// don't allow switcing for wells under zero rate target or requested fixed status and control
|
||||||
|
const bool allow_switching = !this->wellUnderZeroRateTarget(summary_state, well_state) &&
|
||||||
|
(!fixed_control || !fixed_status) && allow_open;
|
||||||
bool changed = false;
|
bool changed = false;
|
||||||
bool final_check = false;
|
bool final_check = false;
|
||||||
// well needs to be set operable or else solving/updating of re-opened wells is skipped
|
// well needs to be set operable or else solving/updating of re-opened wells is skipped
|
||||||
|
|||||||
Reference in New Issue
Block a user