mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Add parameter --alternative-well-rate-init.
With this, a slightly more sophisticated procedure is used for well rate intialization. Since it changes existing results, it defaults to false, giving the existing behaviour.
This commit is contained in:
parent
6155188a70
commit
24b2393334
@ -145,6 +145,10 @@ template<class TypeTag, class MyTypeTag>
|
||||
struct MaxInnerIterWells {
|
||||
using type = UndefinedProperty;
|
||||
};
|
||||
template<class TypeTag, class MyTypeTag>
|
||||
struct AlternativeWellRateInit {
|
||||
using type = UndefinedProperty;
|
||||
};
|
||||
|
||||
template<class TypeTag>
|
||||
struct DbhpMaxRel<TypeTag, TTag::FlowModelParameters> {
|
||||
@ -251,6 +255,10 @@ struct MaxInnerIterWells<TypeTag, TTag::FlowModelParameters> {
|
||||
static constexpr int value = 50;
|
||||
};
|
||||
template<class TypeTag>
|
||||
struct AlternativeWellRateInit<TypeTag, TTag::FlowModelParameters> {
|
||||
static constexpr bool value = false;
|
||||
};
|
||||
template<class TypeTag>
|
||||
struct StrictInnerIterMsWells<TypeTag, TTag::FlowModelParameters> {
|
||||
static constexpr int value = 40;
|
||||
};
|
||||
@ -432,6 +440,7 @@ namespace Opm
|
||||
EWOMS_REGISTER_PARAM(TypeTag, int, StrictInnerIterMsWells, "Number of inner iterations for multi-segment wells with strict tolerance");
|
||||
EWOMS_REGISTER_PARAM(TypeTag, bool, UseInnerIterationsWells, "Use nested iterations for standard wells");
|
||||
EWOMS_REGISTER_PARAM(TypeTag, int, MaxInnerIterWells, "Maximum number of inner iterations for standard wells");
|
||||
EWOMS_REGISTER_PARAM(TypeTag, bool, AlternativeWellRateInit, "Use alternative well rate initialization procedure");
|
||||
EWOMS_REGISTER_PARAM(TypeTag, Scalar, RegularizationFactorMsw, "Regularization factor for ms wells");
|
||||
EWOMS_REGISTER_PARAM(TypeTag, Scalar, MaxSinglePrecisionDays, "Maximum time step size where single precision floating point arithmetic can be used solving for the linear systems of equations");
|
||||
EWOMS_REGISTER_PARAM(TypeTag, int, MaxStrictIter, "Maximum number of Newton iterations before relaxed tolerances are used for the CNV convergence criterion");
|
||||
|
@ -307,6 +307,7 @@ namespace Opm {
|
||||
bool initial_step_;
|
||||
bool report_step_starts_;
|
||||
bool glift_debug = false;
|
||||
bool alternative_well_rate_init_;
|
||||
std::unique_ptr<RateConverterType> rateConverter_;
|
||||
std::unique_ptr<VFPProperties<VFPInjProperties,VFPProdProperties>> vfp_properties_;
|
||||
|
||||
|
@ -63,6 +63,8 @@ namespace Opm {
|
||||
value);
|
||||
return candidate == parallel_wells.end() || *candidate != value;
|
||||
};
|
||||
|
||||
alternative_well_rate_init_ = EWOMS_GET_PARAM(TypeTag, bool, AlternativeWellRateInit);
|
||||
}
|
||||
|
||||
template<typename TypeTag>
|
||||
@ -393,9 +395,11 @@ namespace Opm {
|
||||
local_deferredLogger.warning("WELL_POTENTIAL_CALCULATION_FAILED", msg);
|
||||
}
|
||||
|
||||
// Update the well rates to match state, if only single-phase rates.
|
||||
for (auto& well : well_container_) {
|
||||
well->updateWellStateRates(ebosSimulator_, well_state_, local_deferredLogger);
|
||||
if (alternative_well_rate_init_) {
|
||||
// Update the well rates to match state, if only single-phase rates.
|
||||
for (auto& well : well_container_) {
|
||||
well->updateWellStateRates(ebosSimulator_, well_state_, local_deferredLogger);
|
||||
}
|
||||
}
|
||||
|
||||
//compute well guideRates
|
||||
|
Loading…
Reference in New Issue
Block a user