This commit removes the restriction that cumulative totals are not
output in the case of creating OPM Extended Restart files. There
was a reason why we did not do this when the new restart facility
was introduced, but that reason no longer applies.
This commit expands the private member function
Tables::addGasPVTTables(const EclipseState&)
to create structurally correct TAB vector entries from the PVTG
(wet gas) input table data when gas is an active phase in a
simulation run. Specifically, the main result array has the columns
[ Rv, 1/Bg, 1/(Bg*mu_g), d(1/Bg)/dRv, d(1/(Bg*mu_g))/dRv ]
and the ancillary table (base pointer JBPVTG) holds the gas pressure
nodes.
Note that while we do create structurally correct output tables, we
do not fill in undersaturated states that have been defaulted in the
input table.
The number of table rows in the main table is equal to number of PVT
regions times the number of declared pressure nodes (TABDIMS item 4,
NPPVT) times the number of declared composition nodes (TABDIMS item
6, NRPVT). In other words, the main result array is expanded to
fill NRPVT rows per gas pressure node per PVT region. Fill value
-2.0e+20. We have verified the results with ECLIPSE 100. The
ancillary table is expanded to the number of declared pressure nodes
for each PVT region. Here the fill value is +2.0e+20.
As an OPM extension, we will use the maximum number of active
composition and pressure nodes across all PVTG tables if the
declared maximum pressure nodes in TABDIMS is too small. This will
create TAB vector representations that are not compatible with
ECLIPSE, but which will nevertheless be useful in the context of
ResInsight's flux calculation.
Add unit tests for all gas-related PVT tables.
This commit expands the private member function
Tables::addOilPVTTables(const EclipseState&)
to create structurally correct TAB vector entries from the PVTO
(live oil) input table data when oil is an active phase in a
simulation run. Specifically, the main result array has the columns
[ Po, 1/Bo, 1/(Bo*mu_o), d(1/Bo)/dPo, d(1/(Bo*mu_o))/dPo ]
and the ancillary table (base pointer JBPVTO) holds the composition
nodes.
Note that while we do create structurally correct output tables, we
do not fill in undersaturated states that have been defaulted in the
input table.
The number of table rows in the main table is equal to number of PVT
regions times the number of declared composition nodes (TABDIMS item
6, NRPVT) times the number of declared pressure nodes (TABDIMS item
4, NPPVT). In other words, the main result array is expanded to
fill NPPVT rows per Rs node per PVT region. Fill value +2.0e+20.
We have verified the results with ECLIPSE 100. The ancillary table
is expanded to number of declared composition nodes for each PVT
region. Fill value +2.0e+20.
As an OPM extension, we will use the maximum number of active
pressure and composition nodes across all PVTO tables if the
declared maximum pressure nodes in TABDIMS is too small. This will
create a TAB vector representations that are not compatible with
ECLIPSE, but which will nevertheless be useful in the context of
ResInsight's flux calculation.
Add unit tests for all supported oil-related PVT tables.
This commit adds a new public member function
Tables::addPVTTables(const EclipseState&)
that calls into a new private member function
Tables::addWaterPVTTables(const EclipseState&)
to create structurally correct TAB vector entries from the PVTW
input table data when water is an active phase in a simulation run.
Specifically, the result array has the columns
[ Pw, 1/Bw, Cw, 1/(Bw * mu_w), Cw - Cv ]
in which 'Cw' denotes the water compressibility and 'Cv' denotes the
water viscosibility. Column 4 and 5 follow ECLIPSE 100 conventions.
Number of table rows equal to number of PVT regions. This result
array differs from the existing Tables::addPVTW() member function in
the treatment of viscosity and viscosibility data. We have verified
the results with ECLIPSE 100.
At present the function is not called by Flow's INIT file writer.
Add a unit test to exercise the new member function.
Reimplement original constructor in terms of the new constructor.
The main purpose of the new constructor is to support PVT tables
which use a fill/padding value different from 1.0e+20.
Differentiate between the input type, as specified in the json configuration
file, and the internal native type used to store data. This is a many-to-one
mapping, where e.g. both the input types STRING and RAW_STRING map to the
internal datatype std::string.
Additional changes:
- Have removed several ParserItem() constructors.
- The size_type::SINGLE is default for a ParserItem, and not set explicitly in
the generated ParserKeywords.cpp file.
- Have removed a call to boost::lexical_cast<> - just use std::to_string()