mirror of
https://github.com/OPM/opm-simulators.git
synced 2024-12-30 11:06:55 -06:00
flow_ebos: make the FIP code consistent with flow_legacy
in particular, the rock compressibility effects are not considered in the FIP numbers anymore. While I'm not sure if this is correct or not, it at least makes the results consistent with those produced by 'flow_legacy'.
This commit is contained in:
parent
6949de699f
commit
76a825f36d
@ -1027,12 +1027,14 @@ namespace Opm {
|
||||
const unsigned cellIdx = elemCtx.globalSpaceIndex(/*spaceIdx=*/0, /*timeIdx=*/0);
|
||||
const auto& intQuants = elemCtx.intensiveQuantities(/*spaceIdx=*/0, /*timeIdx=*/0);
|
||||
const auto& fs = intQuants.fluidState();
|
||||
const double pv =
|
||||
ebosSimulator_.model().dofTotalVolume(cellIdx)
|
||||
* ebosSimulator_.problem().porosity(cellIdx);
|
||||
|
||||
for (int phase = 0; phase < maxnp; ++phase) {
|
||||
const double b = fs.invB(flowPhaseToEbosPhaseIdx(phase)).value();
|
||||
const double s = fs.saturation(flowPhaseToEbosPhaseIdx(phase)).value();
|
||||
|
||||
const double pv = intQuants.porosity().value()*elemCtx.dofVolume(/*spaceIdx=*/0, /*timeIdx=*/0);
|
||||
fip_.fip[phase][cellIdx] = b * s * pv;
|
||||
}
|
||||
|
||||
@ -1081,7 +1083,9 @@ namespace Opm {
|
||||
const auto& intQuants = *ebosSimulator_.model().cachedIntensiveQuantities(c, /*timeIdx=*/0);
|
||||
const auto& fs = intQuants.fluidState();
|
||||
const double hydrocarbon = fs.saturation(FluidSystem::oilPhaseIdx).value() + fs.saturation(FluidSystem::gasPhaseIdx).value();
|
||||
const double pv = intQuants.porosity().value()*elemCtx.dofVolume(/*spaceIdx=*/0, /*timeIdx=*/0);
|
||||
const double pv =
|
||||
ebosSimulator_.model().dofTotalVolume(c)
|
||||
* ebosSimulator_.problem().porosity(c);
|
||||
hcpv[region] += pv * hydrocarbon;
|
||||
pres[region] += pv * fs.pressure(FluidSystem::oilPhaseIdx).value();
|
||||
}
|
||||
@ -1091,7 +1095,9 @@ namespace Opm {
|
||||
if (region != -1) {
|
||||
const auto& intQuants = *ebosSimulator_.model().cachedIntensiveQuantities(c, /*timeIdx=*/0);
|
||||
const auto& fs = intQuants.fluidState();
|
||||
const double pv = intQuants.porosity().value()*elemCtx.dofVolume(/*spaceIdx=*/0, /*timeIdx=*/0);
|
||||
const double pv =
|
||||
ebosSimulator_.model().dofTotalVolume(c)
|
||||
* ebosSimulator_.problem().porosity(c);
|
||||
fip_.fip[FIPDataType::FIP_PV][c] = pv;
|
||||
const double hydrocarbon = fs.saturation(FluidSystem::oilPhaseIdx).value() + fs.saturation(FluidSystem::gasPhaseIdx).value();
|
||||
|
||||
@ -1151,7 +1157,9 @@ namespace Opm {
|
||||
const auto& intQuants = *ebosSimulator_.model().cachedIntensiveQuantities(c, /*timeIdx=*/0);
|
||||
const auto& fs = intQuants.fluidState();
|
||||
const double hydrocarbon = fs.saturation(FluidSystem::oilPhaseIdx).value() + fs.saturation(FluidSystem::gasPhaseIdx).value();
|
||||
const double pv = intQuants.porosity().value()*elemCtx.dofVolume(/*spaceIdx=*/0, /*timeIdx=*/0);
|
||||
const double pv =
|
||||
ebosSimulator_.model().dofTotalVolume(c)
|
||||
* ebosSimulator_.problem().porosity(c);
|
||||
hcpv[region] += pv * hydrocarbon;
|
||||
pres[region] += pv * fs.pressure(FluidSystem::oilPhaseIdx).value();
|
||||
}
|
||||
@ -1166,7 +1174,9 @@ namespace Opm {
|
||||
const auto& intQuants = *ebosSimulator_.model().cachedIntensiveQuantities(c, /*timeIdx=*/0);
|
||||
const auto& fs = intQuants.fluidState();
|
||||
const double hydrocarbon = fs.saturation(FluidSystem::oilPhaseIdx).value() + fs.saturation(FluidSystem::gasPhaseIdx).value();
|
||||
const double pv = intQuants.porosity().value()*elemCtx.dofVolume(/*spaceIdx=*/0, /*timeIdx=*/0);
|
||||
const double pv =
|
||||
ebosSimulator_.model().dofTotalVolume(c)
|
||||
* ebosSimulator_.problem().porosity(c);
|
||||
fip_.fip[FIPDataType::FIP_PV][c] = pv;
|
||||
|
||||
if (hcpv[region] != 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user