Skip to content

Commit 05303d0

Browse files
atgeirrAtgeirr Flø Rasmussen
authored andcommitted
Set the actual parameter pointers.
1 parent 210ba00 commit 05303d0

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

opm/material/fluidmatrixinteractions/EclMaterialLawManagerSimpleInitParams.cpp

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -199,19 +199,21 @@ void
199199
EclMaterialLawManagerSimple<Traits>::InitParams::
200200
initThreePhaseParams_(//HystParams &hystParams,
201201
MaterialLawParams& materialParams,
202-
[[maybe_unused]] unsigned satRegionIdx,
202+
unsigned satRegionIdx,
203203
[[maybe_unused]] unsigned elemIdx)
204204
{
205-
// const auto& epsInfo = this->parent_.oilWaterScaledEpsInfoDrainage_[elemIdx];
206-
207-
// auto oilWaterParams = hystParams.getOilWaterParams();
208-
// auto gasOilParams = hystParams.getGasOilParams();
209-
// auto gasWaterParams = hystParams.getGasWaterParams();
210205
auto& realParams = materialParams;
211-
// realParams.setGasOilParams(gasOilParams);
212-
// realParams.setOilWaterParams(oilWaterParams);
213-
// realParams.setGasWaterParams(gasWaterParams);
214206
realParams.setApproach(this->parent_.twoPhaseApproach_);
207+
208+
if (realParams.approach() == EclTwoPhaseApproach::GasOil) {
209+
realParams.setGasOilParams(this->parent_.gasOilEffectiveParamVector_[satRegionIdx]);
210+
}
211+
else if (realParams.approach() == EclTwoPhaseApproach::GasWater) {
212+
realParams.setGasWaterParams(this->parent_.gasWaterEffectiveParamVector_[satRegionIdx]);
213+
}
214+
else if (realParams.approach() == EclTwoPhaseApproach::OilWater) {
215+
realParams.setOilWaterParams(this->parent_.oilWaterEffectiveParamVector_[satRegionIdx]);
216+
}
215217
realParams.finalize();
216218
}
217219

0 commit comments

Comments
 (0)