mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
some cleaning up for the AquiferFetkovich
This commit is contained in:
parent
21d69a7af0
commit
383748b161
@ -64,6 +64,7 @@ namespace Opm
|
||||
|
||||
protected:
|
||||
// Aquifer Fetkovich Specific Variables
|
||||
// TODO: using const reference here will cause segmentation fault, which is very strange
|
||||
const Aquifetp::AQUFETP_data aqufetp_data_;
|
||||
Scalar aquifer_pressure_; // aquifer
|
||||
|
||||
@ -185,24 +186,6 @@ namespace Opm
|
||||
Base::pa0_ = *(aqufetp_data_.p0);
|
||||
}
|
||||
aquifer_pressure_ = Base::pa0_ ;
|
||||
|
||||
// use the thermodynamic state of the first active cell as a
|
||||
// reference. there might be better ways to do this...
|
||||
ElementContext elemCtx(Base::ebos_simulator_);
|
||||
auto elemIt = Base::ebos_simulator_.gridView().template begin</*codim=*/0>();
|
||||
elemCtx.updatePrimaryStencil(*elemIt);
|
||||
elemCtx.updatePrimaryIntensiveQuantities(/*timeIdx=*/0);
|
||||
const auto& iq0 = elemCtx.intensiveQuantities(/*spaceIdx=*/0, /*timeIdx=*/0);
|
||||
// Initialize a FluidState object first
|
||||
FluidState fs_aquifer;
|
||||
// We use the temperature of the first cell connected to the aquifer
|
||||
// Here we copy the fluidstate of the first cell, so we do not accidentally mess up the reservoir fs
|
||||
fs_aquifer.assign( iq0.fluidState() );
|
||||
Eval temperature_aq, pa0_mean;
|
||||
temperature_aq = fs_aquifer.temperature(0);
|
||||
pa0_mean = Base::pa0_;
|
||||
Eval mu_w_aquifer = FluidSystem::waterPvt().viscosity(pvttableIdx, temperature_aq, pa0_mean);
|
||||
Base::mu_w_ = mu_w_aquifer.value();
|
||||
}
|
||||
|
||||
inline Scalar calculateReservoirEquilibrium()
|
||||
|
@ -202,6 +202,7 @@ namespace Opm
|
||||
std::vector<Eval> rhow_;
|
||||
std::vector<Scalar> alphai_;
|
||||
|
||||
// TODO: Fetkovich does not use mu_w_, it should be moved to CT class
|
||||
Scalar mu_w_; //water viscosity
|
||||
Scalar Tc_; // Time constant
|
||||
Scalar pa0_; // initial aquifer pressure
|
||||
|
Loading…
Reference in New Issue
Block a user