move update well test state to after potentials are calculated

This commit is contained in:
Tor Harald Sandve 2021-08-09 13:21:10 +02:00
parent 1cbc096d20
commit cf61417b6d

View File

@ -454,7 +454,6 @@ namespace Opm {
well->updateWaterThroughput(dt, this->wellState());
}
}
updateWellTestState(simulationTime, wellTestState_);
// update the rate converter with current averages pressures etc in
rateConverter_->template defineState<ElementContext>(ebosSimulator_);
@ -470,6 +469,8 @@ namespace Opm {
local_deferredLogger.warning("WELL_POTENTIAL_CALCULATION_FAILED", msg);
}
updateWellTestState(simulationTime, wellTestState_);
// check group sales limits at the end of the timestep
const Group& fieldGroup = schedule().getGroup("FIELD", reportStepIdx);
checkGconsaleLimits(fieldGroup, this->wellState(),