mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
added: RST CONV support for polymer, solvent and brine
This commit is contained in:
@@ -320,7 +320,10 @@ namespace Opm {
|
||||
schedule[timer.reportStepNum()].rst_config(),
|
||||
{getIdx(FluidSystem::oilPhaseIdx),
|
||||
getIdx(FluidSystem::gasPhaseIdx),
|
||||
getIdx(FluidSystem::waterPhaseIdx)});
|
||||
getIdx(FluidSystem::waterPhaseIdx),
|
||||
contiPolymerEqIdx,
|
||||
contiBrineEqIdx,
|
||||
contiSolventEqIdx});
|
||||
|
||||
return report;
|
||||
}
|
||||
|
@@ -34,7 +34,7 @@ namespace Opm {
|
||||
|
||||
void RSTConv::init(const std::size_t numCells,
|
||||
const RSTConfig& rst_config,
|
||||
const std::array<int,3>& compIdx)
|
||||
const std::array<int,6>& compIdx)
|
||||
{
|
||||
const auto kw = rst_config.keywords.find("CONV");
|
||||
if (kw == rst_config.keywords.end()) {
|
||||
@@ -46,9 +46,9 @@ void RSTConv::init(const std::size_t numCells,
|
||||
N_ = kw->second;
|
||||
compIdx_ = compIdx;
|
||||
|
||||
cnv_X_.resize(3);
|
||||
for (std::size_t i = 0; i < 3; ++i) {
|
||||
if (compIdx_[i] != -1) {
|
||||
cnv_X_.resize(6);
|
||||
for (std::size_t i = 0; i < 6; ++i) {
|
||||
if (compIdx_[i] > -1) {
|
||||
cnv_X_[i].resize(numCells);
|
||||
}
|
||||
}
|
||||
|
@@ -45,10 +45,10 @@ public:
|
||||
//! \brief Init state at beginning of step.
|
||||
//! \param numCells Global number of active cells in the model
|
||||
//! \param rst_config RPTRST configuration
|
||||
//! \param compIdx Component index for phases {OIL, GAS, WAT}, -1 if inactive
|
||||
//! \param compIdx Component index for phases {OIL, GAS, WAT, POLYMER, BRINE, SOLVENT}, negative if inactive
|
||||
void init(const std::size_t numCells,
|
||||
const RSTConfig& rst_config,
|
||||
const std::array<int,3>& compIdx);
|
||||
const std::array<int,6>& compIdx);
|
||||
|
||||
//! \brief Adds the CONV output for given residual vector.
|
||||
template<class ResidualVector>
|
||||
@@ -71,7 +71,7 @@ private:
|
||||
const std::vector<int>& globalCell_; //!< Global cell indices
|
||||
Parallel::Communication comm_; //!< Communicator
|
||||
std::vector<std::vector<int>> cnv_X_; //!< Counts of worst cells for RPTRST CONV
|
||||
std::array<int,3> compIdx_; //!< Component indices
|
||||
std::array<int,6> compIdx_; //!< Component indices
|
||||
int N_ = 0; //!< Number of cells to consider
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user