24#ifndef OPM_WELL_TEST_HEADER_INCLUDED
25#define OPM_WELL_TEST_HEADER_INCLUDED
35template<
class Scalar>
class SingleWellState;
36class WellEconProductionLimits;
37class WellInterfaceGeneric;
47 const double simulation_time,
48 const bool write_message_to_opmlog,
49 WellTestState& well_test_state,
53 const bool write_message_to_opmlog,
54 WellTestState& well_test_state,
58 struct RatioLimitCheckReport {
59 static constexpr int INVALIDCOMPLETION = std::numeric_limits<int>::max();
60 bool ratio_limit_violated =
false;
61 int worst_offending_completion = INVALIDCOMPLETION;
62 double violation_extent = 0.0;
65 void checkMaxGORLimit(
const WellEconProductionLimits& econ_production_limits,
67 RatioLimitCheckReport& report)
const;
69 void checkMaxWGRLimit(
const WellEconProductionLimits& econ_production_limits,
71 RatioLimitCheckReport& report)
const;
73 void checkMaxWaterCutLimit(
const WellEconProductionLimits& econ_production_limits,
75 RatioLimitCheckReport& report)
const;
77 template<
class RatioFunc>
79 const double max_ratio_limit,
80 const RatioFunc& ratioFunc)
const;
82 template<
class RatioFunc>
84 const double max_ratio_limit,
85 const RatioFunc& ratioFunc,
86 RatioLimitCheckReport& report)
const;
88 bool checkRateEconLimits(
const WellEconProductionLimits& econ_production_limits,
89 const std::vector<double>& rates_or_potentials,
93 checkRatioEconLimits(
const WellEconProductionLimits& econ_production_limits,
Definition: DeferredLogger.hpp:57
Definition: WellInterfaceGeneric.hpp:50
Class for performing well tests.
Definition: WellTest.hpp:41
WellTest(const WellInterfaceGeneric &well)
Constructor sets reference to well.
Definition: WellTest.hpp:44
void updateWellTestStateEconomic(const SingleWellState< double > &ws, const double simulation_time, const bool write_message_to_opmlog, WellTestState &well_test_state, DeferredLogger &deferred_logger) const
void updateWellTestStatePhysical(const double simulation_time, const bool write_message_to_opmlog, WellTestState &well_test_state, DeferredLogger &deferred_logger) const
Definition: BlackoilPhases.hpp:27