recovering some unecessary changes.

PR #1477 introduced different ways to improve the WellState initialization.
Basically, the WellState initialization will be something challenging to
handle along with the improvement of the well model.
This commit is contained in:
Kai Bao
2018-05-15 16:34:31 +02:00
parent 18917b81f4
commit f3f096dbbb
4 changed files with 18 additions and 22 deletions

View File

@@ -154,8 +154,6 @@ namespace Opm
// TODO: using comp_frac here is dangerous, it should be changed later
// Most likely, it should be changed to use distr, or at least, we need to update comp_frac_ based on distr
// while solvent might complicate the situation
//
// TODO: it is possible that the RESV for the injector is not well handled here.
const auto pu = phaseUsage();
const int legacyCompIdx = ebosCompIdxToFlowCompIdx(comp_idx);
double comp_frac = 0.0;
@@ -170,7 +168,6 @@ namespace Opm
comp_frac = comp_frac_[legacyCompIdx];
}
// testing code end
return comp_frac * primary_variables_evaluation_[GTotal];
} else { // producers
return primary_variables_evaluation_[GTotal] * wellVolumeFractionScaled(comp_idx);
@@ -666,13 +663,9 @@ namespace Opm
}
assert(number_phases_under_control > 0);
const double target_rate = well_controls_get_current_target(well_controls_);
const double target_rate = well_controls_get_current_target(well_controls_); // surface rate target
if (well_type_ == INJECTOR) {
assert(number_phases_under_control == 1); // only handles single phase injection now
// TODO: considering the solvent part here
// Better way to cover solvent part will be getQs() - target_rate, while it turned out not correct
// for the solvent case.
control_eq = getGTotal() - target_rate;
} else if (well_type_ == PRODUCER) {
EvalWell rate_for_control(0.);
@@ -688,7 +681,7 @@ namespace Opm
}
case RESERVOIR_RATE:
{
// TODO: repeated code here
// TODO: repeated code here, while hopefully it gives better readability
int number_phases_under_control = 0;
const double* distr = well_controls_get_current_distr(well_controls_);
for (int phase = 0; phase < number_of_phases_; ++phase) {