NNC.hpp
Go to the documentation of this file.
1 /*
2  Copyright 2015 IRIS
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 NNC_HPP
21 #define NNC_HPP
22 
25 #include <vector>
26 
27 namespace Opm
28 {
29 class NNC
30 {
31 public:
33  NNC(Opm::DeckConstPtr deck, EclipseGridConstPtr eclipseGrid);
34  void addNNC(const size_t NNC1, const size_t NNC2, const double trans);
35  const std::vector<size_t>& nnc1() const { return m_nnc1; }
36  const std::vector<size_t>& nnc2() const { return m_nnc2; }
37  const std::vector<double>& trans() const { return m_trans; }
38  size_t numNNC() const;
39  bool hasNNC() const;
40 
41 private:
42  std::vector<size_t> m_nnc1;
43  std::vector<size_t> m_nnc2;
44  std::vector<double> m_trans;
45 };
46 
47 
48 } // namespace Opm
49 
50 
51 #endif // NNC_HPP
std::shared_ptr< const EclipseGrid > EclipseGridConstPtr
Definition: EclipseGrid.hpp:143
Definition: Deck.hpp:29
std::shared_ptr< const Deck > DeckConstPtr
Definition: Deck.hpp:86
const std::vector< size_t > & nnc1() const
Definition: NNC.hpp:35
size_t numNNC() const
NNC(Opm::DeckConstPtr deck, EclipseGridConstPtr eclipseGrid)
Construct from input deck.
const std::vector< size_t > & nnc2() const
Definition: NNC.hpp:36
void addNNC(const size_t NNC1, const size_t NNC2, const double trans)
bool hasNNC() const
const std::vector< double > & trans() const
Definition: NNC.hpp:37
Definition: NNC.hpp:29