diff --git a/dumux/geomechanics/poroelastic/iofields.hh b/dumux/geomechanics/poroelastic/iofields.hh index b6c91ef71172ad52479aa2ff319537fa2febb567..262475c5b646c5df52e5b75657b432d66e7bf854 100644 --- a/dumux/geomechanics/poroelastic/iofields.hh +++ b/dumux/geomechanics/poroelastic/iofields.hh @@ -24,6 +24,8 @@ #ifndef DUMUX_POROELASTIC_IO_FIELDS_HH #define DUMUX_POROELASTIC_IO_FIELDS_HH +#include <dumux/io/name.hh> + namespace Dumux { /*! @@ -36,8 +38,10 @@ public: template <class OutputModule> static void initOutputModule(OutputModule& out) { - out.addVolumeVariable([](const auto& volVars){ return volVars.displacement(); }, "u"); - out.addVolumeVariable([](const auto& volVars){ return volVars.porosity(); }, "porosity"); + out.addVolumeVariable([](const auto& volVars){ return volVars.displacement(); }, + IOName::displacement()); + out.addVolumeVariable([](const auto& volVars){ return volVars.porosity(); }, + IOName::porosity()); } template <class OutputModule> diff --git a/dumux/io/name.hh b/dumux/io/name.hh index 756685aa7f9e3a9c4196def86fac864cb4e1fd61..e44c7019ae6835af4249ddd71f64887c080e8eeb 100644 --- a/dumux/io/name.hh +++ b/dumux/io/name.hh @@ -38,11 +38,15 @@ std::string pressure(int phaseIdx) noexcept std::string pressure() noexcept { return "p"; } -//! I/O name of saturation +//! I/O name of saturation for multiphase systems template<class FluidSystem> std::string saturation(int phaseIdx) noexcept { return (FluidSystem::numPhases == 1) ? "S" : "S_" + FluidSystem::phaseName(phaseIdx); } +//! I/O name of saturation for singlephase systems +std::string saturation() noexcept +{ return "S"; } + //! I/O name of temperature for equilibrium models std::string temperature() noexcept { return "T"; } @@ -65,6 +69,15 @@ std::string density(int phaseIdx) noexcept std::string density() noexcept { return "rho"; } +//! I/O name of viscosity for multiphase systems +template<class FluidSystem> +std::string viscosity(int phaseIdx) noexcept +{ return (FluidSystem::numPhases == 1) ? "mu" : "mu_" + FluidSystem::phaseName(phaseIdx); } + +//! I/O name of viscosity for singlephase systems +std::string viscosity() noexcept +{ return "mu"; } + //! I/O name of molar density for multiphase systems template<class FluidSystem> std::string molarDensity(int phaseIdx) noexcept @@ -74,6 +87,15 @@ std::string molarDensity(int phaseIdx) noexcept std::string molarDensity() noexcept { return "rhoMolar"; } +//! I/O name of relative permeability for multiphase systems +template<class FluidSystem> +std::string relativePermeability(int phaseIdx) noexcept +{ return (FluidSystem::numPhases == 1) ? "kr" : "kr_" + FluidSystem::phaseName(phaseIdx); } + +//! I/O name of relative permeability for singlephase systems +std::string relativePermeability() noexcept +{ return "kr"; } + //! I/O name of mobility for multiphase systems template<class FluidSystem> std::string mobility(int phaseIdx) noexcept @@ -93,6 +115,22 @@ template<class FluidSystem> std::string massFraction(int phaseIdx, int compIdx) noexcept { return "X^" + FluidSystem::componentName(compIdx) + "_" + FluidSystem::phaseName(phaseIdx); } +//! I/O name of liquid +std::string liquid() noexcept +{ return "liq"; } + +//! I/O name of gaseous +std::string gaseous() noexcept +{ return "gas"; } + +//! I/O name of aqueous +std::string aqueous() noexcept +{ return "aq"; } + +//! I/O name of napl +std::string napl() noexcept +{ return "napl"; } + //! I/O name of capillary pressure std::string capillaryPressure() noexcept { return "pc"; } @@ -101,15 +139,31 @@ std::string capillaryPressure() noexcept std::string porosity() noexcept { return "porosity"; } +//! I/O name of permeability +std::string permeability() noexcept +{ return "permeability"; } + //! I/O name of phase presence std::string phasePresence() noexcept { return "phase presence"; } +//! I/O name of pressure head +std::string pressureHead() noexcept +{ return "pressure head"; } + +//! I/O name of water content +std::string waterContent() noexcept +{ return "water content"; } + //! I/O name of solid volume fraction template<class SolidSystem> std::string solidVolumeFraction(int compIdx = 0) noexcept { return "precipitateVolumeFraction^" + SolidSystem::componentName(compIdx); } +//! I/O name of displacement +std::string displacement() noexcept +{ return "u"; } + } // end namespace IOName } // end namespace Dumux diff --git a/dumux/material/fluidsystems/1pgas.hh b/dumux/material/fluidsystems/1pgas.hh index a889a3f2d80636112301c25f811c01482a8fe173..e5fa4dc2a276f481c59928e298965b3b27fc1218 100644 --- a/dumux/material/fluidsystems/1pgas.hh +++ b/dumux/material/fluidsystems/1pgas.hh @@ -31,6 +31,7 @@ #include <dumux/material/fluidsystems/base.hh> #include <dumux/material/components/componenttraits.hh> +#include <dumux/io/name.hh> namespace Dumux { namespace FluidSystems { @@ -73,7 +74,7 @@ public: * \param phaseIdx The index of the fluid phase to consider */ static std::string phaseName(int phaseIdx = 0) - { return "gas"; } + { return IOName::gaseous(); } /*! * \brief A human readable name for the component. diff --git a/dumux/material/fluidsystems/1pliquid.hh b/dumux/material/fluidsystems/1pliquid.hh index 1d03e0403325675c9bd89909b56056a384b79267..d7f4bbf30e9ccced66c522c163f64620b0cd1769 100644 --- a/dumux/material/fluidsystems/1pliquid.hh +++ b/dumux/material/fluidsystems/1pliquid.hh @@ -31,6 +31,7 @@ #include <dumux/material/fluidsystems/base.hh> #include <dumux/material/components/componenttraits.hh> +#include <dumux/io/name.hh> namespace Dumux { namespace FluidSystems { @@ -73,7 +74,7 @@ public: * \param phaseIdx The index of the fluid phase to consider */ static std::string phaseName(int phaseIdx = 0) - { return "liq"; } + { return IOName::liquid(); } /*! * \brief A human readable name for the component. diff --git a/dumux/material/fluidsystems/2p1c.hh b/dumux/material/fluidsystems/2p1c.hh index 4857dc4b947cb9d32bc905aa2e60f26f186b50f7..4bfe614d72b0b193c251d7b11fd3990e48afd154 100644 --- a/dumux/material/fluidsystems/2p1c.hh +++ b/dumux/material/fluidsystems/2p1c.hh @@ -30,6 +30,8 @@ #include <dune/common/exceptions.hh> +#include <dumux/io/name.hh> + #include "base.hh" namespace Dumux { @@ -68,8 +70,8 @@ public: static std::string phaseName(int phaseIdx) { static std::string name[] = { - std::string("liq"), - std::string("gas"), + std::string(IOName::liquid()), + std::string(IOName::gaseous()), }; assert(0 <= phaseIdx && phaseIdx < numPhases); diff --git a/dumux/material/fluidsystems/2pimmiscible.hh b/dumux/material/fluidsystems/2pimmiscible.hh index 2429a039a0ca4903234fdc41903257e29e674d9e..f6cc03cf975b2a867ec0f94caf25fb2c57bf1af5 100644 --- a/dumux/material/fluidsystems/2pimmiscible.hh +++ b/dumux/material/fluidsystems/2pimmiscible.hh @@ -33,6 +33,7 @@ #include <dumux/material/fluidsystems/1pgas.hh> #include <dumux/material/fluidstates/immiscible.hh> #include <dumux/material/components/base.hh> +#include <dumux/io/name.hh> #include "base.hh" @@ -89,16 +90,16 @@ public: if (!Fluid0::isGas() && !Fluid1::isGas()) { if (phaseIdx == phase0Idx) - return Components::IsAqueous<typename Fluid0::Component>::value ? "aq" : "napl"; + return Components::IsAqueous<typename Fluid0::Component>::value ? IOName::aqueous() : IOName::napl(); else - return Components::IsAqueous<typename Fluid1::Component>::value ? "aq" : "napl"; + return Components::IsAqueous<typename Fluid1::Component>::value ? IOName::aqueous() : IOName::napl(); } else { if (phaseIdx == phase0Idx) - return Fluid0::isGas() ? "gas" : "liq"; + return Fluid0::isGas() ? IOName::gaseous() : IOName::liquid(); else - return Fluid1::isGas() ? "gas" : "liq"; + return Fluid1::isGas() ? IOName::gaseous() : IOName::liquid(); } } diff --git a/dumux/material/fluidsystems/3pimmiscible.hh b/dumux/material/fluidsystems/3pimmiscible.hh index 3d362ffad3cc27e2bf319261b84ee7b4a3caad18..88d9eb94c696ed4edba38caf58c35aa124d2a8b1 100644 --- a/dumux/material/fluidsystems/3pimmiscible.hh +++ b/dumux/material/fluidsystems/3pimmiscible.hh @@ -34,6 +34,7 @@ #include <dumux/material/fluidsystems/1pgas.hh> #include <dumux/material/fluidstates/immiscible.hh> #include <dumux/material/components/base.hh> +#include <dumux/io/name.hh> namespace Dumux { namespace FluidSystems { @@ -93,10 +94,10 @@ public: switch (phaseIdx) { case wPhaseIdx: return Components::IsAqueous<typename WettingFluid::Component>::value - ? "aq" : "napl"; + ? IOName::aqueous() : IOName::napl(); case nPhaseIdx: return Components::IsAqueous<typename NonwettingFluid::Component>::value - ? "aq" : "napl"; - case gPhaseIdx: return "gas"; + ? IOName::aqueous() : IOName::napl(); + case gPhaseIdx: return IOName::gaseous(); } DUNE_THROW(Dune::InvalidStateException, "Invalid phase index " << phaseIdx); } diff --git a/dumux/material/fluidsystems/brine.hh b/dumux/material/fluidsystems/brine.hh index 9bfc0769a499d02f88490aae3110de63bc36ebe8..c1d04a7d5f6fd518d655e7522266c7b78394f4b1 100644 --- a/dumux/material/fluidsystems/brine.hh +++ b/dumux/material/fluidsystems/brine.hh @@ -32,6 +32,8 @@ #include <dumux/common/exceptions.hh> +#include <dumux/io/name.hh> + namespace Dumux { namespace FluidSystems { @@ -69,7 +71,7 @@ public: static const std::string phaseName(int phaseIdx = liquidPhaseIdx) { assert(phaseIdx == liquidPhaseIdx); - return "liq"; + return IOName::liquid(); } /*! diff --git a/dumux/material/fluidsystems/brineair.hh b/dumux/material/fluidsystems/brineair.hh index bba23499ddc91efc1f26b975a48996e247ec3f46..24cda87536935aa2dcbd37ab90c51498a79ed172 100644 --- a/dumux/material/fluidsystems/brineair.hh +++ b/dumux/material/fluidsystems/brineair.hh @@ -41,6 +41,8 @@ #include <dumux/common/valgrind.hh> #include <dumux/common/exceptions.hh> +#include <dumux/io/name.hh> + #include "brine.hh" namespace Dumux { @@ -148,8 +150,8 @@ public: assert(0 <= phaseIdx && phaseIdx < numPhases); switch (phaseIdx) { - case liquidPhaseIdx: return "liq"; - case gasPhaseIdx: return "gas"; + case liquidPhaseIdx: return IOName::liquid(); + case gasPhaseIdx: return IOName::gaseous(); } DUNE_THROW(Dune::InvalidStateException, "Invalid phase index " << phaseIdx); } diff --git a/dumux/material/fluidsystems/brineco2.hh b/dumux/material/fluidsystems/brineco2.hh index 55eb96777b8e02d83e99e9104fe1840af953bc17..489c384c468177a28dfacc2a8181095673723296 100644 --- a/dumux/material/fluidsystems/brineco2.hh +++ b/dumux/material/fluidsystems/brineco2.hh @@ -41,6 +41,8 @@ #include <dumux/material/binarycoefficients/brine_co2.hh> +#include <dumux/io/name.hh> + namespace Dumux { // include the default tables for CO2 @@ -195,8 +197,8 @@ public: { switch (phaseIdx) { - case liquidPhaseIdx: return "liq"; - case gasPhaseIdx: return "gas"; + case liquidPhaseIdx: return IOName::liquid(); + case gasPhaseIdx: return IOName::gaseous(); } DUNE_THROW(Dune::InvalidStateException, "Invalid phase index " << phaseIdx); } diff --git a/dumux/material/fluidsystems/h2oair.hh b/dumux/material/fluidsystems/h2oair.hh index 0efa87856c69ffe0a2d0274ed9ce198a771f59d0..9cc3091bb9364e16630c023837537f6c353e8e89 100644 --- a/dumux/material/fluidsystems/h2oair.hh +++ b/dumux/material/fluidsystems/h2oair.hh @@ -39,6 +39,8 @@ #include <dumux/common/valgrind.hh> #include <dumux/common/exceptions.hh> +#include <dumux/io/name.hh> + namespace Dumux { namespace FluidSystems { /*! @@ -104,8 +106,8 @@ public: assert(0 <= phaseIdx && phaseIdx < numPhases); switch (phaseIdx) { - case liquidPhaseIdx: return "liq"; - case gasPhaseIdx: return "gas"; + case liquidPhaseIdx: return IOName::liquid(); + case gasPhaseIdx: return IOName::gaseous(); } DUNE_THROW(Dune::InvalidStateException, "Invalid phase index " << phaseIdx); } diff --git a/dumux/material/fluidsystems/h2oairmesitylene.hh b/dumux/material/fluidsystems/h2oairmesitylene.hh index 3db76865d2d1028d1a5cf2f8f32e25a9213b101c..9c8a74049a33f8155197be86faae37b151dfc1da 100644 --- a/dumux/material/fluidsystems/h2oairmesitylene.hh +++ b/dumux/material/fluidsystems/h2oairmesitylene.hh @@ -37,6 +37,8 @@ #include <dumux/material/fluidsystems/base.hh> +#include <dumux/io/name.hh> + namespace Dumux { namespace FluidSystems { @@ -197,9 +199,9 @@ public: assert(0 <= phaseIdx && phaseIdx < numPhases); switch (phaseIdx) { - case wPhaseIdx: return "aq"; - case nPhaseIdx: return "napl"; - case gPhaseIdx: return "gas"; + case wPhaseIdx: return IOName::aqueous(); + case nPhaseIdx: return IOName::napl(); + case gPhaseIdx: return IOName::gaseous(); } DUNE_THROW(Dune::InvalidStateException, "Invalid phase index " << phaseIdx); } diff --git a/dumux/material/fluidsystems/h2oairxylene.hh b/dumux/material/fluidsystems/h2oairxylene.hh index 944304bb1c621a1c4dd9a8702aafe5115f3f6cd2..f9832c0b18befd3c190a5a2073eed5f6a280af3e 100644 --- a/dumux/material/fluidsystems/h2oairxylene.hh +++ b/dumux/material/fluidsystems/h2oairxylene.hh @@ -36,6 +36,8 @@ #include <dumux/material/fluidsystems/base.hh> +#include <dumux/io/name.hh> + namespace Dumux { namespace FluidSystems @@ -198,9 +200,9 @@ public: assert(0 <= phaseIdx && phaseIdx < numPhases); switch (phaseIdx) { - case wPhaseIdx: return "aq"; - case nPhaseIdx: return "napl"; - case gPhaseIdx: return "gas"; + case wPhaseIdx: return IOName::aqueous(); + case nPhaseIdx: return IOName::napl(); + case gPhaseIdx: return IOName::gaseous(); } DUNE_THROW(Dune::InvalidStateException, "Invalid phase index " << phaseIdx); } diff --git a/dumux/material/fluidsystems/h2oheavyoil.hh b/dumux/material/fluidsystems/h2oheavyoil.hh index 575b2c74f721ebe7fb18fa25584c1e82f6566243..55f7c00c477aa66f159840154e812c786e94b070 100644 --- a/dumux/material/fluidsystems/h2oheavyoil.hh +++ b/dumux/material/fluidsystems/h2oheavyoil.hh @@ -33,6 +33,8 @@ #include <dumux/material/fluidsystems/base.hh> +#include <dumux/io/name.hh> + namespace Dumux { namespace FluidSystems { @@ -187,9 +189,9 @@ public: assert(0 <= phaseIdx && phaseIdx < numPhases); switch (phaseIdx) { - case wPhaseIdx: return "aq"; - case nPhaseIdx: return "napl"; - case gPhaseIdx: return "gas"; + case wPhaseIdx: return IOName::aqueous(); + case nPhaseIdx: return IOName::napl(); + case gPhaseIdx: return IOName::gaseous(); } DUNE_THROW(Dune::InvalidStateException, "Invalid phase index " << phaseIdx); } diff --git a/dumux/material/fluidsystems/h2on2.hh b/dumux/material/fluidsystems/h2on2.hh index e5c75bc42b2fa21ff804f8e23df2ffa7d1b1dd3e..f1cf83305c70c2b99279228d701295ed3e39e717 100644 --- a/dumux/material/fluidsystems/h2on2.hh +++ b/dumux/material/fluidsystems/h2on2.hh @@ -37,6 +37,8 @@ #include <dumux/material/components/tabulatedcomponent.hh> #include <dumux/material/binarycoefficients/h2o_n2.hh> +#include <dumux/io/name.hh> + #include "base.hh" namespace Dumux { @@ -105,8 +107,8 @@ public: assert(0 <= phaseIdx && phaseIdx < numPhases); switch (phaseIdx) { - case liquidPhaseIdx: return "liq"; - case gasPhaseIdx: return "gas"; + case liquidPhaseIdx: return IOName::liquid(); + case gasPhaseIdx: return IOName::gaseous(); } DUNE_THROW(Dune::InvalidStateException, "Invalid phase index " << phaseIdx); } diff --git a/dumux/material/fluidsystems/h2on2o2.hh b/dumux/material/fluidsystems/h2on2o2.hh index 868dbe8f85d409c59d9e45331c7ccc30521eee76..c30a26d4d7c803a2183581ad03965d86369a3846 100644 --- a/dumux/material/fluidsystems/h2on2o2.hh +++ b/dumux/material/fluidsystems/h2on2o2.hh @@ -44,6 +44,8 @@ #include <dumux/material/binarycoefficients/h2o_o2.hh> #include <dumux/material/binarycoefficients/n2_o2.hh> +#include <dumux/io/name.hh> + namespace Dumux { namespace FluidSystems { /*! @@ -124,8 +126,8 @@ public: assert(0 <= phaseIdx && phaseIdx < numPhases); switch (phaseIdx) { - case liquidPhaseIdx: return "liq"; - case gasPhaseIdx: return "gas"; + case liquidPhaseIdx: return IOName::liquid(); + case gasPhaseIdx: return IOName::gaseous(); } DUNE_THROW(Dune::InvalidStateException, "Invalid phase index " << phaseIdx); } diff --git a/dumux/material/fluidsystems/liquidphase2c.hh b/dumux/material/fluidsystems/liquidphase2c.hh index 67e5847579475e91afda022059355708176db301..c0e0d9a751915c478aaf0b73282beab5d92b8e47 100644 --- a/dumux/material/fluidsystems/liquidphase2c.hh +++ b/dumux/material/fluidsystems/liquidphase2c.hh @@ -30,6 +30,7 @@ #include <dune/common/exceptions.hh> #include <dumux/material/fluidsystems/base.hh> #include <dumux/material/binarycoefficients/h2o_constant.hh> +#include <dumux/io/name.hh> namespace Dumux { namespace FluidSystems { @@ -75,7 +76,7 @@ public: * \param phaseIdx The index of the fluid phase to consider */ static std::string phaseName(int phaseIdx = 0) - { return "liq"; } + { return IOName::liquid(); } /*! * \brief Returns whether the fluids are miscible diff --git a/dumux/material/fluidsystems/spe5.hh b/dumux/material/fluidsystems/spe5.hh index b7fc35f9c4a1b61e0476ab995cebd4d84724efac..eaafbb876931128248dc14e9b98c6ade0caf8b85 100644 --- a/dumux/material/fluidsystems/spe5.hh +++ b/dumux/material/fluidsystems/spe5.hh @@ -28,6 +28,7 @@ #include <dumux/common/spline.hh> #include <dumux/material/eos/pengrobinsonmixture.hh> +#include <dumux/io/name.hh> namespace Dumux { @@ -89,9 +90,9 @@ public: assert(0 <= phaseIdx && phaseIdx < numPhases); switch (phaseIdx) { - case gPhaseIdx: return "gas"; - case wPhaseIdx: return "aq"; - case oPhaseIdx: return "napl"; + case gPhaseIdx: return IOName::gaseous(); + case wPhaseIdx: return IOName::aqueous(); + case oPhaseIdx: return IOName::napl(); } DUNE_THROW(Dune::InvalidStateException, "Invalid phase index " << phaseIdx); } diff --git a/dumux/porousmediumflow/1pnc/iofields.hh b/dumux/porousmediumflow/1pnc/iofields.hh index b14f2a7d0a8c9b381628b0c82a551e33a11ef85c..0b4bf082595c8152e96f18c08e13f582bd144ec8 100644 --- a/dumux/porousmediumflow/1pnc/iofields.hh +++ b/dumux/porousmediumflow/1pnc/iofields.hh @@ -26,6 +26,8 @@ #include <string> +#include <dumux/io/name.hh> + namespace Dumux { /*! @@ -42,18 +44,22 @@ public: using VolumeVariables = typename OutputModule::VolumeVariables; using FluidSystem = typename VolumeVariables::FluidSystem; - out.addVolumeVariable([](const auto& volVars){ return volVars.pressure(0); }, "p"); - out.addVolumeVariable([](const auto& volVars){ return volVars.density(0); }, "rho"); - out.addVolumeVariable([](const auto& volVars){ return volVars.viscosity(0); }, "mu"); - out.addVolumeVariable([](const auto& volVars){ return volVars.pressure(0) - 1e5; }, "delp"); + out.addVolumeVariable([](const auto& volVars){ return volVars.pressure(0); }, + IOName::pressure()); + out.addVolumeVariable([](const auto& volVars){ return volVars.density(0); }, + IOName::density()); + out.addVolumeVariable([](const auto& volVars){ return volVars.viscosity(0); }, + IOName::viscosity()); + out.addVolumeVariable([](const auto& volVars){ return volVars.pressure(0) - 1e5; }, + "delp"); for (int i = 0; i < VolumeVariables::numComponents(); ++i) out.addVolumeVariable([i](const auto& volVars){ return volVars.moleFraction(0, i); }, - "x^" + std::string(FluidSystem::componentName(i)) + "_" + std::string(FluidSystem::phaseName(0))); + IOName::moleFraction<FluidSystem>(0, i)); for (int i = 0; i < VolumeVariables::numComponents(); ++i) out.addVolumeVariable([i](const auto& volVars){ return volVars.massFraction(0, i); }, - "X^" + std::string(FluidSystem::componentName(i))+ "_" + std::string(FluidSystem::phaseName(0))); + IOName::massFraction<FluidSystem>(0, i)); } template <class OutputModule> @@ -66,12 +72,12 @@ public: template <class FluidSystem, class SolidSystem = void> static std::string primaryVariableName(int pvIdx, int state = 0) { - const std::string xString = useMoles ? "x" : "X"; if (pvIdx == 0) - return "p"; + return IOName::pressure(); + else if (useMoles) + return IOName::moleFraction<FluidSystem>(0, pvIdx); else - return xString + "^" + FluidSystem::componentName(pvIdx) - + "_" + FluidSystem::phaseName(0); + return IOName::massFraction<FluidSystem>(0, pvIdx); } }; diff --git a/dumux/porousmediumflow/2p/iofields.hh b/dumux/porousmediumflow/2p/iofields.hh index fe726bd7c2dc3bb4dff2212d5d5ec4c4e2da0b3c..a12e9f4ba5cc958605bf55a2643d4b0c58541ded 100644 --- a/dumux/porousmediumflow/2p/iofields.hh +++ b/dumux/porousmediumflow/2p/iofields.hh @@ -43,20 +43,25 @@ public: template <class OutputModule> static void initOutputModule(OutputModule& out) { - using VolumeVariables = typename VtkOutputModule::VolumeVariables; + using VolumeVariables = typename OutputModule::VolumeVariables; using FS = typename VolumeVariables::FluidSystem; - out.addVolumeVariable([](const VolumeVariables& v){ return v.saturation(FS::phase0Idx); }, "S_"+FS::phaseName(FS::phase0Idx)); - out.addVolumeVariable([](const VolumeVariables& v){ return v.saturation(FS::phase1Idx); }, "S_"+FS::phaseName(FS::phase1Idx)); - out.addVolumeVariable([](const VolumeVariables& v){ return v.pressure(FS::phase0Idx); }, "p_"+FS::phaseName(FS::phase0Idx)); - out.addVolumeVariable([](const VolumeVariables& v){ return v.pressure(FS::phase1Idx); }, "p_"+FS::phaseName(FS::phase1Idx)); - out.addVolumeVariable([](const auto& v){ return v.capillaryPressure(); }, "pc"); - out.addVolumeVariable([](const auto& v){ return v.density(FS::phase0Idx); }, "rho_"+FS::phaseName(FS::phase0Idx)); - out.addVolumeVariable([](const auto& v){ return v.density(FS::phase1Idx); }, "rho_"+FS::phaseName(FS::phase1Idx)); - out.addVolumeVariable([](const auto& v){ return v.mobility(FS::phase0Idx); },"mob_"+ FS::phaseName(FS::phase0Idx)); - out.addVolumeVariable([](const auto& v){ return v.mobility(FS::phase1Idx); },"mob_"+ FS::phaseName(FS::phase1Idx)); + for (int phaseIdx = 0; phaseIdx < FS::numPhases; ++phaseIdx) + { + out.addVolumeVariable([phaseIdx](const VolumeVariables& v){ return v.saturation(phaseIdx); }, + IOName::saturation<FS>(phaseIdx)); + out.addVolumeVariable([phaseIdx](const VolumeVariables& v){ return v.pressure(phaseIdx); }, + IOName::pressure<FS>(phaseIdx)); + out.addVolumeVariable([phaseIdx](const auto& v){ return v.density(phaseIdx); }, + IOName::density<FS>(phaseIdx)); + out.addVolumeVariable([phaseIdx](const auto& v){ return v.mobility(phaseIdx); }, + IOName::mobility<FS>(phaseIdx)); + } - out.addVolumeVariable([](const auto& v){ return v.porosity(); }, "porosity"); + out.addVolumeVariable([](const auto& v){ return v.capillaryPressure(); }, + IOName::capillaryPressure()); + out.addVolumeVariable([](const auto& v){ return v.porosity(); }, + IOName::porosity()); } template <class OutputModule> @@ -66,13 +71,15 @@ public: initOutputModule(out); } - template <class FluidSystem = void, class SolidSystem = void> + template <class FluidSystem, class SolidSystem = void> static std::string primaryVariableName(int pvIdx, int state = 0) { if (priVarFormulation == TwoPFormulation::p0s1) - return pvIdx == 0 ? "p_w" : "S_n"; + return pvIdx == 0 ? IOName::pressure<FluidSystem>(FluidSystem::phase0Idx) + : IOName::saturation<FluidSystem>(FluidSystem::phase1Idx); else - return pvIdx == 0 ? "p_n" : "S_w"; + return pvIdx == 0 ? IOName::pressure<FluidSystem>(FluidSystem::phase1Idx) + : IOName::saturation<FluidSystem>(FluidSystem::phase0Idx); } }; diff --git a/dumux/porousmediumflow/2p/model.hh b/dumux/porousmediumflow/2p/model.hh index 42287814fad511989164b518b2bf139d7c47c29b..311d49864398ab49104330b6978955c1bba2bb30 100644 --- a/dumux/porousmediumflow/2p/model.hh +++ b/dumux/porousmediumflow/2p/model.hh @@ -103,11 +103,11 @@ struct TwoPModelTraits static std::string primaryVariableName(int pvIdx, int state = 0) { if (priVarFormulation() == TwoPFormulation::p0s1) - return pvIdx == 0 ? "p_" + FluidSystem::phaseName(FluidSystem::phase0Idx) - : "S_" + FluidSystem::phaseName(FluidSystem::phase1Idx) ; + return pvIdx == 0 ? IOName::pressure<FluidSystem>(FluidSystem::phase0Idx) + : IOName::saturation<FluidSystem>(FluidSystem::phase1Idx) ; else - return pvIdx == 0 ? "p_" + FluidSystem::phaseName(FluidSystem::phase1Idx) - : "S_" + FluidSystem::phaseName(FluidSystem::phase0Idx); + return pvIdx == 0 ? IOName::pressure<FluidSystem>(FluidSystem::phase1Idx) + : IOName::saturation<FluidSystem>(FluidSystem::phase0Idx); } }; diff --git a/dumux/porousmediumflow/2p1c/iofields.hh b/dumux/porousmediumflow/2p1c/iofields.hh index 9ca4f77d7df5d67dca881f348d9742e27dfdc166..d2cfe340412fd79dfb02b63552b7e71aba73ec91 100644 --- a/dumux/porousmediumflow/2p1c/iofields.hh +++ b/dumux/porousmediumflow/2p1c/iofields.hh @@ -25,6 +25,7 @@ #define DUMUX_TWOP_ONEC_IO_FIELDS_HH #include <dumux/porousmediumflow/2p/iofields.hh> +#include <dumux/io/name.hh> namespace Dumux { @@ -43,7 +44,8 @@ public: TwoPIOFields<priVarFormulation>::initOutputModule(out); // output additional to TwoP output: - out.addVolumeVariable([](const auto& v){ return v.priVars().state(); }, "phase presence"); + out.addVolumeVariable([](const auto& v){ return v.priVars().state(); }, + IOName::phasePresence()); } template <class OutputModule> @@ -53,15 +55,19 @@ public: initOutputModule(out); } - template <class FluidSystem = void, class SolidSystem = void> + template <class FluidSystem, class SolidSystem = void> static std::string primaryVariableName(int pvIdx, int state) { if (priVarFormulation == TwoPFormulation::p0s1) - return (pvIdx == 0) ? "p_w" : - (state == Indices::twoPhases) ? "S_n" : "T"; + return (pvIdx == 0) ? IOName::pressure<FluidSystem>(FluidSystem::phase0Idx) : + (state == Indices::twoPhases) + ? IOName::saturation<FluidSystem>(FluidSystem::phase1Idx) + : IOName::temperature(); else - return (pvIdx == 0) ? "p_n" : - (state == Indices::twoPhases) ? "S_w" : "T"; + return (pvIdx == 0) ? IOName::pressure<FluidSystem>(FluidSystem::phase1Idx) : + (state == Indices::twoPhases) + ? IOName::saturation<FluidSystem>(FluidSystem::phase0Idx) + : IOName::temperature(); } }; diff --git a/dumux/porousmediumflow/2pnc/iofields.hh b/dumux/porousmediumflow/2pnc/iofields.hh index 1b6ebbd0f28b9dff71ffd249a0e7e7af21a9ff78..58ee4253774f56501edbf55fd30fa783a8368777 100644 --- a/dumux/porousmediumflow/2pnc/iofields.hh +++ b/dumux/porousmediumflow/2pnc/iofields.hh @@ -25,6 +25,7 @@ #define DUMUX_TWOP_NC_IO_FIELDS_HH #include <dumux/porousmediumflow/2p/iofields.hh> +#include <dumux/io/name.hh> namespace Dumux { @@ -46,24 +47,24 @@ public: // use default fields from the 2p model TwoPIOFields<priVarFormulation>::initOutputModule(out); - //output additional to TwoP output: - for (int i = 0; i < VolumeVariables::numPhases(); ++i) - for (int j = 0; j < VolumeVariables::numComponents(); ++j) - out.addVolumeVariable([i,j](const auto& v){ return v.moleFraction(i,j); }, - "x^"+ FluidSystem::componentName(j) + "_" + FluidSystem::phaseName(i)); - - for (int i = 0; i < VolumeVariables::numPhases(); ++i) - out.addVolumeVariable([i](const auto& v){ return v.molarDensity(i); }, - "rhoMolar_" + FluidSystem::phaseName(i)); - - if (VolumeVariables::numComponents() < 3){ - for (int i = 0; i < VolumeVariables::numPhases(); ++i) - for (int j = 0; j < VolumeVariables::numComponents(); ++j) - out.addVolumeVariable([i,j](const auto& v){ return v.massFraction(i,j); }, - "X^"+ FluidSystem::componentName(j) + "_" + FluidSystem::phaseName(i)); + // output additional to TwoP output: + for (int phaseIdx = 0; phaseIdx < VolumeVariables::numPhases(); ++phaseIdx) + { + for (int compIdx = 0; compIdx < VolumeVariables::numComponents(); ++compIdx) + { + out.addVolumeVariable([phaseIdx,compIdx](const auto& v){ return v.moleFraction(phaseIdx,compIdx); }, + IOName::moleFraction<FluidSystem>(phaseIdx, compIdx)); + if (VolumeVariables::numComponents() < 3) + out.addVolumeVariable([phaseIdx,compIdx](const auto& v){ return v.massFraction(phaseIdx,compIdx); }, + IOName::massFraction<FluidSystem>(phaseIdx, compIdx)); + } + + out.addVolumeVariable([phaseIdx](const auto& v){ return v.molarDensity(phaseIdx); }, + IOName::molarDensity<FluidSystem>(phaseIdx)); } - out.addVolumeVariable([](const auto& v){ return v.priVars().state(); }, "phase presence"); + out.addVolumeVariable([](const auto& v){ return v.priVars().state(); }, + IOName::phasePresence()); } template <class OutputModule> @@ -76,33 +77,39 @@ public: template <class FluidSystem, class SolidSystem = void> static std::string primaryVariableName(int pvIdx, int state) { - const std::string xString = useMoles ? "x" : "X"; - - std::string phaseNameSecComps; + int idxSecComps; if (state == Indices::firstPhaseOnly || (state == Indices::bothPhases && setMoleFractionsForFirstPhase)) - phaseNameSecComps = FluidSystem::phaseName(FluidSystem::phase0Idx); + idxSecComps = FluidSystem::phase0Idx; else - phaseNameSecComps = FluidSystem::phaseName(FluidSystem::phase1Idx); + idxSecComps = FluidSystem::phase1Idx; if (pvIdx > 1) - return xString + "^" + FluidSystem::componentName(pvIdx) + "_" + phaseNameSecComps; + return useMoles ? IOName::moleFraction<FluidSystem>(idxSecComps, pvIdx) + : IOName::massFraction<FluidSystem>(idxSecComps, pvIdx); const std::vector<std::string> p0s1SwitchedPvNames = { - xString + "^" + FluidSystem::componentName(FluidSystem::comp1Idx) + "_" + FluidSystem::phaseName(FluidSystem::phase0Idx), - xString + "^" + FluidSystem::componentName(FluidSystem::comp0Idx) + "_" + FluidSystem::phaseName(FluidSystem::phase1Idx), - "S_n"}; + useMoles ? IOName::moleFraction<FluidSystem>(FluidSystem::phase0Idx, FluidSystem::comp1Idx) + : IOName::massFraction<FluidSystem>(FluidSystem::phase0Idx, FluidSystem::comp1Idx), + useMoles ? IOName::moleFraction<FluidSystem>(FluidSystem::phase1Idx, FluidSystem::comp0Idx) + : IOName::massFraction<FluidSystem>(FluidSystem::phase1Idx, FluidSystem::comp0Idx), + IOName::saturation<FluidSystem>(FluidSystem::phase1Idx)}; + const std::vector<std::string> p1s0SwitchedPvNames = { - xString + "^" + FluidSystem::componentName(FluidSystem::comp1Idx) + "_" + FluidSystem::phaseName(FluidSystem::phase0Idx), - xString + "^" + FluidSystem::componentName(FluidSystem::comp0Idx) + "_" + FluidSystem::phaseName(FluidSystem::phase1Idx), - "S_w"}; + useMoles ? IOName::moleFraction<FluidSystem>(FluidSystem::phase0Idx, FluidSystem::comp1Idx) + : IOName::massFraction<FluidSystem>(FluidSystem::phase0Idx, FluidSystem::comp1Idx), + useMoles ? IOName::moleFraction<FluidSystem>(FluidSystem::phase1Idx, FluidSystem::comp0Idx) + : IOName::massFraction<FluidSystem>(FluidSystem::phase1Idx, FluidSystem::comp0Idx), + IOName::saturation<FluidSystem>(FluidSystem::phase0Idx)}; switch (priVarFormulation) { case TwoPFormulation::p0s1: - return pvIdx == 0 ? "p_w" : p0s1SwitchedPvNames[state-1]; + return pvIdx == 0 ? IOName::pressure<FluidSystem>(FluidSystem::wPhaseIdx) + : p0s1SwitchedPvNames[state-1]; case TwoPFormulation::p1s0: - return pvIdx == 0 ? "p_n" : p1s0SwitchedPvNames[state-1]; + return pvIdx == 0 ? IOName::pressure<FluidSystem>(FluidSystem::nPhaseIdx) + : p1s0SwitchedPvNames[state-1]; default: DUNE_THROW(Dune::InvalidStateException, "Invalid formulation "); } } diff --git a/dumux/porousmediumflow/2pnc/model.hh b/dumux/porousmediumflow/2pnc/model.hh index d8d79889ebff2ec9759392fc062aeddda6ab5026..c5cfa177db8fb403ae041dd08571107102b7fa2e 100644 --- a/dumux/porousmediumflow/2pnc/model.hh +++ b/dumux/porousmediumflow/2pnc/model.hh @@ -153,19 +153,19 @@ struct TwoPNCModelTraits const std::vector<std::string> p0s1SwitchedPvNames = { xString + "^" + FluidSystem::componentName(FluidSystem::comp1Idx) + "_" + FluidSystem::phaseName(FluidSystem::phase0Idx), xString + "^" + FluidSystem::componentName(FluidSystem::comp0Idx) + "_" + FluidSystem::phaseName(FluidSystem::phase1Idx), - "S_" + FluidSystem::phaseName(FluidSystem::phase1Idx)}; + IOName::saturation<FluidSystem>(FluidSystem::phase1Idx)}; const std::vector<std::string> p1s0SwitchedPvNames = { xString + "^" + FluidSystem::componentName(FluidSystem::comp1Idx) + "_" + FluidSystem::phaseName(FluidSystem::phase0Idx), xString + "^" + FluidSystem::componentName(FluidSystem::comp0Idx) + "_" + FluidSystem::phaseName(FluidSystem::phase1Idx), - "S_" + FluidSystem::phaseName(FluidSystem::phase0Idx)}; + IOName::saturation<FluidSystem>(FluidSystem::phase0Idx)}; switch (priVarFormulation()) { case TwoPFormulation::p0s1: - return pvIdx == 0 ? "p_" + FluidSystem::phaseName(FluidSystem::phase0Idx) + return pvIdx == 0 ? IOName::pressure<FluidSystem>(FluidSystem::phase0Idx) : p0s1SwitchedPvNames[state-1]; case TwoPFormulation::p1s0: - return pvIdx == 0 ? "p_" + FluidSystem::phaseName(FluidSystem::phase1Idx) + return pvIdx == 0 ? IOName::pressure<FluidSystem>(FluidSystem::phase1Idx) : p1s0SwitchedPvNames[state-1]; default: DUNE_THROW(Dune::InvalidStateException, "Invalid formulation "); } diff --git a/dumux/porousmediumflow/3p/iofields.hh b/dumux/porousmediumflow/3p/iofields.hh index a9947e1ad98b32749c3eec79c6dd5e35242643da..a33a68111b14b3176eab0d1f32ab31e3574eca47 100644 --- a/dumux/porousmediumflow/3p/iofields.hh +++ b/dumux/porousmediumflow/3p/iofields.hh @@ -24,6 +24,8 @@ #ifndef DUMUX_THREEP_IO_FIELDS_HH #define DUMUX_THREEP_IO_FIELDS_HH +#include <dumux/io/name.hh> + namespace Dumux { /*! @@ -36,19 +38,24 @@ public: template <class OutputModule> static void initOutputModule(OutputModule& out) { - using VolumeVariables = typename VtkOutputModule::VolumeVariables; + using VolumeVariables = typename OutputModule::VolumeVariables; using FluidSystem = typename VolumeVariables::FluidSystem; // register standardized output fields - for (int i = 0; i < VolumeVariables::numPhases(); ++i) + for (int phaseIdx = 0; phaseIdx < VolumeVariables::numPhases(); ++phaseIdx) { - out.addVolumeVariable([i](const auto& v){ return v.saturation(i); }, "S_"+ FluidSystem::phaseName(i)); - out.addVolumeVariable([i](const auto& v){ return v.pressure(i); }, "p_"+ FluidSystem::phaseName(i)); - out.addVolumeVariable([i](const auto& v){ return v.density(i); }, "rho_"+ FluidSystem::phaseName(i)); + out.addVolumeVariable([phaseIdx](const auto& v){ return v.saturation(phaseIdx); }, + IOName::saturation<FluidSystem>(phaseIdx)); + out.addVolumeVariable([phaseIdx](const auto& v){ return v.pressure(phaseIdx); }, + IOName::pressure<FluidSystem>(phaseIdx)); + out.addVolumeVariable([phaseIdx](const auto& v){ return v.density(phaseIdx); }, + IOName::density<FluidSystem>(phaseIdx)); } - out.addVolumeVariable( [](const auto& v){ return v.porosity(); },"porosity"); - out.addVolumeVariable( [](const auto& v){ return v.permeability(); },"permeability"); + out.addVolumeVariable( [](const auto& v){ return v.porosity(); }, + IOName::porosity()); + out.addVolumeVariable( [](const auto& v){ return v.permeability(); }, + IOName::permeability()); } template <class OutputModule> @@ -58,14 +65,14 @@ public: initOutputModule(out); } - template <class FluidSystem = void, class SolidSystem = void> + template <class FluidSystem, class SolidSystem = void> static std::string primaryVariableName(int pvIdx, int state = 0) { switch (pvIdx) { - case 0: return "p_g"; - case 1: return "S_w"; - default: return "S_n"; + case 0: return IOName::pressure<FluidSystem>(FluidSystem::gPhaseIdx); + case 1: return IOName::saturation<FluidSystem>(FluidSystem::wPhaseIdx); + default: return IOName::saturation<FluidSystem>(FluidSystem::nPhaseIdx); } } }; diff --git a/dumux/porousmediumflow/3p3c/iofields.hh b/dumux/porousmediumflow/3p3c/iofields.hh index 16c9fe4c7098599c04886326cea61e251b274354..25d31deb2f87e8cfdb50195ecb4b1acf41135841 100644 --- a/dumux/porousmediumflow/3p3c/iofields.hh +++ b/dumux/porousmediumflow/3p3c/iofields.hh @@ -24,6 +24,8 @@ #ifndef DUMUX_THREEPTHREEC_IO_FIELDS_HH #define DUMUX_THREEPTHREEC_IO_FIELDS_HH +#include <dumux/io/name.hh> + namespace Dumux { /*! @@ -40,25 +42,27 @@ public: using VolumeVariables = typename OutputModule::VolumeVariables; using FluidSystem = typename VolumeVariables::FluidSystem; - // register standardized out output fields - out.addVolumeVariable( [](const auto& v){ return v.saturation(FluidSystem::wPhaseIdx); }, "S_w"); - out.addVolumeVariable( [](const auto& v){ return v.saturation(FluidSystem::nPhaseIdx); },"S_n"); - out.addVolumeVariable( [](const auto& v){ return v.saturation(FluidSystem::gPhaseIdx); },"S_g"); - out.addVolumeVariable( [](const auto& v){ return v.pressure(FluidSystem::wPhaseIdx); },"p_w"); - out.addVolumeVariable( [](const auto& v){ return v.pressure(FluidSystem::nPhaseIdx); },"p_n"); - out.addVolumeVariable( [](const auto& v){ return v.pressure(FluidSystem::gPhaseIdx); },"p_g"); - out.addVolumeVariable( [](const auto& v){ return v.density(FluidSystem::wPhaseIdx); },"rho_w"); - out.addVolumeVariable( [](const auto& v){ return v.density(FluidSystem::nPhaseIdx); },"rho_n"); - out.addVolumeVariable( [](const auto& v){ return v.density(FluidSystem::gPhaseIdx); },"rho_g"); + // register standardized output fields + for (int phaseIdx = 0; phaseIdx < VolumeVariables::numPhases(); ++phaseIdx) + { + out.addVolumeVariable( [phaseIdx](const auto& v){ return v.saturation(phaseIdx); }, + IOName::saturation<FluidSystem>(phaseIdx)); + out.addVolumeVariable( [phaseIdx](const auto& v){ return v.pressure(phaseIdx); }, + IOName::pressure<FluidSystem>(phaseIdx)); + out.addVolumeVariable( [phaseIdx](const auto& v){ return v.density(phaseIdx); }, + IOName::density<FluidSystem>(phaseIdx)); - for (int i = 0; i < VolumeVariables::numPhases(); ++i) - for (int j = 0; j < VolumeVariables::numComponents(); ++j) - out.addVolumeVariable([i,j](const auto& v){ return v.moleFraction(i,j); }, - "x^" + FluidSystem::componentName(j) + "_" + FluidSystem::phaseName(i)); + for (int compIdx = 0; compIdx < VolumeVariables::numComponents(); ++compIdx) + out.addVolumeVariable([phaseIdx, compIdx](const auto& v){ return v.moleFraction(phaseIdx, compIdx); }, + IOName::moleFraction<FluidSystem>(phaseIdx, compIdx)); + } - out.addVolumeVariable( [](const auto& v){ return v.porosity(); },"porosity"); - out.addVolumeVariable( [](const auto& v){ return v.priVars().state(); },"phase presence"); - out.addVolumeVariable( [](const auto& v){ return v.permeability(); },"permeability"); + out.addVolumeVariable( [](const auto& v){ return v.porosity(); }, + IOName::porosity()); + out.addVolumeVariable( [](const auto& v){ return v.priVars().state(); }, + IOName::phasePresence()); + out.addVolumeVariable( [](const auto& v){ return v.permeability(); }, + IOName::permeability()); } template <class OutputModule> @@ -75,44 +79,44 @@ public: { case Indices::threePhases: { - const std::vector<std::string> s1 = {"p_g", - "S_w", - "S_n"}; + const std::vector<std::string> s1 = {IOName::pressure<FluidSystem>(FluidSystem::gPhaseIdx), + IOName::saturation<FluidSystem>(FluidSystem::wPhaseIdx), + IOName::saturation<FluidSystem>(FluidSystem::nPhaseIdx)}; return s1[pvIdx]; } case Indices::wPhaseOnly: { - const std::vector<std::string> s2 = {"p_g", - "x^" + FluidSystem::componentName(FluidSystem::gCompIdx) + "_" + FluidSystem::phaseName(FluidSystem::wPhaseIdx), - "x^" + FluidSystem::componentName(FluidSystem::nCompIdx) + "_" + FluidSystem::phaseName(FluidSystem::wPhaseIdx)}; + const std::vector<std::string> s2 = {IOName::pressure<FluidSystem>(FluidSystem::gPhaseIdx), + IOName::moleFraction<FluidSystem>(FluidSystem::wPhaseIdx, FluidSystem::gCompIdx), + IOName::moleFraction<FluidSystem>(FluidSystem::wPhaseIdx, FluidSystem::nCompIdx)}; return s2[pvIdx]; } case Indices::gnPhaseOnly: { - const std::vector<std::string> s3 = {"p_g", - "x^" + FluidSystem::componentName(FluidSystem::wCompIdx) + "_" + FluidSystem::phaseName(FluidSystem::gPhaseIdx), - "S_n"}; + const std::vector<std::string> s3 = {IOName::pressure<FluidSystem>(FluidSystem::gPhaseIdx), + IOName::moleFraction<FluidSystem>(FluidSystem::gPhaseIdx, FluidSystem::wCompIdx), + IOName::saturation<FluidSystem>(FluidSystem::nPhaseIdx)}; return s3[pvIdx]; } case Indices::wnPhaseOnly: { - const std::vector<std::string> s4 = {"p_g", - "x^" + FluidSystem::componentName(FluidSystem::gCompIdx) + "_" + FluidSystem::phaseName(FluidSystem::wPhaseIdx), - "S_n"}; + const std::vector<std::string> s4 = {IOName::pressure<FluidSystem>(FluidSystem::gPhaseIdx), + IOName::moleFraction<FluidSystem>(FluidSystem::wPhaseIdx, FluidSystem::gCompIdx), + IOName::saturation<FluidSystem>(FluidSystem::nPhaseIdx)}; return s4[pvIdx]; } case Indices::gPhaseOnly: { - const std::vector<std::string> s5 = {"p_g", - "x^" + FluidSystem::componentName(FluidSystem::wCompIdx) + "_" + FluidSystem::phaseName(FluidSystem::gPhaseIdx), - "x^" + FluidSystem::componentName(FluidSystem::nCompIdx) + "_" + FluidSystem::phaseName(FluidSystem::gPhaseIdx)}; + const std::vector<std::string> s5 = {IOName::pressure<FluidSystem>(FluidSystem::gPhaseIdx), + IOName::moleFraction<FluidSystem>(FluidSystem::gPhaseIdx, FluidSystem::wCompIdx), + IOName::moleFraction<FluidSystem>(FluidSystem::gPhaseIdx, FluidSystem::nCompIdx)}; return s5[pvIdx]; } case Indices::wgPhaseOnly: { - const std::vector<std::string> s6 = {"p_g", - "S_w", - "x^" + FluidSystem::componentName(FluidSystem::nCompIdx) + "_" + FluidSystem::phaseName(FluidSystem::gPhaseIdx)}; + const std::vector<std::string> s6 = {IOName::pressure<FluidSystem>(FluidSystem::gPhaseIdx), + IOName::saturation<FluidSystem>(FluidSystem::wPhaseIdx), + IOName::moleFraction<FluidSystem>(FluidSystem::gPhaseIdx, FluidSystem::nCompIdx)}; return s6[pvIdx]; } } diff --git a/dumux/porousmediumflow/3pwateroil/iofields.hh b/dumux/porousmediumflow/3pwateroil/iofields.hh index cdb99db5cbf4961df886e18a5a3529ec6009e3b9..4d33cae0f77d02bb73bd622b965625ee792a0355 100644 --- a/dumux/porousmediumflow/3pwateroil/iofields.hh +++ b/dumux/porousmediumflow/3pwateroil/iofields.hh @@ -24,6 +24,9 @@ #ifndef DUMUX_3P2CNI_IO_FIELDS_HH #define DUMUX_3P2CNI_IO_FIELDS_HH +#include <dumux/io/name.hh> +#include <dumux/porousmediumflow/3p3c/iofields.hh> + namespace Dumux { /*! @@ -41,31 +44,31 @@ public: using VolumeVariables = typename OutputModule::VolumeVariables; using FluidSystem = typename VolumeVariables::FluidSystem; - // register standardized out output fields - out.addVolumeVariable( [](const auto& v){ return v.saturation(FluidSystem::wPhaseIdx); }, "S_w"); - out.addVolumeVariable( [](const auto& v){ return v.saturation(FluidSystem::nPhaseIdx); },"S_n"); - out.addVolumeVariable( [](const auto& v){ return v.saturation(FluidSystem::gPhaseIdx); },"S_g"); - out.addVolumeVariable( [](const auto& v){ return v.pressure(FluidSystem::wPhaseIdx); },"p_w"); - out.addVolumeVariable( [](const auto& v){ return v.pressure(FluidSystem::nPhaseIdx); },"p_n"); - out.addVolumeVariable( [](const auto& v){ return v.pressure(FluidSystem::gPhaseIdx); },"p_g"); - out.addVolumeVariable( [](const auto& v){ return v.density(FluidSystem::wPhaseIdx); },"rho_w"); - out.addVolumeVariable( [](const auto& v){ return v.density(FluidSystem::nPhaseIdx); },"rho_n"); - out.addVolumeVariable( [](const auto& v){ return v.density(FluidSystem::gPhaseIdx); },"rho_g"); - out.addVolumeVariable( [](const auto& v){ return v.mobility(FluidSystem::wPhaseIdx); },"mob_w"); - out.addVolumeVariable( [](const auto& v){ return v.mobility(FluidSystem::nPhaseIdx); },"mob_n"); - out.addVolumeVariable( [](const auto& v){ return v.mobility(FluidSystem::gPhaseIdx); },"mob_g"); - out.addVolumeVariable( [](const auto& v){ return v.viscosity(FluidSystem::wPhaseIdx); },"viscos_w"); - out.addVolumeVariable( [](const auto& v){ return v.viscosity(FluidSystem::nPhaseIdx); },"viscos_n"); - out.addVolumeVariable( [](const auto& v){ return v.viscosity(FluidSystem::gPhaseIdx); },"viscos_g"); + // register standardized output fields + for (int phaseIdx = 0; phaseIdx < VolumeVariables::numPhases(); ++phaseIdx) + { + out.addVolumeVariable([phaseIdx](const auto& v){ return v.saturation(phaseIdx); }, + IOName::saturation<FluidSystem>(phaseIdx)); + out.addVolumeVariable([phaseIdx](const auto& v){ return v.pressure(phaseIdx); }, + IOName::pressure<FluidSystem>(phaseIdx)); + out.addVolumeVariable([phaseIdx](const auto& v){ return v.density(phaseIdx); }, + IOName::density<FluidSystem>(phaseIdx)); + out.addVolumeVariable([phaseIdx](const auto& v){ return v.mobility(phaseIdx); }, + IOName::mobility<FluidSystem>(phaseIdx)); + out.addVolumeVariable([phaseIdx](const auto& v){ return v.viscosity(phaseIdx); }, + IOName::viscosity<FluidSystem>(phaseIdx)); - for (int i = 0; i < VolumeVariables::numPhases(); ++i) - for (int j = 0; j < VolumeVariables::numComponents(); ++j) - out.addVolumeVariable([i,j](const auto& v){ return v.moleFraction(i,j); }, - "x^" + FluidSystem::componentName(j) + "_" + FluidSystem::phaseName(i)); + for (int compIdx = 0; compIdx < VolumeVariables::numComponents(); ++compIdx) + out.addVolumeVariable([phaseIdx, compIdx](const auto& v){ return v.moleFraction(phaseIdx, compIdx); }, + IOName::moleFraction<FluidSystem>(phaseIdx, compIdx)); + } - out.addVolumeVariable( [](const auto& v){ return v.porosity(); },"porosity"); - out.addVolumeVariable( [](const auto& v){ return v.priVars().state(); },"phase presence"); - out.addVolumeVariable( [](const auto& v){ return v.permeability(); },"permeability"); + out.addVolumeVariable([](const auto& v){ return v.porosity(); }, + IOName::porosity()); + out.addVolumeVariable([](const auto& v){ return v.priVars().state(); }, + IOName::phasePresence()); + out.addVolumeVariable([](const auto& v){ return v.permeability(); }, + IOName::permeability()); } template <class OutputModule> @@ -82,44 +85,44 @@ public: { case Indices::threePhases: { - const std::vector<std::string> s1 = {"p_g", - "S_w", - "S_n"}; + const std::vector<std::string> s1 = {IOName::pressure<FluidSystem>(FluidSystem::gPhaseIdx), + IOName::saturation<FluidSystem>(FluidSystem::wPhaseIdx), + IOName::saturation<FluidSystem>(FluidSystem::nPhaseIdx)}; return s1[pvIdx]; } case Indices::wPhaseOnly: { - const std::vector<std::string> s2 = {"p_w", - "T", - "x^" + FluidSystem::componentName(FluidSystem::nCompIdx) + "_" + FluidSystem::phaseName(FluidSystem::wPhaseIdx)}; + const std::vector<std::string> s2 = {IOName::pressure<FluidSystem>(FluidSystem::wPhaseIdx), + IOName::temperature(), + IOName::moleFraction<FluidSystem>(FluidSystem::wPhaseIdx, FluidSystem::nCompIdx)}; return s2[pvIdx]; } case Indices::gnPhaseOnly: { - const std::vector<std::string> s3 = {"p_g", - "S_n", - "x^" + FluidSystem::componentName(FluidSystem::wCompIdx) + "_" + FluidSystem::phaseName(FluidSystem::nPhaseIdx)}; + const std::vector<std::string> s3 = {IOName::pressure<FluidSystem>(FluidSystem::gPhaseIdx), + IOName::saturation<FluidSystem>(FluidSystem::nPhaseIdx), + IOName::moleFraction<FluidSystem>(FluidSystem::nPhaseIdx, FluidSystem::wCompIdx)}; return s3[pvIdx]; } case Indices::wnPhaseOnly: { - const std::vector<std::string> s4 = {"p_w", - "T", - "S_n"}; + const std::vector<std::string> s4 = {IOName::pressure<FluidSystem>(FluidSystem::wPhaseIdx), + IOName::temperature(), + IOName::saturation<FluidSystem>(FluidSystem::nPhaseIdx)}; return s4[pvIdx]; } case Indices::gPhaseOnly: { - const std::vector<std::string> s5 = {"p_g", - "T", - "x^" + FluidSystem::componentName(FluidSystem::nCompIdx) + "_" + FluidSystem::phaseName(FluidSystem::gPhaseIdx)}; + const std::vector<std::string> s5 = {IOName::pressure<FluidSystem>(FluidSystem::gPhaseIdx), + IOName::temperature(), + IOName::moleFraction<FluidSystem>(FluidSystem::gPhaseIdx, FluidSystem::nCompIdx)}; return s5[pvIdx]; } case Indices::wgPhaseOnly: { - const std::vector<std::string> s6 = {"p_g", - "S_w", - "x^" + FluidSystem::componentName(FluidSystem::nCompIdx) + "_" + FluidSystem::phaseName(FluidSystem::gPhaseIdx)}; + const std::vector<std::string> s6 = {IOName::pressure<FluidSystem>(FluidSystem::gPhaseIdx), + IOName::saturation<FluidSystem>(FluidSystem::wPhaseIdx), + IOName::moleFraction<FluidSystem>(FluidSystem::gPhaseIdx, FluidSystem::nCompIdx)}; return s6[pvIdx]; } } diff --git a/dumux/porousmediumflow/mineralization/iofields.hh b/dumux/porousmediumflow/mineralization/iofields.hh index e6e750f331473f27afdd274f4f86d323970af1bf..529e64c8c5f469251c28f1d2377c4d8991759304 100644 --- a/dumux/porousmediumflow/mineralization/iofields.hh +++ b/dumux/porousmediumflow/mineralization/iofields.hh @@ -25,6 +25,8 @@ #ifndef DUMUX_MINERALIZATION_IO_FIELDS_HH #define DUMUX_MINERALIZATION_IO_FIELDS_HH +#include <dumux/io/name.hh> + namespace Dumux { /*! @@ -46,7 +48,8 @@ public: // additional output for (int i = 0; i < SolidSystem::numComponents - SolidSystem::numInertComponents; ++i) { - out.addVolumeVariable([i](const auto& v){ return v.solidVolumeFraction(i); },"precipitateVolumeFraction^"+ SolidSystem::componentName(i)); + out.addVolumeVariable([i](const auto& v){ return v.solidVolumeFraction(i); }, + IOName::solidVolumeFraction<SolidSystem>(i)); } } @@ -63,7 +66,7 @@ public: if (pvIdx < nonMineralizationNumEq) return NonMineralizationIOFields::template primaryVariableName<FluidSystem, SolidSystem>(pvIdx, state); else - return "precipitateVolumeFraction^" + SolidSystem::componentName(pvIdx - nonMineralizationNumEq); + return IOName::solidVolumeFraction<SolidSystem>(pvIdx - nonMineralizationNumEq); } }; diff --git a/dumux/porousmediumflow/mpnc/iofields.hh b/dumux/porousmediumflow/mpnc/iofields.hh index 849c7193b97a129c8c33db48df647a7056276936..7a51660f407f7d41d5bab318c3c2e52994030650 100644 --- a/dumux/porousmediumflow/mpnc/iofields.hh +++ b/dumux/porousmediumflow/mpnc/iofields.hh @@ -24,6 +24,8 @@ #ifndef DUMUX_MPNC_IO_FIELDS_HH #define DUMUX_MPNC_IO_FIELDS_HH +#include <dumux/io/name.hh> + namespace Dumux { /*! @@ -41,18 +43,29 @@ public: for (int i = 0; i < VolumeVariables::numPhases(); ++i) { - out.addVolumeVariable([i](const auto& v){ return v.saturation(i); }, "S_"+ FluidSystem::phaseName(i)); - out.addVolumeVariable([i](const auto& v){ return v.pressure(i); }, "p_"+ FluidSystem::phaseName(i)); - out.addVolumeVariable([i](const auto& v){ return v.density(i); }, "rho_"+ FluidSystem::phaseName(i)); - out.addVolumeVariable([i](const auto& v){ return v.mobility(i); },"mob_"+ FluidSystem::phaseName(i)); + out.addVolumeVariable([i](const auto& v){ return v.saturation(i); }, + IOName::saturation<FluidSystem>(i)); + out.addVolumeVariable([i](const auto& v){ return v.pressure(i); }, + IOName::pressure<FluidSystem>(i)); + out.addVolumeVariable([i](const auto& v){ return v.density(i); }, + IOName::density<FluidSystem>(i)); + out.addVolumeVariable([i](const auto& v){ return v.mobility(i); }, + IOName::mobility<FluidSystem>(i)); for (int j = 0; j < VolumeVariables::numComponents(); ++j) - vtk.addVolumeVariable([i,j](const auto& v){ return v.moleFraction(i,j); }, - "x^"+ FluidSystem::componentName(j) + "_" + FluidSystem::phaseName(i)); + out.addVolumeVariable([i,j](const auto& v){ return v.moleFraction(i,j); }, + IOName::moleFraction<FluidSystem>(i, j)); } - for (int j = 0; j < VolumeVariables::numComponents(); ++j) - vtk.addVolumeVariable([j](const auto& v){ return v.fugacity(j); }, - "fugacity^"+ FluidSystem::componentName(j)); + + out.addVolumeVariable([](const auto& v){ return v.porosity(); }, + IOName::porosity()); + } + + template <class OutputModule> + DUNE_DEPRECATED_MSG("use initOutputModule instead") + static void init(OutputModule& out) + { + initOutputModule(out); } }; diff --git a/dumux/porousmediumflow/nonequilibrium/iofields.hh b/dumux/porousmediumflow/nonequilibrium/iofields.hh index 04254269e445e219f5f02a0f7a04af7d613d6e1e..bece5487af87212978d1c8b8951b96f903e2bcf2 100644 --- a/dumux/porousmediumflow/nonequilibrium/iofields.hh +++ b/dumux/porousmediumflow/nonequilibrium/iofields.hh @@ -24,6 +24,8 @@ #ifndef DUMUX_NONEQUILBRIUM_OUTPUT_FIELDS_HH #define DUMUX_NONEQUILBRIUM_OUTPUT_FIELDS_HH +#include <dumux/io/name.hh> + namespace Dumux { /*! @@ -41,9 +43,10 @@ public: EquilibriumIOFields::initOutputModule(out); for (int i = 0; i < ModelTraits::numEnergyEqFluid(); ++i) - out.addVolumeVariable( [i](const auto& v){ return v.temperatureFluid(i); }, "T_" + FluidSystem::phaseName(i) ); - for (int i = 0; i < ModelTraits::numEnergyEqSolid(); ++i) - out.addVolumeVariable( [i](const auto& v){ return v.temperatureSolid(); }, "T_s" ); + out.addVolumeVariable([i](const auto& v){ return v.temperatureFluid(i); }, + IOName::fluidTemperature<FluidSystem>(i)); + out.addVolumeVariable([](const auto& v){ return v.temperatureSolid(); }, + IOName::solidTemperature()); for (int i = 0; i < ModelTraits::numPhases(); ++i){ out.addVolumeVariable( [i](const auto& v){ return v.reynoldsNumber(i); }, "reynoldsNumber_" + FluidSystem::phaseName(i) ); out.addVolumeVariable( [i](const auto& v){ return v.nusseltNumber(i); }, "nusseltNumber_" + FluidSystem::phaseName(i) ); diff --git a/dumux/porousmediumflow/nonisothermal/iofields.hh b/dumux/porousmediumflow/nonisothermal/iofields.hh index 21964ab359496f5c8048ac62462f6ef9e7ae40fd..3ef98a1259f02bc79e9152a712ae62711039bd3b 100644 --- a/dumux/porousmediumflow/nonisothermal/iofields.hh +++ b/dumux/porousmediumflow/nonisothermal/iofields.hh @@ -24,6 +24,8 @@ #ifndef DUMUX_ENERGY_OUTPUT_FIELDS_HH #define DUMUX_ENERGY_OUTPUT_FIELDS_HH +#include <dumux/io/name.hh> + namespace Dumux { /*! @@ -39,7 +41,8 @@ public: static void initOutputModule(OutputModule& out) { IsothermalIOFields::initOutputModule(out); - out.addVolumeVariable( [](const auto& v){ return v.temperature(); }, "T"); + out.addVolumeVariable( [](const auto& v){ return v.temperature(); }, + IOName::temperature()); } template <class OutputModule> @@ -55,7 +58,7 @@ public: if (pvIdx < ModelTraits::numEq() - 1) return IsothermalIOFields::template primaryVariableName<FluidSystem, SolidSystem>(pvIdx, state); else - return "T"; + return IOName::temperature(); } }; diff --git a/dumux/porousmediumflow/richards/iofields.hh b/dumux/porousmediumflow/richards/iofields.hh index 071384df5efbdfe1f86cb2532af92013fa510b58..cd2b4a05b2ca5eea89c79d07e6c5ed9b9c61c458 100644 --- a/dumux/porousmediumflow/richards/iofields.hh +++ b/dumux/porousmediumflow/richards/iofields.hh @@ -25,6 +25,7 @@ #define DUMUX_RICHARDS_IO_FIELDS_HH #include <dumux/common/parameters.hh> +#include <dumux/io/name.hh> namespace Dumux { @@ -39,28 +40,41 @@ public: template <class OutputModule> static void initOutputModule(OutputModule& out) { - using VolumeVariables = typename VtkOutputModule::VolumeVariables; + using VolumeVariables = typename OutputModule::VolumeVariables; using FS = typename VolumeVariables::FluidSystem; - out.addVolumeVariable([](const auto& v){ return v.saturation(FS::liquidPhaseIdx); }, "S_"+FS::phaseName(FS::liquidPhaseIdx)); - out.addVolumeVariable([](const auto& v){ return v.saturation(FS::gasPhaseIdx); }, "S_"+FS::phaseName(FS::gasPhaseIdx)); - out.addVolumeVariable([](const auto& v){ return v.pressure(FS::liquidPhaseIdx); }, "p_"+FS::phaseName(FS::liquidPhaseIdx)); - out.addVolumeVariable([](const auto& v){ return v.pressure(FS::gasPhaseIdx); }, "p_"+FS::phaseName(FS::gasPhaseIdx)); - out.addVolumeVariable([](const auto& v){ return v.capillaryPressure(); }, "pc"); - out.addVolumeVariable([](const auto& v){ return v.density(FS::liquidPhaseIdx); }, "rho_"+FS::phaseName(FS::liquidPhaseIdx)); - out.addVolumeVariable([](const auto& v){ return v.mobility(FS::liquidPhaseIdx); }, "mob_"+FS::phaseName(FS::liquidPhaseIdx)); - out.addVolumeVariable([](const auto& v){ return v.relativePermeability(FS::liquidPhaseIdx); }, "kr"); - out.addVolumeVariable([](const auto& v){ return v.porosity(); }, "porosity"); + out.addVolumeVariable([](const auto& v){ return v.saturation(FS::liquidPhaseIdx); }, + IOName::saturation<FS>(FS::liquidPhaseIdx)); + out.addVolumeVariable([](const auto& v){ return v.saturation(FS::gasPhaseIdx); }, + IOName::saturation<FS>(FS::gasPhaseIdx)); + out.addVolumeVariable([](const auto& v){ return v.pressure(FS::liquidPhaseIdx); }, + IOName::pressure<FS>(FS::liquidPhaseIdx)); + out.addVolumeVariable([](const auto& v){ return v.pressure(FS::gasPhaseIdx); }, + IOName::pressure<FS>(FS::gasPhaseIdx)); + out.addVolumeVariable([](const auto& v){ return v.capillaryPressure(); }, + IOName::capillaryPressure()); + out.addVolumeVariable([](const auto& v){ return v.density(FS::liquidPhaseIdx); }, + IOName::density<FS>(FS::liquidPhaseIdx)); + out.addVolumeVariable([](const auto& v){ return v.mobility(FS::liquidPhaseIdx); }, + IOName::mobility<FS>(FS::liquidPhaseIdx)); + out.addVolumeVariable([](const auto& v){ return v.relativePermeability(FS::liquidPhaseIdx); }, + IOName::relativePermeability<FS>(FS::liquidPhaseIdx)); + out.addVolumeVariable([](const auto& v){ return v.porosity(); }, + IOName::porosity()); static const bool gravity = getParamFromGroup<bool>(out.paramGroup(), "Problem.EnableGravity"); if(gravity) - out.addVolumeVariable([](const auto& v){ return v.pressureHead(FS::liquidPhaseIdx); }, "pressure head"); + out.addVolumeVariable([](const auto& v){ return v.pressureHead(FS::liquidPhaseIdx); }, + IOName::pressureHead()); if (enableWaterDiffusionInAir) - out.addVolumeVariable([](const auto& v){ return v.moleFraction(1, 0); }, "x^"+FS::componentName(FS::gasCompIdx)+"_"+FS::phaseName(FS::liquidPhaseIdx)); - out.addVolumeVariable([](const auto& v){ return v.waterContent(FS::liquidPhaseIdx); },"water content"); + out.addVolumeVariable([](const auto& v){ return v.moleFraction(FS::gasPhaseIdx, FS::liquidCompIdx); }, + IOName::moleFraction<FS>(FS::gasPhaseIdx, FS::liquidCompIdx)); + out.addVolumeVariable([](const auto& v){ return v.waterContent(FS::liquidPhaseIdx); }, + IOName::waterContent()); - out.addVolumeVariable([](const auto& v){ return v.priVars().state(); }, "phase presence"); + out.addVolumeVariable([](const auto& v){ return v.priVars().state(); }, + IOName::phasePresence()); } template <class OutputModule> @@ -70,13 +84,14 @@ public: initOutputModule(out); } - template<class FluidSystem = void, class SolidSystem = void> + template<class FluidSystem, class SolidSystem = void> static std::string primaryVariableName(int pvIdx, int state) { if (state == Indices::gasPhaseOnly) - return "x^w_n"; + return IOName::moleFraction<FluidSystem>(FluidSystem::gasPhaseIdx, + FluidSystem::liquidCompIdx); else - return "p_w"; + return IOName::pressure<FluidSystem>(FluidSystem::liquidPhaseIdx); } }; diff --git a/dumux/porousmediumflow/richards/model.hh b/dumux/porousmediumflow/richards/model.hh index 642e0325356d15d4818293b73c0d53598989354a..f1958f5691156222d4529fae1ddcfc1c676a9809 100644 --- a/dumux/porousmediumflow/richards/model.hh +++ b/dumux/porousmediumflow/richards/model.hh @@ -143,7 +143,7 @@ struct RichardsModelTraits return "x^" + FluidSystem::componentName(FluidSystem::comp0Idx) + "_" + FluidSystem::phaseName(FluidSystem::phase1Idx); else - return "p_" + FluidSystem::phaseName(FluidSystem::phase0Idx); + return IOName::pressure<FluidSystem>(FluidSystem::phase0Idx); } }; diff --git a/dumux/porousmediumflow/richardsnc/iofields.hh b/dumux/porousmediumflow/richardsnc/iofields.hh index 89209368e0a97e01522e3c25648d62055edad398..1dd65fbe046cd752779b791ed4954c361e6e24df 100644 --- a/dumux/porousmediumflow/richardsnc/iofields.hh +++ b/dumux/porousmediumflow/richardsnc/iofields.hh @@ -25,6 +25,7 @@ #define DUMUX_RICHARDSNC_IO_FIELDS_HH #include <dumux/common/parameters.hh> +#include <dumux/io/name.hh> namespace Dumux { @@ -42,25 +43,37 @@ public: using VolumeVariables = typename OutputModule::VolumeVariables; using FS = typename VolumeVariables::FluidSystem; - out.addVolumeVariable([](const auto& v){ return v.saturation(VolumeVariables::liquidPhaseIdx); }, "S_"+FS::phaseName(VolumeVariables::liquidPhaseIdx)); - out.addVolumeVariable([](const auto& v){ return v.saturation(VolumeVariables::gasPhaseIdx); }, "S_gas"); - out.addVolumeVariable([](const auto& v){ return v.pressure(VolumeVariables::liquidPhaseIdx); }, "p_"+FS::phaseName(VolumeVariables::liquidPhaseIdx)); - out.addVolumeVariable([](const auto& v){ return v.pressure(VolumeVariables::gasPhaseIdx); }, "p_gas"); - out.addVolumeVariable([](const auto& v){ return v.capillaryPressure(); }, "pc"); - out.addVolumeVariable([](const auto& v){ return v.density(FS::liquidPhaseIdx); }, "rho_"+FS::phaseName(FS::liquidPhaseIdx)); - out.addVolumeVariable([](const auto& v){ return v.mobility(FS::liquidPhaseIdx); }, "mob_"+FS::phaseName(FS::liquidPhaseIdx)); - out.addVolumeVariable([](const auto& v){ return v.relativePermeability(VolumeVariables::liquidPhaseIdx); }, "kr"); - out.addVolumeVariable([](const auto& v){ return v.porosity(); }, "porosity"); - out.addVolumeVariable([](const auto& v){ return v.temperature(); }, "T"); + out.addVolumeVariable([](const auto& v){ return v.saturation(VolumeVariables::liquidPhaseIdx); }, + IOName::saturation() + "_" + IOName::liquid()); + out.addVolumeVariable([](const auto& v){ return v.saturation(VolumeVariables::gasPhaseIdx); }, + IOName::saturation() + "_" + IOName::gaseous()); + out.addVolumeVariable([](const auto& v){ return v.pressure(VolumeVariables::liquidPhaseIdx); }, + IOName::pressure() + "_" + IOName::liquid()); + out.addVolumeVariable([](const auto& v){ return v.pressure(VolumeVariables::gasPhaseIdx); }, + IOName::pressure() + "_" + IOName::gaseous()); + out.addVolumeVariable([](const auto& v){ return v.capillaryPressure(); }, + IOName::capillaryPressure()); + out.addVolumeVariable([](const auto& v){ return v.density(FS::liquidPhaseIdx); }, + IOName::density() + "_" + IOName::liquid()); + out.addVolumeVariable([](const auto& v){ return v.mobility(FS::liquidPhaseIdx); }, + IOName::mobility() + "_" + IOName::liquid()); + out.addVolumeVariable([](const auto& v){ return v.relativePermeability(VolumeVariables::liquidPhaseIdx); }, + IOName::relativePermeability() + "_" + IOName::liquid()); + out.addVolumeVariable([](const auto& v){ return v.porosity(); }, + IOName::porosity()); + out.addVolumeVariable([](const auto& v){ return v.temperature(); }, + IOName::temperature()); static const bool gravity = getParamFromGroup<bool>(out.paramGroup(), "Problem.EnableGravity"); - if(gravity) - out.addVolumeVariable([](const auto& v){ return v.pressureHead(VolumeVariables::liquidPhaseIdx); }, "pressure head"); - out.addVolumeVariable([](const auto& v){ return v.waterContent(VolumeVariables::liquidPhaseIdx); },"water content"); + if (gravity) + out.addVolumeVariable([](const auto& v){ return v.pressureHead(VolumeVariables::liquidPhaseIdx); }, + IOName::pressureHead()); + out.addVolumeVariable([](const auto& v){ return v.waterContent(VolumeVariables::liquidPhaseIdx); }, + IOName::waterContent()); for (int compIdx = 0; compIdx < VolumeVariables::numComponents(); ++compIdx) out.addVolumeVariable([compIdx](const auto& v){ return v.moleFraction(VolumeVariables::liquidPhaseIdx, compIdx); }, - "x^" + FS::componentName(compIdx) + "_" + FS::phaseName(VolumeVariables::liquidPhaseIdx)); + IOName::moleFraction<FS>(VolumeVariables::liquidPhaseIdx, compIdx)); } @@ -74,12 +87,11 @@ public: template <class FluidSystem, class SolidSystem = void> static std::string primaryVariableName(int pvIdx, int state = 0) { - const std::string xString = useMoles ? "x" : "X"; if (pvIdx == 0) - return "p_" + FluidSystem::phaseName(0); + return IOName::pressure<FluidSystem>(0); else - return xString + "^" + FluidSystem::componentName(pvIdx) - + "_" + FluidSystem::phaseName(0); + return useMoles ? IOName::moleFraction<FluidSystem>(0, pvIdx) + : IOName::massFraction<FluidSystem>(0, pvIdx); } }; diff --git a/dumux/porousmediumflow/richardsnc/model.hh b/dumux/porousmediumflow/richardsnc/model.hh index 6499f65f7e2c467c937b998a716f4dc7422e264e..3e2a11e980566a0bd1bd8f50916c42495dcc9de7 100644 --- a/dumux/porousmediumflow/richardsnc/model.hh +++ b/dumux/porousmediumflow/richardsnc/model.hh @@ -120,7 +120,7 @@ struct RichardsNCModelTraits { const std::string xString = useMoles() ? "x" : "X"; if (pvIdx == 0) - return "p_" + FluidSystem::phaseName(0); + return IOName::pressure<FluidSystem>(0); else return xString + "^" + FluidSystem::componentName(pvIdx) + "_" + FluidSystem::phaseName(0); diff --git a/dumux/porousmediumflow/tracer/iofields.hh b/dumux/porousmediumflow/tracer/iofields.hh index e89cca86c39cf9caa1ec33771b44986b8653957d..bebeae230750d543181671eff72d9d26a2d78942 100644 --- a/dumux/porousmediumflow/tracer/iofields.hh +++ b/dumux/porousmediumflow/tracer/iofields.hh @@ -26,6 +26,8 @@ #include <string> +#include <dumux/io/name.hh> + namespace Dumux { /*! @@ -45,12 +47,12 @@ public: // register standardized out output fields for (int compIdx = 0; compIdx < VolumeVariables::numComponents(); ++compIdx) { - out.addVolumeVariable( [compIdx](const auto& v){ return v.moleFraction(0, compIdx); }, - "x^" + std::string(FluidSystem::componentName(compIdx))); - out.addVolumeVariable( [compIdx](const auto& v){ return v.massFraction(0, compIdx); }, - "X^" + std::string(FluidSystem::componentName(compIdx))); + out.addVolumeVariable([compIdx](const auto& v){ return v.moleFraction(0, compIdx); }, + "x^" + FluidSystem::componentName(compIdx)); + out.addVolumeVariable([compIdx](const auto& v){ return v.massFraction(0, compIdx); }, + "X^" + FluidSystem::componentName(compIdx)); } - out.addVolumeVariable( [](const auto& v){ return v.density(); }, "rho"); + out.addVolumeVariable( [](const auto& v){ return v.density(); }, IOName::density()); } template <class OutputModule> diff --git a/test/porousmediumflow/2p2c/implicit/mpnccomparison/iofields.hh b/test/porousmediumflow/2p2c/implicit/mpnccomparison/iofields.hh index 5db6b4d1d1bdc8e02c9d074fbabe3aa2a9ebc0a7..8f42a26678436aa4ddeea0ee46b1aac372324419 100644 --- a/test/porousmediumflow/2p2c/implicit/mpnccomparison/iofields.hh +++ b/test/porousmediumflow/2p2c/implicit/mpnccomparison/iofields.hh @@ -24,6 +24,8 @@ #ifndef DUMUX_TWOPTWOC_MPNC_IO_FIELDS_HH #define DUMUX_TWOPTWOC_MPNC_IO_FIELDS_HH +#include <dumux/io/name.hh> + namespace Dumux { /*! @@ -40,24 +42,38 @@ public: using FS = typename VolumeVariables::FluidSystem; // register standardized output fields - out.addVolumeVariable([](const auto& v){ return v.porosity(); }, "porosity"); - out.addVolumeVariable([](const auto& v){ return v.saturation(FS::phase0Idx); }, "S_"+ FS::phaseName(FS::phase0Idx)); - out.addVolumeVariable([](const auto& v){ return v.saturation(FS::phase1Idx); }, "S_"+ FS::phaseName(FS::phase1Idx)); - out.addVolumeVariable([](const auto& v){ return v.pressure(FS::phase0Idx); }, "p_"+ FS::phaseName(FS::phase0Idx)); - out.addVolumeVariable([](const auto& v){ return v.pressure(FS::phase1Idx); }, "p_"+ FS::phaseName(FS::phase1Idx)); + out.addVolumeVariable([](const auto& v){ return v.porosity(); }, + IOName::porosity()); + + out.addVolumeVariable([](const auto& v){ return v.saturation(FS::phase0Idx); }, + IOName::saturation<FS>(FS::phase0Idx)); + out.addVolumeVariable([](const auto& v){ return v.saturation(FS::phase1Idx); }, + IOName::saturation<FS>(FS::phase1Idx)); + + out.addVolumeVariable([](const auto& v){ return v.pressure(FS::phase0Idx); }, + IOName::pressure<FS>(FS::phase0Idx)); + out.addVolumeVariable([](const auto& v){ return v.pressure(FS::phase1Idx); }, + IOName::pressure<FS>(FS::phase1Idx)); + + out.addVolumeVariable([](const auto& v){ return v.density(FS::phase0Idx); }, + IOName::density<FS>(FS::phase0Idx)); + out.addVolumeVariable([](const auto& v){ return v.density(FS::phase1Idx); }, + IOName::density<FS>(FS::phase1Idx)); - out.addVolumeVariable([](const auto& v){ return v.density(FS::phase0Idx); }, "rho_"+ FS::phaseName(FS::phase0Idx)); - out.addVolumeVariable([](const auto& v){ return v.density(FS::phase1Idx); }, "rho_"+ FS::phaseName(FS::phase1Idx)); - out.addVolumeVariable([](const auto& v){ return v.mobility(FS::phase0Idx); }, "mob_"+ FS::phaseName(FS::phase0Idx)); - out.addVolumeVariable([](const auto& v){ return v.mobility(FS::phase1Idx); }, "mob_"+ FS::phaseName(FS::phase1Idx)); + out.addVolumeVariable([](const auto& v){ return v.mobility(FS::phase0Idx); }, + IOName::mobility<FS>(FS::phase0Idx)); + out.addVolumeVariable([](const auto& v){ return v.mobility(FS::phase1Idx); }, + IOName::mobility<FS>(FS::phase1Idx)); for (int i = 0; i < VolumeVariables::numPhases(); ++i) for (int j = 0; j < VolumeVariables::numComponents(); ++j) - out.addVolumeVariable([i,j](const auto& v){ return v.massFraction(i,j); },"X^"+ FS::componentName(j) + "_" + FS::phaseName(i)); + out.addVolumeVariable([i,j](const auto& v){ return v.massFraction(i,j); }, + IOName::massFraction<FS>(i, j)); for (int i = 0; i < VolumeVariables::numPhases(); ++i) for (int j = 0; j < VolumeVariables::numComponents(); ++j) - out.addVolumeVariable([i,j](const auto& v){ return v.moleFraction(i,j); },"x^"+ FS::componentName(j) + "_" + FS::phaseName(i)); + out.addVolumeVariable([i,j](const auto& v){ return v.moleFraction(i,j); }, + IOName::moleFraction<FS>(i, j)); } template <class OutputModule> diff --git a/test/references/3pwateroilbox-reference.vtu b/test/references/3pwateroilbox-reference.vtu index 8bb9a595ab92864d331f866eaa71aebfc9f89c82..2416e05561511454ac4ee7541c17a92629fe990d 100644 --- a/test/references/3pwateroilbox-reference.vtu +++ b/test/references/3pwateroilbox-reference.vtu @@ -2535,7 +2535,7 @@ 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 </DataArray> - <DataArray type="Float32" Name="viscos_aq" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="mu_aq" NumberOfComponents="1" format="ascii"> 0.000954057 0.000954014 0.000954032 0.000953987 0.000953936 0.000953917 0.000953862 0.000953846 0.000953803 0.000953789 0.00095376 0.000953749 0.000953733 0.000953725 0.00095372 0.000953715 0.000953718 0.000953715 0.000953725 0.000953724 0.000953739 0.000953738 0.000953757 0.000953757 0.000953778 0.000953779 0.000953802 0.000953803 0.000953827 0.000953829 0.000953854 0.000953856 0.000953881 0.000953883 0.000953909 0.00095391 @@ -2746,7 +2746,7 @@ 0.000954929 0.000954929 0.00095493 0.00095493 0.000954931 0.000954932 0.000954932 0.000954933 0.000954933 0.000954934 0.000954934 0.000954935 0.000954935 0.000954936 0.000954936 0.000954936 0.000954937 </DataArray> - <DataArray type="Float32" Name="viscos_napl" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="mu_napl" NumberOfComponents="1" format="ascii"> 1739.16 1738.7 1738.82 1738.36 1737.91 1737.68 1737.17 1736.98 1736.57 1736.4 1736.14 1736 1735.87 1735.77 1735.74 1735.66 1735.72 1735.66 1735.79 1735.75 1735.92 1735.89 1736.11 1736.09 1736.33 1736.31 1736.57 1736.56 1736.83 1736.82 1737.1 1737.09 1737.38 1737.37 1737.66 1737.65 @@ -2957,7 +2957,7 @@ 1747.21 1747.22 1747.22 1747.23 1747.24 1747.24 1747.25 1747.25 1747.26 1747.26 1747.27 1747.27 1747.28 1747.28 1747.29 1747.29 1747.29 </DataArray> - <DataArray type="Float32" Name="viscos_gas" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="mu_gas" NumberOfComponents="1" format="ascii"> 5.91112e-09 5.89577e-09 5.94453e-09 5.92224e-09 5.85837e-09 5.87276e-09 5.81658e-09 5.82477e-09 5.78228e-09 5.78942e-09 5.75858e-09 5.7663e-09 5.74447e-09 5.75313e-09 5.73802e-09 5.74757e-09 5.73737e-09 5.74768e-09 5.74101e-09 5.75193e-09 5.74777e-09 5.75918e-09 5.75676e-09 5.76855e-09 5.76732e-09 5.77942e-09 5.77898e-09 5.79133e-09 5.79138e-09 5.80392e-09 5.80426e-09 5.81697e-09 5.81743e-09 5.83028e-09 5.83077e-09 5.84373e-09 diff --git a/test/references/richardsanalyticalcc-reference.vtu b/test/references/richardsanalyticalcc-reference.vtu index ed9cce9d696ea3546686deabc1d91065c24178fc..9bcbeef80d7814f386a1d1c929706bae80bf8a3b 100644 --- a/test/references/richardsanalyticalcc-reference.vtu +++ b/test/references/richardsanalyticalcc-reference.vtu @@ -318,7 +318,7 @@ 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 diff --git a/test/references/richardslensbox-reference-parallel.vtu b/test/references/richardslensbox-reference-parallel.vtu index 3c824a4e3a9a2309e8787b7c20c0d1323fdc6a34..901ca580caaa6296f63d6de186495e7f0dbf74d6 100644 --- a/test/references/richardslensbox-reference-parallel.vtu +++ b/test/references/richardslensbox-reference-parallel.vtu @@ -150,7 +150,7 @@ 146.749 164.984 146.749 3.92159 0 0 0 0 0 0 0 0.0196823 249.082 733.751 753.199 733.751 249.082 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 diff --git a/test/references/richardslensbox-reference.vtu b/test/references/richardslensbox-reference.vtu index 076c15811e15530376dc76496a5cbe583f9c6b14..32ce87a8dc41fa210ba3a9e504da695ee4999199 100644 --- a/test/references/richardslensbox-reference.vtu +++ b/test/references/richardslensbox-reference.vtu @@ -269,7 +269,7 @@ 249.082 733.751 753.199 733.751 249.082 0.0196823 0 0 0 0 0 0 0 0 0 0 0 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 diff --git a/test/references/richardslenscc-reference-parallel.vtu b/test/references/richardslenscc-reference-parallel.vtu index 64b199f8c9331191c357989572fabbf3e568eb0b..7a8a5e3c2a909beb910f9e35789c96e1760b676c 100644 --- a/test/references/richardslenscc-reference-parallel.vtu +++ b/test/references/richardslenscc-reference-parallel.vtu @@ -129,7 +129,7 @@ 0 0 0 0 0 0 0 0 10.7357 17.6661 17.6661 10.7357 0 0 0 0 0 0 0 0.0154609 407.511 473.279 473.279 407.511 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 diff --git a/test/references/richardslenscc-reference.vtu b/test/references/richardslenscc-reference.vtu index 6a548781500b09664cc0bb9d015c85d214796336..fa6c1e1b7ff7fb38be07c087ff9d65cc4fa2e1ba 100644 --- a/test/references/richardslenscc-reference.vtu +++ b/test/references/richardslenscc-reference.vtu @@ -241,7 +241,7 @@ 0 0 0 0 0 0 0 0.0154609 407.511 473.279 473.279 407.511 0.0154609 0 0 0 0 0 0 0 0 0 0 0 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 diff --git a/test/references/richardsniconductionbox-reference.vtu b/test/references/richardsniconductionbox-reference.vtu index 1986fbf328dba077c6142e1eb4529a3c4c80c603..8ee8e4fcd8bcbaf476223a64faf8041f5c6be74f 100644 --- a/test/references/richardsniconductionbox-reference.vtu +++ b/test/references/richardsniconductionbox-reference.vtu @@ -255,7 +255,7 @@ 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 diff --git a/test/references/richardsniconductioncc-reference.vtu b/test/references/richardsniconductioncc-reference.vtu index 36a22a712d441b123f7e502a11164b818e3eec20..5187408907e2504100bd71f1f235121ecc3f33e8 100644 --- a/test/references/richardsniconductioncc-reference.vtu +++ b/test/references/richardsniconductioncc-reference.vtu @@ -136,7 +136,7 @@ 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 921.392 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 diff --git a/test/references/richardsniconvectionbox-reference.vtu b/test/references/richardsniconvectionbox-reference.vtu index 72cfb75c55fadbe578e77d718ae97caa04c1e327..b751ca7007ff5e256f56a9812f1ce83927096996 100644 --- a/test/references/richardsniconvectionbox-reference.vtu +++ b/test/references/richardsniconvectionbox-reference.vtu @@ -115,7 +115,7 @@ 921.42 921.42 921.42 921.42 921.42 921.42 921.419 921.419 921.419 921.419 921.419 921.419 921.419 921.419 921.419 921.419 921.392 921.392 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 diff --git a/test/references/richardsniconvectioncc-reference.vtu b/test/references/richardsniconvectioncc-reference.vtu index e644b0e21a3495daee0bc521f40c2ae500c048e5..fdf46b11a0a8a1a6c54620b436fdf18b8d34a980 100644 --- a/test/references/richardsniconvectioncc-reference.vtu +++ b/test/references/richardsniconvectioncc-reference.vtu @@ -66,7 +66,7 @@ 921.422 921.422 921.421 921.421 921.421 921.421 921.421 921.421 921.42 921.42 921.42 921.42 921.42 921.42 921.42 921.419 921.419 921.419 921.419 921.418 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 diff --git a/test/references/richardswelltracerbox-reference.vtu b/test/references/richardswelltracerbox-reference.vtu index 5a0d6b21619195fab311b366a27a5697b3c0555e..2f22e0c79637ab7d0a51b9f114da3aaae86fc08b 100644 --- a/test/references/richardswelltracerbox-reference.vtu +++ b/test/references/richardswelltracerbox-reference.vtu @@ -647,7 +647,7 @@ 0.00249281 0.0025516 0.00264837 0.00282718 0.00320399 0.00394512 0.00523999 0.0074141 0.0116811 0.0259377 0.0944501 0.432193 2.08172 9.29282 31.8186 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 diff --git a/test/references/richardswelltracercc-reference.vtu b/test/references/richardswelltracercc-reference.vtu index df51063e775539284ba2e6e183fc2e88af6de54d..9537ef0e727cdfba1e531ef35e1b6dbd293195c2 100644 --- a/test/references/richardswelltracercc-reference.vtu +++ b/test/references/richardswelltracercc-reference.vtu @@ -605,7 +605,7 @@ 0.00614061 0.0062582 0.00646096 0.00684863 0.00773605 0.00951366 0.0130612 0.0244501 0.0786285 0.344282 1.70825 8.96678 45.2552 188.888 535.009 890.348 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 diff --git a/test/references/rosi2c-soil-reference.vtu b/test/references/rosi2c-soil-reference.vtu index 99012737accaae4a161fc62a2f6b032bb32fcdb8..176d3bdb6ad403f4dc33bbfb509eb9d77862429f 100644 --- a/test/references/rosi2c-soil-reference.vtu +++ b/test/references/rosi2c-soil-reference.vtu @@ -4686,7 +4686,7 @@ 0.000634247 0.000632533 0.000629226 0.000624564 0.0006189 0.000612694 0.000606494 0.000600903 0.000596525 0.000593887 0.00059335 0.000595015 0.000598672 0.000603847 0.000609902 0.000616155 0.00062197 0.000626811 0.000630269 0.000632067 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 6.59414e-07 6.5816e-07 6.55784e-07 6.52554e-07 6.4887e-07 6.45244e-07 6.42229e-07 6.40294e-07 6.3969e-07 6.4044e-07 6.42415e-07 6.45407e-07 6.49154e-07 6.53349e-07 6.57664e-07 6.6178e-07 6.65414e-07 6.68339e-07 6.70382e-07 6.71431e-07 6.58388e-07 6.57017e-07 6.54406e-07 6.5083e-07 6.46713e-07 6.42635e-07 6.39255e-07 6.37145e-07 6.3656e-07 6.37457e-07 6.39653e-07 6.42918e-07 6.4698e-07 6.51511e-07 6.56152e-07 6.60561e-07 diff --git a/test/references/test_boxrichardsevaporation-reference.vtu b/test/references/test_boxrichardsevaporation-reference.vtu index 45135a776820db34e89f4b49aaefd264b5ae7121..ad98f26f49c1170a10409fd4ed9ca24d98ac25d3 100644 --- a/test/references/test_boxrichardsevaporation-reference.vtu +++ b/test/references/test_boxrichardsevaporation-reference.vtu @@ -94,7 +94,7 @@ 0.000207045 0.000207045 0.000207045 0.000207045 0.000207045 0.000207045 0.000206541 0.000206541 0.000206541 0.000206541 0.000206541 0.000206541 0 0 0 0 0 0 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 diff --git a/test/references/test_ccrichardsevaporation-reference.vtu b/test/references/test_ccrichardsevaporation-reference.vtu index 14e279ed93ec2aee760d67e673dca46cbbc1eb0c..85fe61c8e8f93ac04d58a4b653b6d51d2cd40047 100644 --- a/test/references/test_ccrichardsevaporation-reference.vtu +++ b/test/references/test_ccrichardsevaporation-reference.vtu @@ -80,7 +80,7 @@ 0.000207047 0.000207046 0.000207046 0.000207046 0.000207046 0.000207046 0.000206733 0.000206733 0.000206733 0.000206733 0.000206733 0 0 0 0 0 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 2.18844e-07 diff --git a/test/references/test_embedded_1d3d_1p2c_richards2c_3d-reference.vtu b/test/references/test_embedded_1d3d_1p2c_richards2c_3d-reference.vtu index 606678d167cfcb93761a053917008eac95a16814..ac4cc1591fccbc63635d80f2f4585ee9164e5de3 100644 --- a/test/references/test_embedded_1d3d_1p2c_richards2c_3d-reference.vtu +++ b/test/references/test_embedded_1d3d_1p2c_richards2c_3d-reference.vtu @@ -1886,7 +1886,7 @@ 0.0127774 0.0126583 0.0122684 0.0123525 0.0125632 0.0125142 0.0122497 0.0123338 0.0125387 0.0124892 0.0124988 0.0126437 0.0127594 0.0126619 0.0124716 0.0126137 0.0127273 0.0126335 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 1.44809e-05 1.44681e-05 1.44481e-05 1.44309e-05 1.44253e-05 1.44355e-05 1.44585e-05 1.44872e-05 1.45122e-05 1.45267e-05 1.44751e-05 1.44594e-05 1.44341e-05 1.44133e-05 1.44055e-05 1.44179e-05 1.44452e-05 1.44789e-05 1.45076e-05 1.45239e-05 1.4468e-05 1.44479e-05 1.44141e-05 1.43748e-05 1.43911e-05 1.44245e-05 1.4467e-05 1.4502e-05 1.45212e-05 1.44672e-05 1.44446e-05 1.44066e-05 1.43525e-05 1.44114e-05 1.44612e-05 1.45016e-05 diff --git a/test/references/test_embedded_1p_richards_box_3d.vtu b/test/references/test_embedded_1p_richards_box_3d.vtu index 335590ba65e26809d475d6df6bb713d8a6f39a22..ac4accc8b0d5ae3d8b8f82da6296a5637a6da72c 100644 --- a/test/references/test_embedded_1p_richards_box_3d.vtu +++ b/test/references/test_embedded_1p_richards_box_3d.vtu @@ -1305,7 +1305,7 @@ 0.000853228 0.000849936 0.000840787 0.000827768 0.000813799 0.000802194 0.00079593 0.000796775 0.000804455 0.000816508 0.000829133 0.000838513 0.000841964 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 1.00391e-06 1.00242e-06 1.00366e-06 1.00206e-06 9.95402e-07 9.93208e-07 9.94817e-07 9.92198e-07 9.98992e-07 9.98387e-07 9.8792e-07 9.85599e-07 9.96116e-07 9.95527e-07 9.83273e-07 9.78899e-07 9.96344e-07 9.9544e-07 9.83048e-07 9.78762e-07 1.00053e-06 9.99215e-07 9.88161e-07 9.85146e-07 1.00794e-06 1.00648e-06 9.96855e-07 9.944e-07 1.01744e-06 1.01597e-06 1.00736e-06 1.00513e-06 1.02789e-06 1.0266e-06 1.01866e-06 1.01678e-06 diff --git a/test/references/test_embedded_1p_richards_tpfa_3d.vtu b/test/references/test_embedded_1p_richards_tpfa_3d.vtu index 35ff8633f6ea9eb2545b505e1aa0527291b0e9a4..7e0602b4c9f72ec3dd45736fddaec9a868126c3e 100644 --- a/test/references/test_embedded_1p_richards_tpfa_3d.vtu +++ b/test/references/test_embedded_1p_richards_tpfa_3d.vtu @@ -1025,7 +1025,7 @@ 0.00084527 0.000837485 0.000823297 0.000805259 0.000786915 0.000772548 0.000766755 0.000773315 0.000789494 0.000807961 0.000823252 0.000831811 0.000854015 0.000847195 0.000834856 0.0008194 0.000804085 0.000792642 0.000788559 0.000793778 0.000806374 0.000821398 0.000834209 0.000841488 </DataArray> - <DataArray type="Float32" Name="kr" NumberOfComponents="1" format="ascii"> + <DataArray type="Float32" Name="kr_liq" NumberOfComponents="1" format="ascii"> 1.00167e-06 9.98753e-07 9.94934e-07 9.93791e-07 9.97518e-07 1.00505e-06 1.01504e-06 1.02648e-06 1.03813e-06 1.04854e-06 1.05634e-06 1.06051e-06 1.00014e-06 9.96259e-07 9.9067e-07 9.88601e-07 9.92941e-07 1.00095e-06 1.01116e-06 1.02312e-06 1.03552e-06 1.04666e-06 1.05501e-06 1.05947e-06 9.98887e-07 9.93723e-07 9.85174e-07 9.81583e-07 9.86886e-07 9.94784e-07 1.00444e-06 1.01717e-06 1.03097e-06 1.04349e-06 1.05286e-06 1.05785e-06