20 #ifndef OPM_PARSER_NNC_HPP
21 #define OPM_PARSER_NNC_HPP
29 #include <opm/common/OpmLog/KeywordLocation.hpp>
37 NNCdata(
size_t c1,
size_t c2,
double t)
38 : cell1(c1), cell2(c2), trans(t)
42 bool operator==(
const NNCdata& data)
const
44 return cell1 == data.cell1 &&
45 cell2 == data.cell2 &&
49 template<
class Serializer>
59 bool operator<(
const NNCdata& other)
const
61 return std::tie(this->cell1, this->cell2) < std::tie(other.cell1, other.cell2);
109 static NNC serializeObject();
111 bool addNNC(
const size_t cell1,
const size_t cell2,
const double trans);
112 const std::vector<NNCdata>& input()
const {
return m_input; }
113 const std::vector<NNCdata>& edit()
const {
return m_edit; }
114 KeywordLocation input_location(
const NNCdata& nnc)
const;
115 KeywordLocation edit_location(
const NNCdata& nnc)
const;
118 bool operator==(
const NNC& data)
const;
120 template<
class Serializer>
121 void serializeOp(Serializer& serializer)
123 serializer.vector(m_input);
124 serializer.vector(m_edit);
125 serializer(m_nnc_location);
126 serializer(m_edit_location);
131 void load_input(
const EclipseGrid& grid,
const Deck& deck);
132 void load_edit(
const EclipseGrid& grid,
const Deck& deck);
133 void add_edit(
const NNCdata& edit_node);
134 bool update_nnc(std::size_t global_index1, std::size_t global_index2,
double tran_mult);
136 std::vector<NNCdata> m_input;
137 std::vector<NNCdata> m_edit;
138 std::optional<KeywordLocation> m_nnc_location;
139 std::optional<KeywordLocation> m_edit_location;
About cell information and dimension: The actual grid information is held in a pointer to an ERT ecl_...
Definition: EclipseGrid.hpp:54
NNC(const EclipseGrid &grid, const Deck &deck)
Construct from input deck.
Definition: Serializer.hpp:38
This class implements a small container which holds the transmissibility mulitpliers for all the face...
Definition: Exceptions.hpp:29