mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
WellInterface: move code using WellMICPProperties to compile unit
This commit is contained in:
parent
f74f2ded8e
commit
c0e9193e50
@ -25,6 +25,7 @@
|
|||||||
#include <opm/input/eclipse/Schedule/Well/WellBrineProperties.hpp>
|
#include <opm/input/eclipse/Schedule/Well/WellBrineProperties.hpp>
|
||||||
#include <opm/input/eclipse/Schedule/Well/WellConnections.hpp>
|
#include <opm/input/eclipse/Schedule/Well/WellConnections.hpp>
|
||||||
#include <opm/input/eclipse/Schedule/Well/WellFoamProperties.hpp>
|
#include <opm/input/eclipse/Schedule/Well/WellFoamProperties.hpp>
|
||||||
|
#include <opm/input/eclipse/Schedule/Well/WellMICPProperties.hpp>
|
||||||
#include <opm/input/eclipse/Schedule/Well/WellPolymerProperties.hpp>
|
#include <opm/input/eclipse/Schedule/Well/WellPolymerProperties.hpp>
|
||||||
#include <opm/input/eclipse/Schedule/Well/WellTestState.hpp>
|
#include <opm/input/eclipse/Schedule/Well/WellTestState.hpp>
|
||||||
#include <opm/simulators/utils/DeferredLoggingErrorHelpers.hpp>
|
#include <opm/simulators/utils/DeferredLoggingErrorHelpers.hpp>
|
||||||
@ -442,6 +443,20 @@ bool WellInterfaceGeneric::isPressureControlled(const WellState& well_state) con
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
double WellInterfaceGeneric::wmicrobes_() const
|
||||||
|
{
|
||||||
|
auto injectorType = this->well_ecl_.injectorType();
|
||||||
|
|
||||||
|
if (injectorType == InjectorType::WATER) {
|
||||||
|
WellMICPProperties microbes = this->well_ecl_.getMICPProperties();
|
||||||
|
const double microbial_injection_concentration = microbes.m_microbialConcentration;
|
||||||
|
return microbial_injection_concentration;
|
||||||
|
} else {
|
||||||
|
// Not a water injection well => no microbes.
|
||||||
|
return 0.0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
double WellInterfaceGeneric::wfoam_() const
|
double WellInterfaceGeneric::wfoam_() const
|
||||||
{
|
{
|
||||||
auto injectorType = this->well_ecl_.injectorType();
|
auto injectorType = this->well_ecl_.injectorType();
|
||||||
@ -468,6 +483,20 @@ double WellInterfaceGeneric::wsalt_() const
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
double WellInterfaceGeneric::woxygen_() const
|
||||||
|
{
|
||||||
|
auto injectorType = this->well_ecl_.injectorType();
|
||||||
|
|
||||||
|
if (injectorType == InjectorType::WATER) {
|
||||||
|
WellMICPProperties oxygen = this->well_ecl_.getMICPProperties();
|
||||||
|
const double oxygen_injection_concentration = oxygen.m_oxygenConcentration;
|
||||||
|
return oxygen_injection_concentration;
|
||||||
|
} else {
|
||||||
|
// Not a water injection well => no oxygen.
|
||||||
|
return 0.0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
double WellInterfaceGeneric::wpolymer_() const
|
double WellInterfaceGeneric::wpolymer_() const
|
||||||
{
|
{
|
||||||
auto injectorType = this->well_ecl_.injectorType();
|
auto injectorType = this->well_ecl_.injectorType();
|
||||||
@ -482,6 +511,20 @@ double WellInterfaceGeneric::wpolymer_() const
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
double WellInterfaceGeneric::wurea_() const
|
||||||
|
{
|
||||||
|
auto injectorType = this->well_ecl_.injectorType();
|
||||||
|
|
||||||
|
if (injectorType == InjectorType::WATER) {
|
||||||
|
WellMICPProperties urea = this->well_ecl_.getMICPProperties();
|
||||||
|
const double urea_injection_concentration = urea.m_ureaConcentration / 10.; //Dividing by scaling factor 10
|
||||||
|
return urea_injection_concentration;
|
||||||
|
} else {
|
||||||
|
// Not a water injection well => no urea.
|
||||||
|
return 0.0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
int WellInterfaceGeneric::polymerTable_() const
|
int WellInterfaceGeneric::polymerTable_() const
|
||||||
{
|
{
|
||||||
return this->well_ecl_.getPolymerProperties().m_skprpolytable;
|
return this->well_ecl_.getPolymerProperties().m_skprpolytable;
|
||||||
|
@ -198,9 +198,12 @@ public:
|
|||||||
protected:
|
protected:
|
||||||
bool getAllowCrossFlow() const;
|
bool getAllowCrossFlow() const;
|
||||||
|
|
||||||
|
double wmicrobes_() const;
|
||||||
double wfoam_() const;
|
double wfoam_() const;
|
||||||
|
double woxygen_() const;
|
||||||
double wpolymer_() const;
|
double wpolymer_() const;
|
||||||
double wsalt_() const;
|
double wsalt_() const;
|
||||||
|
double wurea_() const;
|
||||||
|
|
||||||
int polymerTable_() const;
|
int polymerTable_() const;
|
||||||
int polymerInjTable_() const;
|
int polymerInjTable_() const;
|
||||||
|
@ -22,7 +22,6 @@
|
|||||||
#include <opm/common/Exceptions.hpp>
|
#include <opm/common/Exceptions.hpp>
|
||||||
|
|
||||||
#include <opm/input/eclipse/Schedule/ScheduleTypes.hpp>
|
#include <opm/input/eclipse/Schedule/ScheduleTypes.hpp>
|
||||||
#include <opm/input/eclipse/Schedule/Well/WellMICPProperties.hpp>
|
|
||||||
#include <opm/simulators/utils/DeferredLoggingErrorHelpers.hpp>
|
#include <opm/simulators/utils/DeferredLoggingErrorHelpers.hpp>
|
||||||
#include <opm/simulators/wells/GroupState.hpp>
|
#include <opm/simulators/wells/GroupState.hpp>
|
||||||
#include <opm/simulators/wells/TargetCalculator.hpp>
|
#include <opm/simulators/wells/TargetCalculator.hpp>
|
||||||
@ -139,16 +138,7 @@ namespace Opm
|
|||||||
wmicrobes() const
|
wmicrobes() const
|
||||||
{
|
{
|
||||||
if constexpr (has_micp) {
|
if constexpr (has_micp) {
|
||||||
auto injectorType = this->well_ecl_.injectorType();
|
return this->wmicrobes_();
|
||||||
|
|
||||||
if (injectorType == InjectorType::WATER) {
|
|
||||||
WellMICPProperties microbes = this->well_ecl_.getMICPProperties();
|
|
||||||
const double microbial_injection_concentration = microbes.m_microbialConcentration;
|
|
||||||
return microbial_injection_concentration;
|
|
||||||
} else {
|
|
||||||
// Not a water injection well => no microbes.
|
|
||||||
return 0.0;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0.0;
|
return 0.0;
|
||||||
@ -160,16 +150,7 @@ namespace Opm
|
|||||||
woxygen() const
|
woxygen() const
|
||||||
{
|
{
|
||||||
if constexpr (has_micp) {
|
if constexpr (has_micp) {
|
||||||
auto injectorType = this->well_ecl_.injectorType();
|
return this->woxygen_();
|
||||||
|
|
||||||
if (injectorType == InjectorType::WATER) {
|
|
||||||
WellMICPProperties oxygen = this->well_ecl_.getMICPProperties();
|
|
||||||
const double oxygen_injection_concentration = oxygen.m_oxygenConcentration;
|
|
||||||
return oxygen_injection_concentration;
|
|
||||||
} else {
|
|
||||||
// Not a water injection well => no oxygen.
|
|
||||||
return 0.0;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0.0;
|
return 0.0;
|
||||||
@ -187,16 +168,7 @@ namespace Opm
|
|||||||
wurea() const
|
wurea() const
|
||||||
{
|
{
|
||||||
if constexpr (has_micp) {
|
if constexpr (has_micp) {
|
||||||
auto injectorType = this->well_ecl_.injectorType();
|
return this->wurea_();
|
||||||
|
|
||||||
if (injectorType == InjectorType::WATER) {
|
|
||||||
WellMICPProperties urea = this->well_ecl_.getMICPProperties();
|
|
||||||
const double urea_injection_concentration = urea.m_ureaConcentration / 10.; //Dividing by scaling factor 10
|
|
||||||
return urea_injection_concentration;
|
|
||||||
} else {
|
|
||||||
// Not a water injection well => no urea.
|
|
||||||
return 0.0;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0.0;
|
return 0.0;
|
||||||
|
Loading…
Reference in New Issue
Block a user