Add solvent to phaseUsage

This commit is contained in:
Tor Harald Sandve
2017-05-08 10:29:51 +02:00
parent ca2288ac37
commit 9e504da6a1
2 changed files with 13 additions and 0 deletions
+1
View File
@@ -38,6 +38,7 @@ namespace Opm
int num_phases;
int phase_used[MaxNumPhases];
int phase_pos[MaxNumPhases];
bool has_solvent;
};
/// Check or assign presence of a formed, free phase. Limited to
+12
View File
@@ -66,6 +66,12 @@ namespace Opm
OPM_THROW(std::runtime_error, "Cannot handle cases with no OIL, i.e. water-gas systems.");
}
// Add solvent info
pu.has_solvent = false;
if (phase.active(Phase::SOLVENT)) {
pu.has_solvent = true;
}
return pu;
}
@@ -112,6 +118,12 @@ namespace Opm
OPM_THROW(std::runtime_error, "Cannot handle cases with no OIL, i.e. water-gas systems.");
}
// Add solvent info
pu.has_solvent = false;
if (phase.active(Phase::SOLVENT)) {
pu.has_solvent = true;
}
return pu;
}