My Project
Loading...
Searching...
No Matches
SingleNumericalAquifer.hpp
1/*
2 Copyright (C) 2020 SINTEF Digital
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_SINGLENUMERICALAQUIFER_HPP
21#define OPM_SINGLENUMERICALAQUIFER_HPP
22
23#include <opm/input/eclipse/EclipseState/Aquifer/NumericalAquifer/NumericalAquiferConnection.hpp>
24#include <opm/input/eclipse/EclipseState/Aquifer/NumericalAquifer/NumericalAquiferCell.hpp>
25
26#include <set>
27#include <unordered_map>
28#include <vector>
29
30namespace Opm {
31 class NNC;
32 struct NNCdata;
33 class FieldPropsManager;
34
36 double volume;
37 double pore_volume;
38 double depth;
39 double porosity;
40 int satnum;
41 int pvtnum;
42 };
43
45 public:
46 explicit SingleNumericalAquifer(const size_t aqu_id);
47 SingleNumericalAquifer() = default;
48
49 void addAquiferCell(const NumericalAquiferCell& aqu_cell);
50 void addAquiferConnection(const NumericalAquiferConnection& aqu_con);
51
52 void postProcessConnections(const EclipseGrid& grid, const std::vector<int>& actnum);
53
54 // TODO: the following two can be made one function. Let us see
55 // how we use them at the end
56 size_t numCells() const;
57 size_t id() const;
58 size_t numConnections() const;
59 const NumericalAquiferCell* getCellPrt(size_t index) const;
60
61 std::unordered_map<size_t, AquiferCellProps> aquiferCellProps() const;
62
63 std::vector<NNCdata> aquiferCellNNCs() const;
64 std::vector<NNCdata> aquiferConnectionNNCs(const EclipseGrid &grid, const FieldPropsManager &fp) const;
65
66 const std::vector<NumericalAquiferConnection>& connections() const;
67
68 bool operator==(const SingleNumericalAquifer& other) const;
69
70 template<class Serializer>
71 void serializeOp(Serializer& serializer) {
72 serializer(this->id_);
73 serializer(this->cells_);
74 serializer(this->connections_);
75 }
76
77 private:
78 // Maybe this id_ is not necessary
79 // Because if it is a map, the id will be there
80 // Then adding aquifer cells will be much easier with the
81 // default constructor
82 size_t id_;
83 std::vector<NumericalAquiferCell> cells_;
84 std::vector<NumericalAquiferConnection> connections_;
85 };
86}
87
88
89#endif //OPM_SINGLENUMERICALAQUIFER_HPP
About cell information and dimension: The actual grid information is held in a pointer to an ERT ecl_...
Definition EclipseGrid.hpp:55
Definition FieldPropsManager.hpp:42
Class for (de-)serializing.
Definition Serializer.hpp:84
Definition SingleNumericalAquifer.hpp:44
This class implements a small container which holds the transmissibility mulitpliers for all the face...
Definition Exceptions.hpp:30
Definition SingleNumericalAquifer.hpp:35
Definition NumericalAquiferCell.hpp:31
Definition NumericalAquiferConnection.hpp:34