mirror of
https://github.com/OPM/opm-simulators.git
synced 2024-12-29 10:40:59 -06:00
Serialize new member TableManager::gas_comp_index
This commit is contained in:
parent
2ce7b35e69
commit
d94943a741
@ -866,10 +866,11 @@ std::size_t packSize(const TableManager& data, Dune::MPIHelper::MPICommunicator
|
||||
packSize(data.useEnptvd(), comm) +
|
||||
packSize(data.useEqlnum(), comm) +
|
||||
packSize(data.useJFunc(), comm) +
|
||||
(data.useJFunc() ? packSize(data.getJFunc(), comm) : 0) +
|
||||
packSize(data.OilDenT(), comm) +
|
||||
packSize(data.GasDenT(), comm) +
|
||||
packSize(data.WatDenT(), comm) +
|
||||
(data.useJFunc() ? packSize(data.getJFunc(), comm) : 0) +
|
||||
packSize(data.gas_comp_index(), comm) +
|
||||
packSize(data.rtemp(), comm);
|
||||
}
|
||||
|
||||
@ -2714,11 +2715,12 @@ void pack(const TableManager& data, std::vector<char>& buffer, int& position,
|
||||
pack(data.useEnptvd(), buffer, position, comm);
|
||||
pack(data.useEqlnum(), buffer, position, comm);
|
||||
pack(data.useJFunc(), buffer, position, comm);
|
||||
if (data.useJFunc())
|
||||
pack(data.getJFunc(), buffer, position, comm);
|
||||
pack(data.OilDenT(), buffer, position, comm);
|
||||
pack(data.GasDenT(), buffer, position, comm);
|
||||
pack(data.WatDenT(), buffer, position, comm);
|
||||
if (data.useJFunc())
|
||||
pack(data.getJFunc(), buffer, position, comm);
|
||||
pack(data.gas_comp_index(), buffer, position, comm);
|
||||
pack(data.rtemp(), buffer, position, comm);
|
||||
}
|
||||
|
||||
@ -4845,6 +4847,7 @@ void unpack(TableManager& data, std::vector<char>& buffer, int& position,
|
||||
bool hasEntpvd;
|
||||
bool hasEqlnum;
|
||||
DenT oilDenT, gasDenT, watDenT;
|
||||
std::size_t gas_comp_index;
|
||||
std::shared_ptr<JFunc> jfunc;
|
||||
double rtemp;
|
||||
unpack(simpleTables, buffer, position, comm);
|
||||
@ -4870,23 +4873,25 @@ void unpack(TableManager& data, std::vector<char>& buffer, int& position,
|
||||
unpack(hasImptvd, buffer, position, comm);
|
||||
unpack(hasEntpvd, buffer, position, comm);
|
||||
unpack(hasEqlnum, buffer, position, comm);
|
||||
unpack(oilDenT, buffer, position, comm);
|
||||
unpack(gasDenT, buffer, position, comm);
|
||||
unpack(watDenT, buffer, position, comm);
|
||||
bool hasJf;
|
||||
unpack(hasJf, buffer, position, comm);
|
||||
if (hasJf) {
|
||||
jfunc = std::make_shared<JFunc>();
|
||||
unpack(*jfunc, buffer, position, comm);
|
||||
}
|
||||
unpack(oilDenT, buffer, position, comm);
|
||||
unpack(gasDenT, buffer, position, comm);
|
||||
unpack(watDenT, buffer, position, comm);
|
||||
unpack(gas_comp_index, buffer, position, comm);
|
||||
unpack(rtemp, buffer, position, comm);
|
||||
|
||||
data = TableManager(simpleTables, pvtgTables, pvtoTables, rock2dTables,
|
||||
rock2dtrTables, pvtwTable, pvcdoTable, densityTable,
|
||||
rockTable, viscrefTable, watdentTable, pvtwsaltTables,
|
||||
bdensityTables, plymwinjTables,
|
||||
skprwatTables, skprpolyTables, tabdims, regdims, eqldims,
|
||||
aqudims, hasImptvd, hasEntpvd, hasEqlnum, oilDenT, gasDenT,
|
||||
watDenT, jfunc, rtemp);
|
||||
aqudims, hasImptvd, hasEntpvd, hasEqlnum, jfunc, oilDenT, gasDenT,
|
||||
watDenT, gas_comp_index, rtemp);
|
||||
}
|
||||
|
||||
template<class Scalar>
|
||||
|
@ -1216,10 +1216,11 @@ BOOST_AUTO_TEST_CASE(TableManager)
|
||||
true,
|
||||
true,
|
||||
true,
|
||||
getDent(),
|
||||
getDenT(),
|
||||
getDenT(),
|
||||
jfunc,
|
||||
getDenT(),
|
||||
getDenT(),
|
||||
getDenT(),
|
||||
77,
|
||||
1.0);
|
||||
auto val2 = PackUnpack(val1);
|
||||
DO_CHECKS(TableManager)
|
||||
|
Loading…
Reference in New Issue
Block a user