Merge pull request #2047 from totto82/enableRockcompFlow

enable rockcomp in flow
This commit is contained in:
dr-robertk 2019-10-17 14:12:35 +02:00 committed by GitHub
commit 18c31bda0b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 13 additions and 19 deletions

View File

@ -119,7 +119,6 @@ class EclTransExtensiveQuantities
enum { numPhases = FluidSystem::numPhases };
enum { enableSolvent = GET_PROP_VALUE(TypeTag, EnableSolvent) };
enum { enableEnergy = GET_PROP_VALUE(TypeTag, EnableEnergy) };
enum { enableExperiments = GET_PROP_VALUE(TypeTag, EnableExperiments) };
typedef Opm::MathToolbox<Evaluation> Toolbox;
typedef Dune::FieldVector<Scalar, dimWorld> DimVector;
@ -437,10 +436,9 @@ protected:
const auto& up = elemCtx.intensiveQuantities(upstreamIdx, timeIdx);
Evaluation transModified = trans;
if (enableExperiments) {
// deal with water induced rock compaction
transModified *= problem.template rockCompTransMultiplier<double>(up, stencil.globalSpaceIndex(upstreamIdx));
}
// deal with water induced rock compaction
transModified *= problem.template rockCompTransMultiplier<double>(up, stencil.globalSpaceIndex(upstreamIdx));
if (upstreamIdx == interiorDofIdx_) {
volumeFlux_[phaseIdx] =

View File

@ -899,13 +899,11 @@ public:
for (size_t pvtRegionIdx = 0; pvtRegionIdx < maxDRv_.size(); ++pvtRegionIdx)
maxDRv_[pvtRegionIdx] = oilVaporizationControl.getMaxDRVDT(pvtRegionIdx)*this->simulator().timeStepSize();
if (enableExperiments) {
// update maximum water saturation and minimum pressure
// used when ROCKCOMP is activated
const bool invalidateFromMaxWaterSat = updateMaxWaterSaturation_();
const bool invalidateFromMinPressure = updateMinPressure_();
invalidateIntensiveQuantities = invalidateFromMaxWaterSat || invalidateFromMinPressure;
}
// update maximum water saturation and minimum pressure
// used when ROCKCOMP is activated
const bool invalidateFromMaxWaterSat = updateMaxWaterSaturation_();
const bool invalidateFromMinPressure = updateMinPressure_();
invalidateIntensiveQuantities = invalidateFromMaxWaterSat || invalidateFromMinPressure;
if (invalidateIntensiveQuantities)
this->model().invalidateIntensiveQuantitiesCache(/*timeIdx=*/0);
@ -1795,7 +1793,7 @@ public:
template <class LhsEval>
LhsEval rockCompPoroMultiplier(const IntensiveQuantities& intQuants, unsigned elementIdx) const
{
if (!enableExperiments || rockCompPoroMult_.size() == 0)
if (rockCompPoroMult_.empty())
return 1.0;
unsigned tableIdx = 0;
@ -1827,7 +1825,7 @@ public:
template <class LhsEval>
LhsEval rockCompTransMultiplier(const IntensiveQuantities& intQuants, unsigned elementIdx) const
{
if (!enableExperiments || rockCompTransMult_.size() == 0)
if (rockCompTransMult_.empty())
return 1.0;
unsigned tableIdx = 0;
@ -1858,7 +1856,7 @@ public:
*/
Scalar overburdenPressure(unsigned elementIdx) const
{
if (!enableExperiments || overburdenPressure_.size() == 0)
if (overburdenPressure_.empty())
return 0.0;
return overburdenPressure_[elementIdx];
@ -2101,7 +2099,7 @@ private:
bool updateMinPressure_()
{
// IRREVERS option is used in ROCKCOMP
if (minOilPressure_.size() == 0)
if (minOilPressure_.empty())
return false;
ElementContext elemCtx(this->simulator());
@ -2147,8 +2145,7 @@ private:
}
// read the parameters for water-induced rock compaction
if (enableExperiments)
readRockCompactionParameters_();
readRockCompactionParameters_();
// check the kind of region which is supposed to be used by checking the ROCKOPTS
// keyword. note that for some funny reason, the ROCK keyword uses PVTNUM by

View File

@ -443,7 +443,6 @@ namespace MissingFeatures {
"RADFIN4",
"RHO",
"RKTRMDIR",
"ROCKCOMP",
"ROCKOPTS",
"ROCKTAB",
"RPTGRID",