mirror of
https://github.com/OPM/opm-simulators.git
synced 2024-12-24 16:30:02 -06:00
move VtkEnergyModule parameters to TypeTag-free parameter system
This commit is contained in:
parent
3c92550f74
commit
8b860aac07
@ -32,8 +32,8 @@
|
||||
|
||||
#include <opm/material/densead/Math.hpp>
|
||||
|
||||
#include <opm/material/fluidmatrixinteractions/NullMaterial.hpp>
|
||||
#include <opm/material/fluidmatrixinteractions/MaterialTraits.hpp>
|
||||
#include <opm/material/fluidmatrixinteractions/NullMaterial.hpp>
|
||||
|
||||
#include <opm/models/common/energymodule.hh>
|
||||
#include <opm/models/common/multiphasebasemodel.hh>
|
||||
@ -44,8 +44,8 @@
|
||||
#include <opm/models/flash/flashintensivequantities.hh>
|
||||
#include <opm/models/flash/flashlocalresidual.hh>
|
||||
#include <opm/models/flash/flashparameters.hh>
|
||||
#include <opm/models/flash/flashproperties.hh>
|
||||
#include <opm/models/flash/flashprimaryvariables.hh>
|
||||
#include <opm/models/flash/flashproperties.hh>
|
||||
#include <opm/models/flash/flashratevector.hh>
|
||||
|
||||
#include <opm/models/io/vtkcompositionmodule.hh>
|
||||
@ -64,8 +64,7 @@ namespace Opm::Properties {
|
||||
|
||||
namespace TTag {
|
||||
//! The type tag for the isothermal single phase problems
|
||||
struct FlashModel { using InheritsFrom = std::tuple<VtkEnergy,
|
||||
MultiPhaseBaseModel>; };
|
||||
struct FlashModel { using InheritsFrom = std::tuple<MultiPhaseBaseModel>; };
|
||||
} // namespace TTag
|
||||
|
||||
//! Use the FlashLocalResidual function for the flash model
|
||||
|
@ -60,7 +60,7 @@ namespace Opm::Properties {
|
||||
// Create new type tags
|
||||
namespace TTag {
|
||||
//! The generic type tag for problems using the immiscible multi-phase model
|
||||
struct ImmiscibleModel { using InheritsFrom = std::tuple<VtkEnergy, MultiPhaseBaseModel>; };
|
||||
struct ImmiscibleModel { using InheritsFrom = std::tuple<MultiPhaseBaseModel>; };
|
||||
|
||||
//! The type tag for single-phase immiscible problems
|
||||
struct ImmiscibleSinglePhaseModel { using InheritsFrom = std::tuple<ImmiscibleModel>; };
|
||||
|
@ -34,51 +34,18 @@
|
||||
|
||||
#include <opm/models/discretization/common/fvbaseparameters.hh>
|
||||
|
||||
#include <opm/models/utils/propertysystem.hh>
|
||||
#include <opm/models/utils/parametersystem.hh>
|
||||
|
||||
namespace Opm::Properties::TTag {
|
||||
|
||||
// create new type tag for the VTK energy output
|
||||
struct VtkEnergy {};
|
||||
|
||||
} // namespace Opm::Properties::TTag
|
||||
|
||||
#include <opm/models/utils/propertysystem.hh>
|
||||
|
||||
namespace Opm::Parameters {
|
||||
|
||||
// create the property tags needed for the energy module
|
||||
template<class TypeTag, class MyTypeTag>
|
||||
struct VtkWriteInternalEnergies { using type = Properties::UndefinedProperty; };
|
||||
|
||||
template<class TypeTag, class MyTypeTag>
|
||||
struct VtkWriteEnthalpies { using type = Properties::UndefinedProperty; };
|
||||
|
||||
template<class TypeTag, class MyTypeTag>
|
||||
struct VtkWriteSolidInternalEnergy { using type = Properties::UndefinedProperty; };
|
||||
|
||||
template<class TypeTag, class MyTypeTag>
|
||||
struct VtkWriteThermalConductivity { using type = Properties::UndefinedProperty; };
|
||||
|
||||
|
||||
// set default values for what quantities to output
|
||||
template<class TypeTag>
|
||||
struct VtkWriteSolidInternalEnergy<TypeTag, Properties::TTag::VtkEnergy>
|
||||
{ static constexpr bool value = false; };
|
||||
struct VtkWriteSolidInternalEnergy { static constexpr bool value = false; };
|
||||
struct VtkWriteThermalConductivity { static constexpr bool value = false; };
|
||||
struct VtkWriteInternalEnergies { static constexpr bool value = false; };
|
||||
struct VtkWriteEnthalpies { static constexpr bool value = false; };
|
||||
|
||||
template<class TypeTag>
|
||||
struct VtkWriteThermalConductivity<TypeTag, Properties::TTag::VtkEnergy>
|
||||
{ static constexpr bool value = false; };
|
||||
|
||||
template<class TypeTag>
|
||||
struct VtkWriteInternalEnergies<TypeTag, Properties::TTag::VtkEnergy>
|
||||
{ static constexpr bool value = false; };
|
||||
|
||||
template<class TypeTag>
|
||||
struct VtkWriteEnthalpies<TypeTag, Properties::TTag::VtkEnergy>
|
||||
{ static constexpr bool value = false; };
|
||||
|
||||
} // namespace Opm::Properties
|
||||
} // namespace Opm::Parameters
|
||||
|
||||
namespace Opm {
|
||||
/*!
|
||||
@ -125,16 +92,16 @@ public:
|
||||
*/
|
||||
static void registerParameters()
|
||||
{
|
||||
Parameters::registerParam<TypeTag, Parameters::VtkWriteSolidInternalEnergy>
|
||||
Parameters::Register<Parameters::VtkWriteSolidInternalEnergy>
|
||||
("Include the volumetric internal energy of solid"
|
||||
"matrix in the VTK output files");
|
||||
Parameters::registerParam<TypeTag, Parameters::VtkWriteThermalConductivity>
|
||||
Parameters::Register<Parameters::VtkWriteThermalConductivity>
|
||||
("Include the total thermal conductivity of the"
|
||||
"medium in the VTK output files");
|
||||
Parameters::registerParam<TypeTag, Parameters::VtkWriteEnthalpies>
|
||||
Parameters::Register<Parameters::VtkWriteEnthalpies>
|
||||
("Include the specific enthalpy of the phases in "
|
||||
"the VTK output files");
|
||||
Parameters::registerParam<TypeTag, Parameters::VtkWriteInternalEnergies>
|
||||
Parameters::Register<Parameters::VtkWriteInternalEnergies>
|
||||
("Include the specific internal energy of the "
|
||||
"phases in the VTK output files");
|
||||
}
|
||||
@ -209,25 +176,25 @@ public:
|
||||
private:
|
||||
static bool solidInternalEnergyOutput_()
|
||||
{
|
||||
static bool val = Parameters::get<TypeTag, Parameters::VtkWriteSolidInternalEnergy>();
|
||||
static bool val = Parameters::Get<Parameters::VtkWriteSolidInternalEnergy>();
|
||||
return val;
|
||||
}
|
||||
|
||||
static bool thermalConductivityOutput_()
|
||||
{
|
||||
static bool val = Parameters::get<TypeTag, Parameters::VtkWriteThermalConductivity>();
|
||||
static bool val = Parameters::Get<Parameters::VtkWriteThermalConductivity>();
|
||||
return val;
|
||||
}
|
||||
|
||||
static bool enthalpyOutput_()
|
||||
{
|
||||
static bool val = Parameters::get<TypeTag, Parameters::VtkWriteEnthalpies>();
|
||||
static bool val = Parameters::Get<Parameters::VtkWriteEnthalpies>();
|
||||
return val;
|
||||
}
|
||||
|
||||
static bool internalEnergyOutput_()
|
||||
{
|
||||
static bool val = Parameters::get<TypeTag, Parameters::VtkWriteInternalEnergies>();
|
||||
static bool val = Parameters::Get<Parameters::VtkWriteInternalEnergies>();
|
||||
return val;
|
||||
}
|
||||
|
||||
|
@ -69,8 +69,7 @@ namespace TTag {
|
||||
/*!
|
||||
* \brief Define the type tag for the compositional NCP model.
|
||||
*/
|
||||
struct NcpModel { using InheritsFrom = std::tuple<VtkEnergy,
|
||||
MultiPhaseBaseModel>; };
|
||||
struct NcpModel { using InheritsFrom = std::tuple<MultiPhaseBaseModel>; };
|
||||
} // namespace TTag
|
||||
|
||||
//! Use the Ncp local jacobian operator for the compositional NCP model
|
||||
|
@ -35,13 +35,13 @@
|
||||
#include <opm/material/fluidmatrixinteractions/MaterialTraits.hpp>
|
||||
#include <opm/material/fluidmatrixinteractions/NullMaterial.hpp>
|
||||
|
||||
#include <opm/models/common/multiphasebasemodel.hh>
|
||||
#include <opm/models/common/energymodule.hh>
|
||||
#include <opm/models/common/multiphasebasemodel.hh>
|
||||
|
||||
#include <opm/models/flash/flashratevector.hh>
|
||||
#include <opm/models/flash/flashboundaryratevector.hh>
|
||||
#include <opm/models/flash/flashextensivequantities.hh>
|
||||
#include <opm/models/flash/flashproperties.hh>
|
||||
#include <opm/models/flash/flashratevector.hh>
|
||||
|
||||
#include <opm/models/io/vtkcompositionmodule.hh>
|
||||
#include <opm/models/io/vtkdiffusionmodule.hh>
|
||||
@ -69,8 +69,7 @@ namespace Opm::Properties {
|
||||
|
||||
namespace TTag {
|
||||
//! The type tag for the isothermal single phase problems
|
||||
struct FlashModel { using InheritsFrom = std::tuple<VtkEnergy,
|
||||
VtkPTFlash,
|
||||
struct FlashModel { using InheritsFrom = std::tuple<VtkPTFlash,
|
||||
MultiPhaseBaseModel>; };
|
||||
} // namespace TTag
|
||||
|
||||
|
@ -69,8 +69,7 @@ namespace TTag {
|
||||
//! The type tag for the isothermal single phase problems
|
||||
struct PvsModel
|
||||
{
|
||||
using InheritsFrom = std::tuple<VtkEnergy,
|
||||
MultiPhaseBaseModel>; };
|
||||
using InheritsFrom = std::tuple<MultiPhaseBaseModel>; };
|
||||
} // namespace TTag
|
||||
|
||||
//! Use the PVS local jacobian operator for the PVS model
|
||||
|
Loading…
Reference in New Issue
Block a user