mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Merge pull request #4529 from totto82/xmfco2
add molar fraction of CO2 in brine to RST output
This commit is contained in:
commit
8d756a6add
@ -789,6 +789,15 @@ assignToSolution(data::Solution& sol)
|
||||
sol.insert("SGAS", UnitSystem::measure::identity, std::move(saturation_[gasPhaseIdx]), data::TargetType::RESTART_SOLUTION);
|
||||
}
|
||||
|
||||
if (eclState_.runspec().co2Storage() && !rsw_.empty()) {
|
||||
std::vector<double> mfrac(rsw_.size(), 0.0);
|
||||
const auto& pvtnum = eclState_.fieldProps().get_int("PVTNUM");
|
||||
for (size_t i = 0; i < rsw_.size(); ++i) {
|
||||
mfrac[i] = FluidSystem::convertXoGToxoG(FluidSystem::convertRswToXwG(rsw_[i], pvtnum[i]-1), pvtnum[i]-1);
|
||||
}
|
||||
sol.insert("XMFCO2", UnitSystem::measure::identity, std::move(mfrac), data::TargetType::RESTART_AUXILIARY);
|
||||
}
|
||||
|
||||
// Fluid in place
|
||||
for (const auto& phase : Inplace::phases()) {
|
||||
if (outputFipRestart_ && !fip_[phase].empty()) {
|
||||
|
Loading…
Reference in New Issue
Block a user