well_segment.hpp
Go to the documentation of this file.
1/*
2 Copyright (C) 2013 Equinor ASA, Norway.
3
4 The file 'well_segment.h' is part of ERT - Ensemble based Reservoir Tool.
5
6 ERT 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 ERT is distributed in the hope that it will be useful, but WITHOUT ANY
12 WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 FITNESS FOR A PARTICULAR PURPOSE.
14
15 See the GNU General Public License at <http://www.gnu.org/licenses/gpl.html>
16 for more details.
17*/
18
19
20#ifndef ERT_WELL_SEGMENT_H
21#define ERT_WELL_SEGMENT_H
22
23
24#ifdef __cplusplus
25extern "C" {
26#endif
27
28#include <stdbool.h>
29
30#include <ert/ecl/ecl_kw.hpp>
32
36
37
38
39
40 typedef struct well_segment_struct well_segment_type;
41
42 well_segment_type * well_segment_alloc_from_kw( const ecl_kw_type * iseg_kw , const well_rseg_loader_type * rseg_loader , const ecl_rsthead_type * header , int well_nr, int segment_index , int segment_id);
43 well_segment_type * well_segment_alloc(int segment_id , int outlet_segment_id , int branch_id , const double * rseg_data);
45 void well_segment_free__(void * arg);
46
47 bool well_segment_active( const well_segment_type * segment );
50
54 int well_segment_get_id( const well_segment_type * segment );
56 bool well_segment_link( well_segment_type * segment , well_segment_type * outlet_segment );
57 void well_segment_link_strict( well_segment_type * segment , well_segment_type * outlet_segment );
58 bool well_segment_has_grid_connections( const well_segment_type * segment , const char * grid_name);
60 bool well_segment_add_connection( well_segment_type * segment , const char * grid_name , well_conn_type * conn);
61 const well_conn_collection_type * well_segment_get_connections(const well_segment_type * segment , const char * grid_name );
63 bool well_segment_well_is_MSW(int well_nr , const ecl_kw_type * iwel_kw , const ecl_rsthead_type * rst_head);
64
65 double well_segment_get_depth( const well_segment_type * segment );
66 double well_segment_get_length( const well_segment_type * segment );
69
70 UTIL_IS_INSTANCE_HEADER( well_segment );
71
72#ifdef __cplusplus
73}
74#endif
75#endif
struct ecl_kw_struct ecl_kw_type
Definition: ecl_kw.hpp:39
Definition: ecl_rsthead.hpp:33
struct well_conn_struct well_conn_type
Definition: well_conn.hpp:44
struct well_conn_collection_struct well_conn_collection_type
Definition: well_conn_collection.hpp:34
struct well_rseg_loader_struct well_rseg_loader_type
Definition: well_rseg_loader.hpp:30
void well_segment_free__(void *arg)
well_segment_type * well_segment_get_outlet(const well_segment_type *segment)
struct well_segment_struct well_segment_type
Definition: well_segment.hpp:40
bool well_segment_well_is_MSW(int well_nr, const ecl_kw_type *iwel_kw, const ecl_rsthead_type *rst_head)
bool well_segment_nearest_wellhead(const well_segment_type *segment)
const well_conn_collection_type * well_segment_get_global_connections(const well_segment_type *segment)
const well_conn_collection_type * well_segment_get_connections(const well_segment_type *segment, const char *grid_name)
bool well_segment_add_connection(well_segment_type *segment, const char *grid_name, well_conn_type *conn)
int well_segment_get_link_count(const well_segment_type *segment)
bool well_segment_link(well_segment_type *segment, well_segment_type *outlet_segment)
well_segment_type * well_segment_alloc_from_kw(const ecl_kw_type *iseg_kw, const well_rseg_loader_type *rseg_loader, const ecl_rsthead_type *header, int well_nr, int segment_index, int segment_id)
bool well_segment_active(const well_segment_type *segment)
UTIL_IS_INSTANCE_HEADER(well_segment)
bool well_segment_has_grid_connections(const well_segment_type *segment, const char *grid_name)
double well_segment_get_length(const well_segment_type *segment)
int well_segment_get_id(const well_segment_type *segment)
void well_segment_link_strict(well_segment_type *segment, well_segment_type *outlet_segment)
double well_segment_get_total_length(const well_segment_type *segment)
double well_segment_get_diameter(const well_segment_type *segment)
bool well_segment_has_global_grid_connections(const well_segment_type *segment)
int well_segment_get_outlet_id(const well_segment_type *segment)
double well_segment_get_depth(const well_segment_type *segment)
bool well_segment_main_stem(const well_segment_type *segment)
well_segment_type * well_segment_alloc(int segment_id, int outlet_segment_id, int branch_id, const double *rseg_data)
void well_segment_free(well_segment_type *segment)
int well_segment_get_branch_id(const well_segment_type *segment)