diff --git a/dumux/porousmediumflow/2pnc/iofields.hh b/dumux/porousmediumflow/2pnc/iofields.hh index 1f1ef53cd64e1e7f3e5229d7ee0a14caf945d30a..c04b98110529cef4362ab479bd29bb020ece385e 100644 --- a/dumux/porousmediumflow/2pnc/iofields.hh +++ b/dumux/porousmediumflow/2pnc/iofields.hh @@ -106,10 +106,10 @@ public: switch (ModelTraits::priVarFormulation()) { case TwoPFormulation::p0s1: - return pvIdx == 0 ? IOName::pressure<FluidSystem>(FluidSystem::wPhaseIdx) + return pvIdx == 0 ? IOName::pressure<FluidSystem>(FluidSystem::phase0Idx) : p0s1SwitchedPvNames[state-1]; case TwoPFormulation::p1s0: - return pvIdx == 0 ? IOName::pressure<FluidSystem>(FluidSystem::nPhaseIdx) + return pvIdx == 0 ? IOName::pressure<FluidSystem>(FluidSystem::phase1Idx) : p1s0SwitchedPvNames[state-1]; default: DUNE_THROW(Dune::InvalidStateException, "Invalid formulation "); } diff --git a/dumux/porousmediumflow/mineralization/iofields.hh b/dumux/porousmediumflow/mineralization/iofields.hh index 0ca489e4d42460aed372b8244521afad070f26ab..62124d295b8d040224c81f4c551980331a6ca308 100644 --- a/dumux/porousmediumflow/mineralization/iofields.hh +++ b/dumux/porousmediumflow/mineralization/iofields.hh @@ -63,10 +63,10 @@ public: template <class ModelTraits, class FluidSystem, class SolidSystem> static std::string primaryVariableName(int pvIdx, int state = 0) { - static constexpr int nonMinNumEq = ModelTraits::numEq() - ModelTraits::numSolidComp() + ModelTraits::numInertSolidComp(); + static constexpr int nonMinNumEq = ModelTraits::numEq() - ModelTraits::numSolidComps() + ModelTraits::numInertSolidComps(); if (pvIdx < nonMinNumEq) - return NonMineralizationIOFields::template primaryVariableName<FluidSystem, SolidSystem>(pvIdx, state); + return NonMineralizationIOFields::template primaryVariableName<ModelTraits, FluidSystem, SolidSystem>(pvIdx, state); else return IOName::solidVolumeFraction<SolidSystem>(pvIdx - nonMinNumEq); }