mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
BlackoilModelEnums: don't use high-level classes
I consider the blackoil model enums to be pretty low level while the "FluidProperties" code is IMO quite high level. this, using the latter to define the former constitutes a layering violation IMO. note that the fix is to simply use the enums from opm-core directly.
This commit is contained in:
parent
7777fe6918
commit
ac4dcba7e0
@ -20,16 +20,15 @@
|
||||
#ifndef OPM_BLACKOILMODELENUMS_HEADER_INCLUDED
|
||||
#define OPM_BLACKOILMODELENUMS_HEADER_INCLUDED
|
||||
|
||||
#include <opm/autodiff/BlackoilPropsAdInterface.hpp>
|
||||
#include <opm/core/simulator/BlackoilState.hpp>
|
||||
#include <opm/core/props/BlackoilPhases.hpp>
|
||||
|
||||
namespace Opm
|
||||
{
|
||||
|
||||
constexpr const auto Water = BlackoilPropsAdInterface::Water;
|
||||
constexpr const auto Oil = BlackoilPropsAdInterface::Oil;
|
||||
constexpr const auto Gas = BlackoilPropsAdInterface::Gas;
|
||||
constexpr const auto MaxNumPhases = BlackoilPropsAdInterface::MaxNumPhases;
|
||||
constexpr const auto Water = BlackoilPhases::Aqua;
|
||||
constexpr const auto Oil = BlackoilPhases::Liquid;
|
||||
constexpr const auto Gas = BlackoilPhases::Vapour;
|
||||
constexpr const auto MaxNumPhases = BlackoilPhases::MaxNumPhases;
|
||||
|
||||
enum PrimalVariables {
|
||||
Sg = 0,
|
||||
|
@ -22,6 +22,7 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <opm/autodiff/BlackoilPropsAdFromDeck.hpp>
|
||||
#include <opm/autodiff/BlackoilModelEnums.hpp>
|
||||
#include <opm/autodiff/AutoDiffHelpers.hpp>
|
||||
|
||||
#include <opm/core/props/BlackoilPropertiesInterface.hpp>
|
||||
|
@ -24,8 +24,8 @@
|
||||
|
||||
#include <opm/autodiff/BlackoilPropsAdInterface.hpp>
|
||||
#include <opm/autodiff/AutoDiffBlock.hpp>
|
||||
#include <opm/autodiff/BlackoilModelEnums.hpp>
|
||||
|
||||
#include <opm/core/props/BlackoilPhases.hpp>
|
||||
#include <opm/core/props/satfunc/SaturationPropsFromDeck.hpp>
|
||||
#include <opm/core/props/rock/RockFromDeck.hpp>
|
||||
|
||||
|
@ -23,6 +23,7 @@
|
||||
|
||||
#include <opm/autodiff/AutoDiffBlock.hpp>
|
||||
#include <opm/autodiff/AutoDiffHelpers.hpp>
|
||||
#include <opm/autodiff/BlackoilModelEnums.hpp>
|
||||
#include <opm/autodiff/BlackoilPropsAdInterface.hpp>
|
||||
|
||||
struct UnstructuredGrid;
|
||||
@ -70,9 +71,9 @@ namespace Opm {
|
||||
Eigen::Dynamic,
|
||||
Eigen::Dynamic,
|
||||
Eigen::RowMajor> DataBlock;
|
||||
enum { Water = BlackoilPropsAdInterface::Water,
|
||||
Oil = BlackoilPropsAdInterface::Oil,
|
||||
Gas = BlackoilPropsAdInterface::Gas };
|
||||
enum { Water = Opm::Water,
|
||||
Oil = Opm::Oil,
|
||||
Gas = Opm::Gas };
|
||||
|
||||
// Data
|
||||
const UnstructuredGrid& grid_;
|
||||
|
@ -23,7 +23,8 @@
|
||||
|
||||
#include <opm/autodiff/AutoDiffBlock.hpp>
|
||||
#include <opm/autodiff/AutoDiffHelpers.hpp>
|
||||
#include <opm/autodiff/BlackoilPropsAdInterface.hpp>
|
||||
#include <opm/autodiff/BlackoilModelEnums.hpp>
|
||||
#include <opm/autodiff/BlackoilPropsAdFromDeck.hpp>
|
||||
#include <opm/autodiff/NewtonIterationBlackoilInterface.hpp>
|
||||
#include <opm/autodiff/LinearisedBlackoilResidual.hpp>
|
||||
#include <opm/polymer/PolymerProperties.hpp>
|
||||
@ -85,9 +86,9 @@ namespace Opm {
|
||||
}
|
||||
|
||||
enum FipId {
|
||||
FIP_AQUA = BlackoilPropsAdInterface::Water,
|
||||
FIP_LIQUID = BlackoilPropsAdInterface::Oil,
|
||||
FIP_VAPOUR = BlackoilPropsAdInterface::Gas,
|
||||
FIP_AQUA = Opm::Water,
|
||||
FIP_LIQUID = Opm::Oil,
|
||||
FIP_VAPOUR = Opm::Gas,
|
||||
FIP_DISSOLVED_GAS = 3,
|
||||
FIP_VAPORIZED_OIL = 4,
|
||||
FIP_PV = 5, //< Pore volume
|
||||
@ -179,8 +180,8 @@ namespace Opm {
|
||||
Eigen::SparseMatrix<double> p2w; // perf -> well (gather)
|
||||
};
|
||||
|
||||
enum { Water = BlackoilPropsAdInterface::Water,
|
||||
Oil = BlackoilPropsAdInterface::Oil };
|
||||
enum { Water = Opm::Water,
|
||||
Oil = Opm::Oil };
|
||||
|
||||
// Member data
|
||||
const UnstructuredGrid& grid_;
|
||||
|
Loading…
Reference in New Issue
Block a user