Separate well connections (typically static) from well controls

(often dynamically changing throughout simulation).
This commit is contained in:
Bård Skaflestad 2010-09-15 17:27:59 +00:00
parent 6a1b45fda4
commit d96229619e

33
well.h
View File

@ -1,33 +1,20 @@
#ifndef WELL_H_INCLUDED
#define WELL_H_INCLUDED
enum well_type { INJECTOR, PRODUCER };
enum well_control_type { BHP , RATE };
#define WELL_DESCRIPTOR \
int number_of_wells; \
\
enum well_type *type; \
\
enum well_control_type *control_type; \
double *target;
#define WELL_TOPOLOGY \
int *well_connpos; \
int *well_cells;
#define WELL_CONNECTION_DATA \
double *WI; \
double *depth;
/* ---------------------------------------------------------------------- */
enum well_type { INJECTOR, PRODUCER };
enum well_control { BHP , RATE };
typedef struct {
WELL_DESCRIPTOR
WELL_TOPOLOGY
WELL_CONNECTION_DATA
int number_of_wells;
int *well_connpos;
int *well_cells;
} well_t;
typedef struct {
enum well_type *type;
enum well_control *ctrl;
double *target;
} well_control_t;
int
allocate_cell_wells(int nc, well_t *W, int **cwpos, int **cwells);