Apply the swatinit scaling to new_props

The capillary pressure function in new_props is scaled to match the
capillary pressure function in props.

This is a temporary workaround while the simulator uses two different
property object.
This commit is contained in:
Tor Harald Sandve
2015-02-18 08:23:17 +01:00
parent 46cfaa1432
commit 013d1d3499
6 changed files with 55 additions and 0 deletions

View File

@@ -1166,6 +1166,22 @@ BlackoilPropsAdFromDeck::BlackoilPropsAdFromDeck(const BlackoilPropsAdFromDeck&
}
}
}
/// Update capillary pressure scaling according to pressure diff. and initial water saturation.
/// \param[in] saturation Array of n*numPhases cell indices to be associated with the saturation values.
/// \param[in] pc Array of n*numPhases cell indices to be associated with the capillary pressure values.
void BlackoilPropsAdFromDeck::swatinit(const std::vector<double>& saturation,
const std::vector<double>& pc)
{
const int nc = rock_.numCells();
const int numActivePhases = numPhases();
for (int i = 0; i < nc; ++i) {
double pcow = pc[numActivePhases*i + phase_usage_.phase_pos[Water]];
double swat = saturation[numActivePhases*i + phase_usage_.phase_pos[Water]];
satprops_->swatInitScaling(i,pcow,swat);
}
}
/// Apply correction to rs/rv according to kw VAPPARS
/// \param[in/out] r Array of n rs/rv values.