Fix saturation bug.

This commit is contained in:
Atgeirr Flø Rasmussen 2016-07-08 15:06:26 +02:00
parent f12c781f3e
commit 79fed93b76

View File

@ -774,7 +774,7 @@ namespace Opm {
double* s = state_.reservoir_state.saturation().data() + 3*cell;
s[Water] += sfactor*dsw;
s[Gas] += sfactor*dsg;
s[Oil] = 1.0 - s[Water] - s[Oil];
s[Oil] = 1.0 - s[Water] - s[Gas];
// Handle < 0 saturations.
for (int phase : { Gas, Oil, Water }) { // TODO: check if ordering here is significant