diff --git a/CMakeLists_files.cmake b/CMakeLists_files.cmake index 42aa9aa84..62a0ca40d 100644 --- a/CMakeLists_files.cmake +++ b/CMakeLists_files.cmake @@ -212,9 +212,9 @@ list (APPEND TEST_DATA_FILES tests/deadfluids.DATA tests/equil_wetgas.DATA tests/equil_liveoil.DATA - tests/equil_rsvd_and_rvvd.DATA - tests/equil_rvvd_and_rvwvd.DATA tests/equil_humidwetgas.DATA + tests/equil_rsvd_and_rvvd.DATA + tests/equil_rsvd_rvvd_and_rvwvd.DATA tests/wetgas.DATA tests/satfuncEPS_B.DATA tests/wells_manager_data.data diff --git a/tests/equil_humidwetgas.DATA b/tests/equil_humidwetgas.DATA index 382b8745e..c9ccd506f 100644 --- a/tests/equil_humidwetgas.DATA +++ b/tests/equil_humidwetgas.DATA @@ -1,12 +1,12 @@ -NOECHO +NNOECHO RUNSPEC ====== WATER OIL GAS -VAPWAT VAPOIL +VAPWAT TABDIMS 1 1 40 20 1 20 / @@ -79,7 +79,7 @@ PVDO / PVTG --- Pg Rv Bg mug +-- Pg Rv Bg Vg 100 0.0001 0.010 0.1 0.0 0.0104 0.1 / 200 0.0004 0.005 0.2 @@ -87,7 +87,7 @@ PVTG / PVTGW --- Pg Rvw Bg mug +-- Pg Rvw Bg Vg 100 0.0001 0.010 0.1 0.0 0.0104 0.1 / 200 0.0004 0.005 0.2 @@ -118,8 +118,9 @@ DENSITY / SOLUTION ====== + EQUIL - 45 150 45 0.25 45 0.35 1* 1* 0 1* 1* 1* +45 150 50 0.25 45 0.35 1* 1* 0 / RPTSOL diff --git a/tests/equil_rvvd_and_rvwvd.DATA b/tests/equil_rsvd_rvvd_and_rvwvd.DATA similarity index 57% rename from tests/equil_rvvd_and_rvwvd.DATA rename to tests/equil_rsvd_rvvd_and_rvwvd.DATA index d4f7c04bd..8469b597d 100644 --- a/tests/equil_rvvd_and_rvwvd.DATA +++ b/tests/equil_rsvd_rvvd_and_rvwvd.DATA @@ -1,12 +1,13 @@ -NOECHO +NNOECHO RUNSPEC ====== WATER OIL GAS -VAPWAT +DISGAS VAPOIL +VAPWAT TABDIMS 1 1 40 20 1 20 / @@ -73,12 +74,22 @@ TOPS PROPS ====== -PVDO -100 1.0 1.0 -200 0.9 1.0 +PVTO +-- Rs Pbub Bo Vo + 0 1. 1.0000 1.20 / + 20 40. 1.0120 1.17 / + 40 80. 1.0255 1.14 / + 60 120. 1.0380 1.11 / + 80 160. 1.0510 1.08 / + 100 200. 1.0630 1.06 / + 120 240. 1.0750 1.03 / + 140 280. 1.0870 1.00 / + 160 320. 1.0985 .98 / + 180 360. 1.1100 .95 / + 200 400. 1.1200 .94 + 500. 1.1189 .94 / / - PVTG -- Pg Rv Bg Vg 100 0.0001 0.010 0.1 @@ -88,7 +99,7 @@ PVTG / PVTGW --- Pg Rvw Bg mug +-- Pg Rvw Bg Vg 100 0.0001 0.010 0.1 0.0 0.0104 0.1 / 200 0.0004 0.005 0.2 @@ -128,12 +139,16 @@ RSVD 0 0.0 100 100. / +RVVD + 0. 0. + 100. 0.0001 / + RVWVD - 0 0.0 - 100 100. / + 0. 0. + 100. 0.0001 / RPTSOL -'PRES' 'PGAS' 'PWAT' 'SOIL' 'SWAT' 'SGAS' 'RV' 'RVW' 'RESTART=2' / +'PRES' 'PGAS' 'PWAT' 'SOIL' 'SWAT' 'SGAS' 'RS' 'RV' 'RVW' 'RESTART=2' / SUMMARY ====== RUNSUM @@ -146,7 +161,7 @@ TSTEP 1 / RPTSCHED -'PRES' 'PGAS' 'PWAT' 'SOIL' 'SWAT' 'SGAS' 'RV' 'RVW' 'RESTART=3' 'NEWTON=2' / +'PRES' 'PGAS' 'PWAT' 'SOIL' 'SWAT' 'SGAS' 'RS' 'RV' 'RVW' 'RESTART=3' 'NEWTON=2' / END \ No newline at end of file diff --git a/tests/test_equil.cc b/tests/test_equil.cc index 036eb249f..b56eadc6f 100644 --- a/tests/test_equil.cc +++ b/tests/test_equil.cc @@ -858,12 +858,11 @@ BOOST_AUTO_TEST_CASE(DeckWithWetGas) } } -//TODO Find corret values BOOST_AUTO_TEST_CASE(DeckWithHumidWetGas) { using TypeTag = Opm::Properties::TTag::TestEquilTypeTag; using FluidSystem = Opm::GetPropType; - auto simulator = initSimulator("equil_humidawetgas.DATA"); + auto simulator = initSimulator("equil_humidwetgas.DATA"); const auto& eclipseState = simulator->vanguard().eclState(); Opm::GridManager gm(eclipseState.getInputGrid()); const UnstructuredGrid& grid = *(gm.c_grid()); @@ -879,14 +878,12 @@ BOOST_AUTO_TEST_CASE(DeckWithHumidWetGas) const int first = 0, last = grid.number_of_cells - 1; const double reltol = 1.0e-1; - BOOST_CHECK_CLOSE(pressures[FluidSystem::waterPhaseIdx][first], 1.482150311e7, reltol); BOOST_CHECK_CLOSE(pressures[FluidSystem::waterPhaseIdx][last], 1.547988347e7, reltol); BOOST_CHECK_CLOSE(pressures[FluidSystem::oilPhaseIdx][first], 1.491150311e7, reltol); BOOST_CHECK_CLOSE(pressures[FluidSystem::oilPhaseIdx][last], 1.548988347e7, reltol); const auto& sats = comp.saturation(); - std::vector s_opm[3]; s_opm[FluidSystem::waterPhaseIdx] = { 0.2, 0.2, 0.2, 0.2, 0.2, 0.2, 0.2, 0.24310545, 0.5388, 0.78458, 0.91540, 1, 1, 1, 1, 1, 1, 1, 1, 1 }; s_opm[FluidSystem::oilPhaseIdx] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.18288667, 0.0846, 0, 0, 0, 0, 0, 0, 0, 0, 0 }; @@ -900,14 +897,15 @@ BOOST_AUTO_TEST_CASE(DeckWithHumidWetGas) } const auto& rv = comp.rv(); - const auto& rvw = comp.rvw(); const std::vector rv_opm { 2.4884509e-4, 2.4910378e-4, 2.4936267e-4, 2.4962174e-4, 2.4988100e-4, 2.5014044e-4, 2.5040008e-4, 2.5065990e-4, 2.5091992e-4, 2.5118012e-4, 2.5223082e-4, 2.5105e-4, 2.5105e-4, 2.5105e-4, 2.5105e-4, 2.5105e-4, 2.5105e-4, 2.5105e-4, 2.5105e-4, 2.5105e-4}; - const std::vector rvw_opm { + + const auto& rvw = comp.rvw(); + const std::vector rvw_opm { 2.4884509e-4, 2.4910378e-4, 2.4936267e-4, 2.4962174e-4, 2.4988100e-4, 2.5014044e-4, 2.5040008e-4, 2.5065990e-4, 2.5091992e-4, 2.5118012e-4, 2.5223082e-4, 2.5105e-4, @@ -1116,11 +1114,11 @@ BOOST_AUTO_TEST_CASE(DeckWithPBVDAndPDVD) } } -BOOST_AUTO_TEST_CASE(DeckWithRVVDAndRVWVD) +BOOST_AUTO_TEST_CASE(DeckWithRSVDAndRVVDAndRVWVD) { using TypeTag = Opm::Properties::TTag::TestEquilTypeTag; using FluidSystem = Opm::GetPropType; - auto simulator = initSimulator("equil_rvvd_and_rvwvd.DATA"); + auto simulator = initSimulator("equil_rsvd_and_rvvd_and_rvwvd.DATA"); const auto& eclipseState = simulator->vanguard().eclState(); Opm::GridManager gm(eclipseState.getInputGrid()); const UnstructuredGrid& grid = *(gm.c_grid()); @@ -1136,14 +1134,12 @@ BOOST_AUTO_TEST_CASE(DeckWithRVVDAndRVWVD) const int first = 0, last = grid.number_of_cells - 1; const double reltol = 1.0e-4; - - BOOST_CHECK_CLOSE(pressures[FluidSystem::waterPhaseIdx][first], 1.483499660e7, reltol); // opm + BOOST_CHECK_CLOSE(pressures[FluidSystem::waterPhaseIdx][first], 1.483499660e7, reltol); BOOST_CHECK_CLOSE(pressures[FluidSystem::waterPhaseIdx][last], 1.547924516e7, reltol); BOOST_CHECK_CLOSE(pressures[FluidSystem::oilPhaseIdx][first], 1.492499660e7, reltol); BOOST_CHECK_CLOSE(pressures[FluidSystem::oilPhaseIdx][last], 1.548924516e7, reltol); - const auto& sats = comp.saturation(); - + const auto& sats = comp.saturation(); std::vector s_opm[3]; s_opm[FluidSystem::waterPhaseIdx] = { 0.2, 0.2, 0.2, 0.2, 0.2, 0.2, 0.2, 0.2223045711692897, 0.52882298575945874, 0.78152142505479982, 0.91816512259416283, 1, 1, 1, 1, 1, 1, 1, 1, 1 }; s_opm[FluidSystem::oilPhaseIdx] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.19637607881498206, 0.08183487740583717, 0, 0, 0, 0, 0, 0, 0, 0, 0 }; @@ -1157,8 +1153,8 @@ BOOST_AUTO_TEST_CASE(DeckWithRVVDAndRVWVD) std::cout << std::endl; } - const auto& rvw = comp.rvw(); - const std::vector rvw_opm { + const auto& rs = comp.rs(); + const std::vector rs_opm { // opm 74.62498302, 74.65959041, 74.69438035, 74.72935336, 74.76450995, 74.79985061, 74.83537588, 74.87527065, 74.96863769, 75.08891765, 52.5, 57.5, @@ -1173,14 +1169,21 @@ BOOST_AUTO_TEST_CASE(DeckWithRVVDAndRVWVD) 6.25e-5, 6.75e-5, 7.25e-5, 7.75e-5, 8.25e-5, 8.75e-5, 9.25e-5, 9.75e-5}; + const auto& rvw = comp.rvw(); + const std::vector rvw_opm { + 2.50e-6, 7.50e-6, 1.25e-5, 1.75e-5, + 2.25e-5, 2.75e-5, 3.25e-5, 3.75e-5, + 4.25e-5, 2.51158386e-4, 2.52203372e-4, 5.75e-5, + 6.25e-5, 6.75e-5, 7.25e-5, 7.75e-5, + 8.25e-5, 8.75e-5, 9.25e-5, 9.75e-5}; + for (size_t i = 0; i < rv_opm.size(); ++i) { - BOOST_CHECK_CLOSE(rvw[i], rvw_opm[i], reltol); + BOOST_CHECK_CLOSE(rs[i], rs_opm[i], reltol); BOOST_CHECK_CLOSE(rv[i], rv_opm[i], reltol); + BOOST_CHECK_CLOSE(rvw[i], rvw_opm[i], reltol); } } -//Both equil cases with TODO RS, RV and RVW - BOOST_AUTO_TEST_CASE(DeckWithSwatinit) { #if 0