well_controls.h
Go to the documentation of this file.
1/*
2 Copyright 2012 SINTEF ICT, Applied Mathematics.
3
4 This file is part of the Open Porous Media project (OPM).
5
6 OPM is free software: you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation, either version 3 of the License, or
9 (at your option) any later version.
10
11 OPM is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with OPM. If not, see <http://www.gnu.org/licenses/>.
18*/
19
20#ifndef OPM_WELL_CONTROLS_H_INCLUDED
21#define OPM_WELL_CONTROLS_H_INCLUDED
22
23#include <stdbool.h>
24
30#ifdef __cplusplus
31extern "C" {
32#endif
33
39};
40
41struct WellControls;
42
43bool
44well_controls_equal(const struct WellControls *ctrls1, const struct WellControls *ctrls2 , bool verbose);
45
46struct WellControls *
48
56struct WellControls *
57well_controls_clone(const struct WellControls *ctrl);
58
59void
60well_controls_destroy(struct WellControls *ctrl);
61
62
63int
64well_controls_get_num(const struct WellControls *ctrl);
65
66int
67well_controls_get_current( const struct WellControls * ctrl);
68
69void
70well_controls_set_current( struct WellControls * ctrl, int current);
71
72
73bool
74well_controls_well_is_stopped(const struct WellControls * ctrl);
75
76bool
77well_controls_well_is_open(const struct WellControls * ctrl);
78
79void
80well_controls_open_well( struct WellControls * ctrl);
81
82void
83well_controls_stop_well( struct WellControls * ctrl);
84
85int
86well_controls_add_new(enum WellControlType type , double target , double alq , int vfp , const double * distr , struct WellControls * ctrl);
87
89well_controls_iget_type(const struct WellControls * ctrl, int control_index);
90
92well_controls_get_current_type(const struct WellControls * ctrl);
93
94void
95well_controls_iset_type( struct WellControls * ctrls , int control_index , enum WellControlType type);
96
97void
98well_controls_iset_target(struct WellControls * ctrl, int control_index , double target);
99
100double
101well_controls_iget_target(const struct WellControls * ctrl, int control_index);
102
103void
104well_controls_iset_alq(struct WellControls * ctrl, int control_index , double alq);
105
106double
107well_controls_iget_alq(const struct WellControls * ctrl, int control_index );
108
109void
110well_controls_iset_vfp(struct WellControls * ctrl, int control_index , int vfp);
111
112int
113well_controls_iget_vfp(const struct WellControls * ctrl, int control_index );
114
115double
116well_controls_get_current_target(const struct WellControls * ctrl);
117
118const double *
119well_controls_iget_distr(const struct WellControls * ctrl, int control_index);
120
121void
122well_controls_iset_distr(const struct WellControls * ctrl, int control_index, const double * distr);
123
124const double *
125well_controls_get_current_distr(const struct WellControls * ctrl);
126
127void
128well_controls_assert_number_of_phases(struct WellControls * ctrl , int number_of_phases);
129
130void
131well_controls_clear(struct WellControls * ctrl);
132
133
134#ifdef __cplusplus
135}
136#endif
137
138#endif /* OPM_WELL_CONTROLS_H_INCLUDED */
void well_controls_iset_target(struct WellControls *ctrl, int control_index, double target)
void well_controls_iset_alq(struct WellControls *ctrl, int control_index, double alq)
void well_controls_iset_vfp(struct WellControls *ctrl, int control_index, int vfp)
int well_controls_add_new(enum WellControlType type, double target, double alq, int vfp, const double *distr, struct WellControls *ctrl)
double well_controls_iget_alq(const struct WellControls *ctrl, int control_index)
bool well_controls_well_is_stopped(const struct WellControls *ctrl)
double well_controls_iget_target(const struct WellControls *ctrl, int control_index)
void well_controls_iset_distr(const struct WellControls *ctrl, int control_index, const double *distr)
void well_controls_open_well(struct WellControls *ctrl)
bool well_controls_well_is_open(const struct WellControls *ctrl)
enum WellControlType well_controls_get_current_type(const struct WellControls *ctrl)
double well_controls_get_current_target(const struct WellControls *ctrl)
bool well_controls_equal(const struct WellControls *ctrls1, const struct WellControls *ctrls2, bool verbose)
int well_controls_iget_vfp(const struct WellControls *ctrl, int control_index)
int well_controls_get_num(const struct WellControls *ctrl)
const double * well_controls_get_current_distr(const struct WellControls *ctrl)
enum WellControlType well_controls_iget_type(const struct WellControls *ctrl, int control_index)
int well_controls_get_current(const struct WellControls *ctrl)
void well_controls_set_current(struct WellControls *ctrl, int current)
const double * well_controls_iget_distr(const struct WellControls *ctrl, int control_index)
void well_controls_assert_number_of_phases(struct WellControls *ctrl, int number_of_phases)
WellControlType
Definition: well_controls.h:34
@ BHP
Definition: well_controls.h:35
@ SURFACE_RATE
Definition: well_controls.h:38
@ RESERVOIR_RATE
Definition: well_controls.h:37
@ THP
Definition: well_controls.h:36
void well_controls_clear(struct WellControls *ctrl)
struct WellControls * well_controls_create(void)
struct WellControls * well_controls_clone(const struct WellControls *ctrl)
void well_controls_stop_well(struct WellControls *ctrl)
void well_controls_destroy(struct WellControls *ctrl)
void well_controls_iset_type(struct WellControls *ctrls, int control_index, enum WellControlType type)