fixed: copy the mobility values into the temporary Eval vector

This commit is contained in:
Arne Morten Kvarving 2023-05-12 15:11:53 +02:00
parent a145cdfcc8
commit 1b073185a1

View File

@ -955,6 +955,8 @@ namespace Opm
// as a result, the polymer and water share the same viscosity
if constexpr (!Base::has_polymermw) {
std::vector<EvalWell> mob_eval(this->num_components_, {this->primary_variables_.numWellEq() + Indices::numEq, 0.});
for (size_t i = 0; i < mob.size(); ++i)
mob_eval[i].setValue(mob[i]);
updateWaterMobilityWithPolymer(ebosSimulator, perf, mob_eval, deferred_logger);
for (size_t i = 0; i < mob.size(); ++i) {
mob[i] = getValue(mob_eval[i]);