32        using VolumeVariables = 
typename OutputModule::VolumeVariables;
 
   33        using FluidSystem = 
typename VolumeVariables::FluidSystem;
 
   39        for (
int phaseIdx = 0; phaseIdx < VolumeVariables::numFluidPhases(); ++phaseIdx)
 
   41            for (
int compIdx = 0; compIdx < VolumeVariables::numFluidComponents(); ++compIdx)
 
   43                out.addVolumeVariable([phaseIdx,compIdx](
const auto& v){ 
return v.moleFraction(phaseIdx,compIdx); },
 
   45                if (VolumeVariables::numFluidComponents() < 3)
 
   46                    out.addVolumeVariable([phaseIdx,compIdx](
const auto& v){ 
return v.massFraction(phaseIdx,compIdx); },
 
   50            out.addVolumeVariable([phaseIdx](
const auto& v){ 
return v.molarDensity(phaseIdx); },
 
   54        out.addVolumeVariable([](
const auto& v){ 
return v.priVars().state(); },
 
 
   61        using Indices = 
typename ModelTraits::Indices;
 
   62        static constexpr auto numStates = 3;
 
   63        using StringVec = std::array<std::string, numStates>;
 
   66        if (state == Indices::firstPhaseOnly
 
   67            || (state == Indices::bothPhases && ModelTraits::setMoleFractionsForFirstPhase()))
 
   68            idxSecComps = FluidSystem::phase0Idx;
 
   70            idxSecComps = FluidSystem::phase1Idx;
 
   76        static const StringVec p0s1SwitchedPvNames = {
 
   83        static const StringVec p1s0SwitchedPvNames = {
 
   90        switch (ModelTraits::priVarFormulation())
 
   94                              : p0s1SwitchedPvNames[state-1];
 
   97                              : p1s0SwitchedPvNames[state-1];
 
   98        default: DUNE_THROW(Dune::InvalidStateException, 
"Invalid formulation ");