My Project
Equil.hpp
1 #ifndef OPM_EQUIL_HPP
2 #define OPM_EQUIL_HPP
3 
4 #include <cstddef>
5 #include <vector>
6 
7 namespace Opm {
8  class DeckKeyword;
9  class EquilRecord {
10  public:
11  double datumDepth() const;
12  double datumDepthPressure() const;
13  double waterOilContactDepth() const;
14  double waterOilContactCapillaryPressure() const;
15  double gasOilContactDepth() const;
16  double gasOilContactCapillaryPressure() const;
17 
18  bool liveOilInitConstantRs() const;
19  bool wetGasInitConstantRv() const;
20  int initializationTargetAccuracy() const;
21  bool humidGasInitConstantRvw() const;
22 
23  EquilRecord();
24 
25  EquilRecord( double datum_depth_arg, double datum_depth_pc_arg, double woc_depth, double woc_pc, double goc_depth, double goc_pc, bool live_oil_init, bool wet_gas_init, int target_accuracy, bool humid_gas_init);
26 
27  bool operator==(const EquilRecord& data) const;
28 
29  template<class Serializer>
30  void serializeOp(Serializer& serializer)
31  {
32  serializer(datum_depth);
33  serializer(datum_depth_ps);
34  serializer(water_oil_contact_depth);
35  serializer(water_oil_contact_capillary_pressure);
36  serializer(gas_oil_contact_depth);
37  serializer(gas_oil_contact_capillary_pressure);
38  serializer(live_oil_init_proc);
39  serializer(wet_gas_init_proc);
40  serializer(init_target_accuracy);
41  serializer(humid_gas_init_proc);
42  }
43 
44  private:
45  double datum_depth;
46  double datum_depth_ps;
47  double water_oil_contact_depth;
48  double water_oil_contact_capillary_pressure;
49  double gas_oil_contact_depth;
50  double gas_oil_contact_capillary_pressure;
51 
52  bool live_oil_init_proc;
53  bool wet_gas_init_proc;
54  int init_target_accuracy;
55  bool humid_gas_init_proc;
56  };
57 
58  class Equil {
59  public:
60  using const_iterator = std::vector< EquilRecord >::const_iterator;
61 
62  Equil() = default;
63  explicit Equil( const DeckKeyword& );
64 
65  static Equil serializationTestObject();
66 
67  const EquilRecord& getRecord( size_t id ) const;
68 
69  size_t size() const;
70  bool empty() const;
71 
72  const_iterator begin() const;
73  const_iterator end() const;
74 
75  bool operator==(const Equil& data) const;
76 
77  template<class Serializer>
78  void serializeOp(Serializer& serializer)
79  {
80  serializer(m_records);
81  }
82 
83  private:
84  std::vector< EquilRecord > m_records;
85  };
86 
87 }
88 
89 #endif //OPM_EQUIL_HPP
Definition: DeckKeyword.hpp:36
Definition: Equil.hpp:9
Definition: Equil.hpp:58
Class for (de-)serializing.
Definition: Serializer.hpp:75
This class implements a small container which holds the transmissibility mulitpliers for all the face...
Definition: Exceptions.hpp:29