mirror of
https://github.com/OPM/opm-simulators.git
synced 2024-12-18 13:33:28 -06:00
Add member hydroCarbonState to the BlackoilState
The hydroCarbonState is used to store the hydroCarbonState State 1: Gas only State 2: Gas and Oil State 3: Oil only An empty vector is return at initialization as no default values are provided by the blackoilstate.
This commit is contained in:
parent
9f99484347
commit
592450777e
@ -24,12 +24,14 @@ BlackoilState::BlackoilState( const BlackoilState& other )
|
||||
: SimulationDataContainer(other)
|
||||
{
|
||||
setBlackoilStateReferencePointers();
|
||||
hydrocarbonstate_ = other.hydroCarbonState();
|
||||
}
|
||||
|
||||
BlackoilState& BlackoilState::operator=( const BlackoilState& other )
|
||||
{
|
||||
SimulationDataContainer::operator=(other);
|
||||
setBlackoilStateReferencePointers();
|
||||
hydrocarbonstate_ = other.hydroCarbonState();
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
@ -62,10 +62,12 @@ namespace Opm
|
||||
std::vector<double>& surfacevol () { return *surfacevol_ref_; }
|
||||
std::vector<double>& gasoilratio () { return *gasoilratio_ref_; }
|
||||
std::vector<double>& rv () { return *rv_ref_; }
|
||||
std::vector<int>& hydroCarbonState() { return hydrocarbonstate_; }
|
||||
|
||||
const std::vector<double>& surfacevol () const { return *surfacevol_ref_; }
|
||||
const std::vector<double>& gasoilratio () const { return *gasoilratio_ref_; }
|
||||
const std::vector<double>& rv () const { return *rv_ref_; }
|
||||
const std::vector<int>& hydroCarbonState() const { return hydrocarbonstate_; }
|
||||
|
||||
private:
|
||||
void setBlackoilStateReferencePointers();
|
||||
@ -73,6 +75,9 @@ namespace Opm
|
||||
std::vector<double>* gasoilratio_ref_;
|
||||
std::vector<double>* rv_ref_;
|
||||
|
||||
// A vector storing the hydro carbon state.
|
||||
std::vector<int> hydrocarbonstate_;
|
||||
|
||||
|
||||
};
|
||||
} // namespace Opm
|
||||
|
Loading…
Reference in New Issue
Block a user