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