mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Merge pull request #5236 from hnil/no_early_exit_zero_flux
Avoid deleting derivative i.e. getting "wrong" matrix in case of zero…
This commit is contained in:
commit
f47d00c9d7
@ -285,10 +285,6 @@ public:
|
|||||||
distZ*g,
|
distZ*g,
|
||||||
thpres,
|
thpres,
|
||||||
problem.moduleParams());
|
problem.moduleParams());
|
||||||
if (pressureDifferences[phaseIdx] == 0) {
|
|
||||||
volumeFlux[phaseIdx] = 0.0;
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
const bool upwindIsInterior = (static_cast<unsigned>(upIdx[phaseIdx]) == interiorDofIdx);
|
const bool upwindIsInterior = (static_cast<unsigned>(upIdx[phaseIdx]) == interiorDofIdx);
|
||||||
const IntensiveQuantities& up = upwindIsInterior ? intQuantsIn : intQuantsEx;
|
const IntensiveQuantities& up = upwindIsInterior ? intQuantsIn : intQuantsEx;
|
||||||
|
@ -137,7 +137,7 @@ add_test_compare_parallel_simulation(CASENAME aquflux_01
|
|||||||
FILENAME AQUFLUX-01
|
FILENAME AQUFLUX-01
|
||||||
SIMULATOR flow
|
SIMULATOR flow
|
||||||
ABS_TOL ${abs_tol}
|
ABS_TOL ${abs_tol}
|
||||||
REL_TOL 0.04
|
REL_TOL 0.06
|
||||||
DIR aquifers
|
DIR aquifers
|
||||||
TEST_ARGS --enable-tuning=true --enable-drift-compensation=false --relaxed-max-pv-fraction=0.0 --tolerance-cnv=1.0e-3)
|
TEST_ARGS --enable-tuning=true --enable-drift-compensation=false --relaxed-max-pv-fraction=0.0 --tolerance-cnv=1.0e-3)
|
||||||
|
|
||||||
|
@ -30,7 +30,7 @@ class TestBasic(unittest.TestCase):
|
|||||||
rho_g = sim.get_fluidstate_variable(name='rho_g')
|
rho_g = sim.get_fluidstate_variable(name='rho_g')
|
||||||
self.assertAlmostEqual(rho_g[0], 241.36955087, places=2, msg='value of gas density')
|
self.assertAlmostEqual(rho_g[0], 241.36955087, places=2, msg='value of gas density')
|
||||||
rho_o = sim.get_fluidstate_variable(name='rho_o')
|
rho_o = sim.get_fluidstate_variable(name='rho_o')
|
||||||
self.assertAlmostEqual(rho_o[0], 631.78611238, places=3, msg='value of oil density')
|
self.assertAlmostEqual(rho_o[0], 631.78674, places=2, msg='value of oil density')
|
||||||
Rs = sim.get_fluidstate_variable(name='Rs')
|
Rs = sim.get_fluidstate_variable(name='Rs')
|
||||||
self.assertAlmostEqual(Rs[0], 226.19666048, places=5, msg='value of solution gas-oil ratio')
|
self.assertAlmostEqual(Rs[0], 226.19666048, places=5, msg='value of solution gas-oil ratio')
|
||||||
Rv = sim.get_fluidstate_variable(name='Rv')
|
Rv = sim.get_fluidstate_variable(name='Rv')
|
||||||
@ -38,8 +38,8 @@ class TestBasic(unittest.TestCase):
|
|||||||
Sw = sim.get_fluidstate_variable(name='Sw')
|
Sw = sim.get_fluidstate_variable(name='Sw')
|
||||||
self.assertAlmostEqual(Sw[0], 0.11969486712, places=5, msg='value of water saturation')
|
self.assertAlmostEqual(Sw[0], 0.11969486712, places=5, msg='value of water saturation')
|
||||||
So = sim.get_fluidstate_variable(name='So')
|
So = sim.get_fluidstate_variable(name='So')
|
||||||
self.assertAlmostEqual(So[0], 0.825166164326, places=5, msg='value of oil saturation')
|
self.assertAlmostEqual(So[0], 0.825129, places=3, msg='value of oil saturation')
|
||||||
Sg = sim.get_fluidstate_variable(name='Sg')
|
Sg = sim.get_fluidstate_variable(name='Sg')
|
||||||
self.assertAlmostEqual(Sg[0], 0.055138968544, places=5, msg='value of gas saturation')
|
self.assertAlmostEqual(Sg[0], 0.055138968544, places=3, msg='value of gas saturation')
|
||||||
T = sim.get_fluidstate_variable(name='T')
|
T = sim.get_fluidstate_variable(name='T')
|
||||||
self.assertAlmostEqual(T[0], 288.705, places=3, msg='value of temperature')
|
self.assertAlmostEqual(T[0], 288.705, places=3, msg='value of temperature')
|
||||||
|
Loading…
Reference in New Issue
Block a user