mirror of
https://github.com/OPM/opm-simulators.git
synced 2024-12-22 15:33:29 -06:00
Only restrict oscillation for iter > nupcol
This commit is contained in:
parent
128e80ec7a
commit
738eb761c2
@ -213,8 +213,10 @@ namespace Opm
|
||||
from = WellProducerCMode2String(ws.production_cmode);
|
||||
}
|
||||
bool oscillating = std::count(this->well_control_log_.begin(), this->well_control_log_.end(), from) >= this->param_.max_number_of_well_switches_;
|
||||
|
||||
if (oscillating) {
|
||||
const int episodeIdx = simulator.episodeIndex();
|
||||
const int iterationIdx = simulator.model().newtonMethod().numIterations();
|
||||
const int nupcol = schedule[episodeIdx].nupcol();
|
||||
if (oscillating && iterationIdx > nupcol) {
|
||||
// only output frist time
|
||||
bool output = std::count(this->well_control_log_.begin(), this->well_control_log_.end(), from) == this->param_.max_number_of_well_switches_;
|
||||
if (output) {
|
||||
|
Loading…
Reference in New Issue
Block a user