Merge pull request #3493 from goncalvesmachadoc/fsip

output FSIP
This commit is contained in:
Bård Skaflestad 2021-08-27 22:44:50 +02:00 committed by GitHub
commit aba95a8263
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 1 deletions

View File

@ -57,6 +57,7 @@ std::string EclString(Opm::Inplace::Phase phase) {
case Opm::Inplace::Phase::WaterResVolume: return "WIPR"; case Opm::Inplace::Phase::WaterResVolume: return "WIPR";
case Opm::Inplace::Phase::OilResVolume: return "OIPR"; case Opm::Inplace::Phase::OilResVolume: return "OIPR";
case Opm::Inplace::Phase::GasResVolume: return "GIPR"; case Opm::Inplace::Phase::GasResVolume: return "GIPR";
case Opm::Inplace::Phase::SALT: return "SIP";
default: throw std::logic_error("Phase not recognized"); default: throw std::logic_error("Phase not recognized");
} }
} }
@ -1051,6 +1052,7 @@ fipUnitConvert_(std::unordered_map<Inplace::Phase, Scalar>& fip) const
{Inplace::Phase::WaterResVolume, M::volume}, {Inplace::Phase::WaterResVolume, M::volume},
{Inplace::Phase::OilResVolume, M::volume}, {Inplace::Phase::OilResVolume, M::volume},
{Inplace::Phase::GasResVolume, M::volume}, {Inplace::Phase::GasResVolume, M::volume},
{Inplace::Phase::SALT, M::mass},
}; };
for (auto& [phase, value] : fip) { for (auto& [phase, value] : fip) {
@ -1621,6 +1623,7 @@ updateSummaryRegionValues(const Inplace& inplace,
inplace.get(Inplace::Phase::PoreVolume), inplace.get(Inplace::Phase::PoreVolume),
false); false);
} }
} }
// The region summary vectors should loop through the FIPxxx regions to // The region summary vectors should loop through the FIPxxx regions to

View File

@ -694,6 +694,9 @@ private:
if (FluidSystem::phaseIsActive(waterPhaseIdx) && !this->fip_[Inplace::Phase::WaterResVolume].empty()) if (FluidSystem::phaseIsActive(waterPhaseIdx) && !this->fip_[Inplace::Phase::WaterResVolume].empty())
this->fip_[Inplace::Phase::WaterResVolume][globalDofIdx] = fipr[waterPhaseIdx]; this->fip_[Inplace::Phase::WaterResVolume][globalDofIdx] = fipr[waterPhaseIdx];
if (FluidSystem::phaseIsActive(waterPhaseIdx) && !this->fip_[Inplace::Phase::SALT].empty())
this->fip_[Inplace::Phase::SALT][globalDofIdx] = fipr[waterPhaseIdx] * fs.saltConcentration().value();
// Store the pure oil and gas Fip // Store the pure oil and gas Fip
if (FluidSystem::phaseIsActive(oilPhaseIdx) && !this->fip_[Inplace::Phase::OilInLiquidPhase].empty()) if (FluidSystem::phaseIsActive(oilPhaseIdx) && !this->fip_[Inplace::Phase::OilInLiquidPhase].empty())
this->fip_[Inplace::Phase::OilInLiquidPhase][globalDofIdx] = fip[oilPhaseIdx]; this->fip_[Inplace::Phase::OilInLiquidPhase][globalDofIdx] = fip[oilPhaseIdx];