mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -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.useEnptvd(), comm) +
|
||||||
packSize(data.useEqlnum(), comm) +
|
packSize(data.useEqlnum(), comm) +
|
||||||
packSize(data.useJFunc(), comm) +
|
packSize(data.useJFunc(), comm) +
|
||||||
|
(data.useJFunc() ? packSize(data.getJFunc(), comm) : 0) +
|
||||||
packSize(data.OilDenT(), comm) +
|
packSize(data.OilDenT(), comm) +
|
||||||
packSize(data.GasDenT(), comm) +
|
packSize(data.GasDenT(), comm) +
|
||||||
packSize(data.WatDenT(), comm) +
|
packSize(data.WatDenT(), comm) +
|
||||||
(data.useJFunc() ? packSize(data.getJFunc(), comm) : 0) +
|
packSize(data.gas_comp_index(), comm) +
|
||||||
packSize(data.rtemp(), 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.useEnptvd(), buffer, position, comm);
|
||||||
pack(data.useEqlnum(), buffer, position, comm);
|
pack(data.useEqlnum(), buffer, position, comm);
|
||||||
pack(data.useJFunc(), 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.OilDenT(), buffer, position, comm);
|
||||||
pack(data.GasDenT(), buffer, position, comm);
|
pack(data.GasDenT(), buffer, position, comm);
|
||||||
pack(data.WatDenT(), buffer, position, comm);
|
pack(data.WatDenT(), buffer, position, comm);
|
||||||
if (data.useJFunc())
|
pack(data.gas_comp_index(), buffer, position, comm);
|
||||||
pack(data.getJFunc(), buffer, position, comm);
|
|
||||||
pack(data.rtemp(), 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 hasEntpvd;
|
||||||
bool hasEqlnum;
|
bool hasEqlnum;
|
||||||
DenT oilDenT, gasDenT, watDenT;
|
DenT oilDenT, gasDenT, watDenT;
|
||||||
|
std::size_t gas_comp_index;
|
||||||
std::shared_ptr<JFunc> jfunc;
|
std::shared_ptr<JFunc> jfunc;
|
||||||
double rtemp;
|
double rtemp;
|
||||||
unpack(simpleTables, buffer, position, comm);
|
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(hasImptvd, buffer, position, comm);
|
||||||
unpack(hasEntpvd, buffer, position, comm);
|
unpack(hasEntpvd, buffer, position, comm);
|
||||||
unpack(hasEqlnum, 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;
|
bool hasJf;
|
||||||
unpack(hasJf, buffer, position, comm);
|
unpack(hasJf, buffer, position, comm);
|
||||||
if (hasJf) {
|
if (hasJf) {
|
||||||
jfunc = std::make_shared<JFunc>();
|
jfunc = std::make_shared<JFunc>();
|
||||||
unpack(*jfunc, buffer, position, comm);
|
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);
|
unpack(rtemp, buffer, position, comm);
|
||||||
|
|
||||||
data = TableManager(simpleTables, pvtgTables, pvtoTables, rock2dTables,
|
data = TableManager(simpleTables, pvtgTables, pvtoTables, rock2dTables,
|
||||||
rock2dtrTables, pvtwTable, pvcdoTable, densityTable,
|
rock2dtrTables, pvtwTable, pvcdoTable, densityTable,
|
||||||
rockTable, viscrefTable, watdentTable, pvtwsaltTables,
|
rockTable, viscrefTable, watdentTable, pvtwsaltTables,
|
||||||
bdensityTables, plymwinjTables,
|
bdensityTables, plymwinjTables,
|
||||||
skprwatTables, skprpolyTables, tabdims, regdims, eqldims,
|
skprwatTables, skprpolyTables, tabdims, regdims, eqldims,
|
||||||
aqudims, hasImptvd, hasEntpvd, hasEqlnum, oilDenT, gasDenT,
|
aqudims, hasImptvd, hasEntpvd, hasEqlnum, jfunc, oilDenT, gasDenT,
|
||||||
watDenT, jfunc, rtemp);
|
watDenT, gas_comp_index, rtemp);
|
||||||
}
|
}
|
||||||
|
|
||||||
template<class Scalar>
|
template<class Scalar>
|
||||||
|
@ -1216,10 +1216,11 @@ BOOST_AUTO_TEST_CASE(TableManager)
|
|||||||
true,
|
true,
|
||||||
true,
|
true,
|
||||||
true,
|
true,
|
||||||
getDent(),
|
|
||||||
getDenT(),
|
|
||||||
getDenT(),
|
|
||||||
jfunc,
|
jfunc,
|
||||||
|
getDenT(),
|
||||||
|
getDenT(),
|
||||||
|
getDenT(),
|
||||||
|
77,
|
||||||
1.0);
|
1.0);
|
||||||
auto val2 = PackUnpack(val1);
|
auto val2 = PackUnpack(val1);
|
||||||
DO_CHECKS(TableManager)
|
DO_CHECKS(TableManager)
|
||||||
|
Loading…
Reference in New Issue
Block a user