mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
add mpi serialization for PlmixparTable
This commit is contained in:
parent
27f52d5aa6
commit
579dbe73c1
@ -459,6 +459,7 @@ HANDLE_AS_POD(DENSITYRecord)
|
|||||||
HANDLE_AS_POD(DenT::entry)
|
HANDLE_AS_POD(DenT::entry)
|
||||||
HANDLE_AS_POD(Eqldims)
|
HANDLE_AS_POD(Eqldims)
|
||||||
HANDLE_AS_POD(MLimits)
|
HANDLE_AS_POD(MLimits)
|
||||||
|
HANDLE_AS_POD(PlmixparRecord)
|
||||||
HANDLE_AS_POD(PVTWRecord)
|
HANDLE_AS_POD(PVTWRecord)
|
||||||
HANDLE_AS_POD(PVCDORecord)
|
HANDLE_AS_POD(PVCDORecord)
|
||||||
HANDLE_AS_POD(Regdims)
|
HANDLE_AS_POD(Regdims)
|
||||||
@ -863,6 +864,7 @@ std::size_t packSize(const TableManager& data, Dune::MPIHelper::MPICommunicator
|
|||||||
packSize(data.getPvcdoTable(), comm) +
|
packSize(data.getPvcdoTable(), comm) +
|
||||||
packSize(data.getDensityTable(), comm) +
|
packSize(data.getDensityTable(), comm) +
|
||||||
packSize(data.getRockTable(), comm) +
|
packSize(data.getRockTable(), comm) +
|
||||||
|
packSize(data.getPlmixparTable(), comm) +
|
||||||
packSize(data.getTlmixparTable(), comm) +
|
packSize(data.getTlmixparTable(), comm) +
|
||||||
packSize(data.getViscrefTable(), comm) +
|
packSize(data.getViscrefTable(), comm) +
|
||||||
packSize(data.getWatdentTable(), comm) +
|
packSize(data.getWatdentTable(), comm) +
|
||||||
@ -1826,6 +1828,11 @@ std::size_t packSize(const TlmixparTable& data, Dune::MPIHelper::MPICommunicator
|
|||||||
return packSize(static_cast<const std::vector<TlmixparRecord>&>(data), comm);
|
return packSize(static_cast<const std::vector<TlmixparRecord>&>(data), comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::size_t packSize(const PlmixparTable& data, Dune::MPIHelper::MPICommunicator comm)
|
||||||
|
{
|
||||||
|
return packSize(static_cast<const std::vector<PlmixparRecord>&>(data), comm);
|
||||||
|
}
|
||||||
|
|
||||||
////// pack routines
|
////// pack routines
|
||||||
|
|
||||||
template<class T>
|
template<class T>
|
||||||
@ -2504,6 +2511,7 @@ void pack(const TableManager& data, std::vector<char>& buffer, int& position,
|
|||||||
pack(data.getPvcdoTable(), buffer, position, comm);
|
pack(data.getPvcdoTable(), buffer, position, comm);
|
||||||
pack(data.getDensityTable(), buffer, position, comm);
|
pack(data.getDensityTable(), buffer, position, comm);
|
||||||
pack(data.getRockTable(), buffer, position, comm);
|
pack(data.getRockTable(), buffer, position, comm);
|
||||||
|
pack(data.getPlmixparTable(), buffer, position, comm);
|
||||||
pack(data.getTlmixparTable(), buffer, position, comm);
|
pack(data.getTlmixparTable(), buffer, position, comm);
|
||||||
pack(data.getViscrefTable(), buffer, position, comm);
|
pack(data.getViscrefTable(), buffer, position, comm);
|
||||||
pack(data.getWatdentTable(), buffer, position, comm);
|
pack(data.getWatdentTable(), buffer, position, comm);
|
||||||
@ -3534,6 +3542,12 @@ void pack(const TlmixparTable& data, std::vector<char>& buffer, int& position,
|
|||||||
pack(static_cast<const std::vector<TlmixparRecord>&>(data), buffer, position, comm);
|
pack(static_cast<const std::vector<TlmixparRecord>&>(data), buffer, position, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void pack(const PlmixparTable& data, std::vector<char>& buffer, int& position,
|
||||||
|
Dune::MPIHelper::MPICommunicator comm)
|
||||||
|
{
|
||||||
|
pack(static_cast<const std::vector<PlmixparRecord>&>(data), buffer, position, comm);
|
||||||
|
}
|
||||||
|
|
||||||
/// unpack routines
|
/// unpack routines
|
||||||
|
|
||||||
template<class T>
|
template<class T>
|
||||||
@ -4439,6 +4453,7 @@ void unpack(TableManager& data, std::vector<char>& buffer, int& position,
|
|||||||
DensityTable densityTable;
|
DensityTable densityTable;
|
||||||
RockTable rockTable;
|
RockTable rockTable;
|
||||||
ViscrefTable viscrefTable;
|
ViscrefTable viscrefTable;
|
||||||
|
PlmixparTable plmixparTable;
|
||||||
TlmixparTable tlmixparTable;
|
TlmixparTable tlmixparTable;
|
||||||
WatdentTable watdentTable;
|
WatdentTable watdentTable;
|
||||||
std::vector<PvtwsaltTable> pvtwsaltTables;
|
std::vector<PvtwsaltTable> pvtwsaltTables;
|
||||||
@ -4468,6 +4483,7 @@ void unpack(TableManager& data, std::vector<char>& buffer, int& position,
|
|||||||
unpack(pvcdoTable, buffer, position, comm);
|
unpack(pvcdoTable, buffer, position, comm);
|
||||||
unpack(densityTable, buffer, position, comm);
|
unpack(densityTable, buffer, position, comm);
|
||||||
unpack(rockTable, buffer, position, comm);
|
unpack(rockTable, buffer, position, comm);
|
||||||
|
unpack(plmixparTable, buffer, position, comm);
|
||||||
unpack(tlmixparTable, buffer, position, comm);
|
unpack(tlmixparTable, buffer, position, comm);
|
||||||
unpack(viscrefTable, buffer, position, comm);
|
unpack(viscrefTable, buffer, position, comm);
|
||||||
unpack(watdentTable, buffer, position, comm);
|
unpack(watdentTable, buffer, position, comm);
|
||||||
@ -4499,10 +4515,11 @@ void unpack(TableManager& data, std::vector<char>& buffer, int& position,
|
|||||||
|
|
||||||
data = TableManager(simpleTables, pvtgTables, pvtoTables, rock2dTables,
|
data = TableManager(simpleTables, pvtgTables, pvtoTables, rock2dTables,
|
||||||
rock2dtrTables, pvtwTable, pvcdoTable, densityTable,
|
rock2dtrTables, pvtwTable, pvcdoTable, densityTable,
|
||||||
rockTable, tlmixparTable, viscrefTable, watdentTable, pvtwsaltTables,
|
rockTable, plmixparTable, tlmixparTable, viscrefTable,
|
||||||
bdensityTables, sdensityTables, plymwinjTables,
|
watdentTable, pvtwsaltTables, bdensityTables, sdensityTables,
|
||||||
skprwatTables, skprpolyTables, tabdims, regdims, eqldims,
|
plymwinjTables, skprwatTables, skprpolyTables, tabdims,
|
||||||
aqudims, hasImptvd, hasEntpvd, hasEqlnum, jfunc, oilDenT, gasDenT,
|
regdims, eqldims, aqudims, hasImptvd, hasEntpvd, hasEqlnum,
|
||||||
|
jfunc, oilDenT, gasDenT,
|
||||||
watDenT, stcond, gas_comp_index, rtemp);
|
watDenT, stcond, gas_comp_index, rtemp);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -5954,6 +5971,14 @@ void unpack(TlmixparTable& data, std::vector<char>& buffer, int& position,
|
|||||||
data = TlmixparTable(pdata);
|
data = TlmixparTable(pdata);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void unpack(PlmixparTable& data, std::vector<char>& buffer, int& position,
|
||||||
|
Dune::MPIHelper::MPICommunicator comm)
|
||||||
|
{
|
||||||
|
std::vector<PlmixparRecord> pdata;
|
||||||
|
unpack(pdata, buffer, position, comm);
|
||||||
|
data = PlmixparTable(pdata);
|
||||||
|
}
|
||||||
|
|
||||||
#define INSTANTIATE_PACK_VECTOR(...) \
|
#define INSTANTIATE_PACK_VECTOR(...) \
|
||||||
template std::size_t packSize(const std::vector<__VA_ARGS__>& data, \
|
template std::size_t packSize(const std::vector<__VA_ARGS__>& data, \
|
||||||
Dune::MPIHelper::MPICommunicator comm); \
|
Dune::MPIHelper::MPICommunicator comm); \
|
||||||
|
@ -113,6 +113,8 @@ class PolyInjTable;
|
|||||||
class PVCDORecord;
|
class PVCDORecord;
|
||||||
class PvcdoTable;
|
class PvcdoTable;
|
||||||
class PolymerConfig;
|
class PolymerConfig;
|
||||||
|
class PlmixparRecord;
|
||||||
|
class PlmixparTable;
|
||||||
class PvtgTable;
|
class PvtgTable;
|
||||||
class PvtoTable;
|
class PvtoTable;
|
||||||
class PVTWRecord;
|
class PVTWRecord;
|
||||||
@ -563,6 +565,8 @@ ADD_PACK_PROTOTYPES(NNC)
|
|||||||
ADD_PACK_PROTOTYPES(NNCdata)
|
ADD_PACK_PROTOTYPES(NNCdata)
|
||||||
ADD_PACK_PROTOTYPES(OilVaporizationProperties)
|
ADD_PACK_PROTOTYPES(OilVaporizationProperties)
|
||||||
ADD_PACK_PROTOTYPES(Phases)
|
ADD_PACK_PROTOTYPES(Phases)
|
||||||
|
ADD_PACK_PROTOTYPES(PlmixparRecord)
|
||||||
|
ADD_PACK_PROTOTYPES(PlmixparTable)
|
||||||
ADD_PACK_PROTOTYPES(PlymwinjTable)
|
ADD_PACK_PROTOTYPES(PlymwinjTable)
|
||||||
ADD_PACK_PROTOTYPES(PolyInjTable)
|
ADD_PACK_PROTOTYPES(PolyInjTable)
|
||||||
ADD_PACK_PROTOTYPES(PolymerConfig)
|
ADD_PACK_PROTOTYPES(PolymerConfig)
|
||||||
|
@ -1220,6 +1220,7 @@ BOOST_AUTO_TEST_CASE(TableManager)
|
|||||||
Opm::PvcdoTable({Opm::PVCDORecord{1.0, 2.0, 3.0, 4.0, 5.0}}),
|
Opm::PvcdoTable({Opm::PVCDORecord{1.0, 2.0, 3.0, 4.0, 5.0}}),
|
||||||
Opm::DensityTable({Opm::DENSITYRecord{1.0, 2.0, 3.0}}),
|
Opm::DensityTable({Opm::DENSITYRecord{1.0, 2.0, 3.0}}),
|
||||||
Opm::RockTable({Opm::ROCKRecord{1.0,2.0}}),
|
Opm::RockTable({Opm::ROCKRecord{1.0,2.0}}),
|
||||||
|
Opm::PlmixparTable({Opm::PlmixparRecord{1.0}}),
|
||||||
Opm::TlmixparTable({Opm::TlmixparRecord{1.0, 2.0}}),
|
Opm::TlmixparTable({Opm::TlmixparRecord{1.0, 2.0}}),
|
||||||
Opm::ViscrefTable({Opm::VISCREFRecord{1.0, 2.0}}),
|
Opm::ViscrefTable({Opm::VISCREFRecord{1.0, 2.0}}),
|
||||||
Opm::WatdentTable({Opm::WATDENTRecord{1.0, 2.0, 3.0}}),
|
Opm::WatdentTable({Opm::WATDENTRecord{1.0, 2.0, 3.0}}),
|
||||||
|
Loading…
Reference in New Issue
Block a user