39 if ((rst_group.glift_max_rate + rst_group.glift_max_supply) != 0)
46 : m_name(rst_group.name)
47 , m_max_lift_gas(rst_group.glift_max_supply)
48 , m_max_total_gas(rst_group.glift_max_rate)
51 const std::optional<double>& max_lift_gas()
const {
52 return this->m_max_lift_gas;
55 void max_lift_gas(
double value) {
57 this->m_max_lift_gas = value;
60 const std::optional<double>& max_total_gas()
const {
61 return this->m_max_total_gas;
64 void max_total_gas(
double value) {
66 this->m_max_total_gas = value;
69 const std::string& name()
const {
73 template<
class Serializer>
77 serializer(m_max_lift_gas);
78 serializer(m_max_total_gas);
88 std::optional<double> m_max_lift_gas;
89 std::optional<double> m_max_total_gas;
97 : m_name(rst_well.name)
98 , m_max_rate(rst_well.glift_max_rate)
99 , m_min_rate(rst_well.glift_min_rate)
100 , m_use_glo(rst_well.glift_active)
101 , m_weight(rst_well.glift_weight_factor)
102 , m_inc_weight(rst_well.glift_inc_weight_factor)
103 , m_alloc_extra_gas(rst_well.glift_alloc_extra_gas)
107 GasLiftWell(
const std::string& name,
bool use_glo) :
117 if ((rst_well.glift_max_rate + rst_well.glift_min_rate + rst_well.glift_weight_factor == 0))
123 const std::string& name()
const {
127 bool use_glo()
const {
128 return this->m_use_glo;
131 void max_rate(
double value) {
132 this->m_max_rate = value;
152 const std::optional<double>& max_rate()
const {
153 return this->m_max_rate;
156 void weight_factor(
double value) {
158 this->m_weight = value;
161 double weight_factor()
const {
162 return this->m_weight;
165 void inc_weight_factor(
double value) {
167 this->m_inc_weight = value;
170 double inc_weight_factor()
const {
171 return this->m_inc_weight;
174 void min_rate(
double value) {
176 this->m_min_rate = value;
179 double min_rate()
const {
180 return this->m_min_rate;
183 void alloc_extra_gas(
bool value) {
185 this->m_alloc_extra_gas = value;
188 bool alloc_extra_gas()
const {
189 return this->m_alloc_extra_gas;
192 template<
class Serializer>
196 serializer(m_use_glo);
197 serializer(m_max_rate);
198 serializer(m_min_rate);
199 serializer(m_weight);
200 serializer(m_inc_weight);
201 serializer(m_alloc_extra_gas);
210 std::optional<double> m_max_rate;
211 double m_min_rate = 0;
212 bool m_use_glo =
false;
214 double m_inc_weight = 0;
215 bool m_alloc_extra_gas =
false;
220 const GasLiftGroup& group(
const std::string& gname)
const;
221 const GasLiftWell& well(
const std::string& wname)
const;
223 double gaslift_increment()
const;
224 void gaslift_increment(
double gaslift_increment);
225 double min_eco_gradient()
const;
226 void min_eco_gradient(
double min_eco_gradient);
227 double min_wait()
const;
228 void min_wait(
double min_wait);
229 void all_newton(
double all_newton);
230 bool all_newton()
const;
234 bool has_well(
const std::string& well)
const;
235 bool has_group(
const std::string& group)
const;
236 std::size_t num_wells()
const;
239 bool operator==(
const GasLiftOpt& other)
const;
241 template<
class Serializer>
244 serializer(m_increment);
245 serializer(m_min_eco_gradient);
246 serializer(m_min_wait);
247 serializer(m_all_newton);
248 serializer(m_groups);
253 double m_increment = 0;
254 double m_min_eco_gradient;
256 bool m_all_newton =
true;
258 std::map<std::string, GasLiftGroup> m_groups;
259 std::map<std::string, GasLiftWell> m_wells;
This class implements a small container which holds the transmissibility mulitpliers for all the face...
Definition Exceptions.hpp:30