mirror of
https://github.com/OPM/opm-simulators.git
synced 2024-11-21 16:57:25 -06:00
move FingerProblem parameters to TypeTag-free parameter system
This commit is contained in:
parent
62a180447c
commit
87b1ea17b4
@ -134,15 +134,8 @@ struct EnableConstraints<TypeTag, TTag::FingerBaseProblem> { static constexpr in
|
||||
|
||||
namespace Opm::Parameters {
|
||||
|
||||
template<class TypeTag, class MyTypeTag>
|
||||
struct InitialWaterSaturation { using type = Properties::UndefinedProperty; };
|
||||
|
||||
template<class TypeTag>
|
||||
struct InitialWaterSaturation<TypeTag, Properties::TTag::FingerBaseProblem>
|
||||
{
|
||||
using type = GetPropType<TypeTag, Properties::Scalar>;
|
||||
static constexpr type value = 0.01;
|
||||
};
|
||||
template<class Scalar>
|
||||
struct InitialWaterSaturation { static constexpr Scalar value = 0.01; };
|
||||
|
||||
} // namespace Opm::Parameters
|
||||
|
||||
@ -259,7 +252,7 @@ public:
|
||||
{
|
||||
ParentType::registerParameters();
|
||||
|
||||
Parameters::registerParam<TypeTag, Parameters::InitialWaterSaturation>
|
||||
Parameters::Register<Parameters::InitialWaterSaturation<Scalar>>
|
||||
("The initial saturation in the domain [] of the wetting phase");
|
||||
|
||||
Parameters::SetDefault<Parameters::CellsX>(20);
|
||||
@ -531,7 +524,7 @@ private:
|
||||
auto& fs = initialFluidState_;
|
||||
fs.setPressure(wettingPhaseIdx, /*pressure=*/1e5);
|
||||
|
||||
Scalar Sw = Parameters::get<TypeTag, Parameters::InitialWaterSaturation>();
|
||||
Scalar Sw = Parameters::Get<Parameters::InitialWaterSaturation<Scalar>>();
|
||||
fs.setSaturation(wettingPhaseIdx, Sw);
|
||||
fs.setSaturation(nonWettingPhaseIdx, 1 - Sw);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user