From 373e27de9d3961a236cdb8ae9b5e34c75416928d Mon Sep 17 00:00:00 2001
From: Katharina Heck <katharina.heck@iws.uni-stuttgart.de>
Date: Wed, 20 Dec 2017 16:06:08 +0100
Subject: [PATCH] [fix][material] adapt thermalconductivitysimplefluidlumping
 to new strucutre

---
 .../thermalconductivitysimplefluidlumping.hh  | 22 ++++++++++---------
 1 file changed, 12 insertions(+), 10 deletions(-)

diff --git a/dumux/material/fluidmatrixinteractions/2p/thermalconductivitysimplefluidlumping.hh b/dumux/material/fluidmatrixinteractions/2p/thermalconductivitysimplefluidlumping.hh
index 70893500fd..87b0df4f09 100644
--- a/dumux/material/fluidmatrixinteractions/2p/thermalconductivitysimplefluidlumping.hh
+++ b/dumux/material/fluidmatrixinteractions/2p/thermalconductivitysimplefluidlumping.hh
@@ -25,23 +25,25 @@
 #define THERMALCONDUCTIVITY_SIMPLE_FLUID_LUMPING_HH
 
 #include <algorithm>
-#include <dumux/porousmediumflow/mpnc/implicit/properties.hh>
+#include <dumux/common/properties.hh>
 
 namespace Dumux
 {
+struct SimpleLumpingIndices
+{
+    static const int wPhaseIdx = 0;
+    static const int nPhaseIdx = 1;
+};
 
 /*!
  * \ingroup fluidmatrixinteractionslaws
  * \brief   Relation for the saturation-dependent effective thermal conductivity
  * \todo This shouldn't depend on TypeTag!!
  */
-template<class TypeTag>
+template<class TypeTag, class Scalar, class Indices = SimpleLumpingIndices>
 class ThermalConductivitySimpleFluidLumping
 {
-    using Scalar = typename GET_PROP_TYPE(TypeTag, Scalar);
-    using Indices = typename GET_PROP_TYPE(TypeTag, Indices);
-    enum { numEnergyEquations = GET_PROP_VALUE(TypeTag, NumEnergyEquations)};
-
+    enum { numEnergyEquationsFluid = GET_PROP_VALUE(TypeTag, NumEnergyEqFluid)};
 
 public:
     /*!
@@ -55,12 +57,12 @@ public:
      *
      * \return effective thermal conductivity \f$\mathrm{[W/(m K)]}\f$
      */
-    template<class VolumeVariables, class SpatialParams, class Element, class FVGeometry>
+    template<class VolumeVariables, class SpatialParams, class Element, class FVGeometry, class SubControlVolume>
     static Scalar effectiveThermalConductivity(const VolumeVariables& volVars,
                                                const SpatialParams& spatialParams,
                                                const Element& element,
                                                const FVGeometry& fvGeometry,
-                                               int scvIdx)
+                                               SubControlVolume& scv)
     {
         Scalar sw = volVars.saturation(Indices::wPhaseIdx);
         Scalar lambdaW = volVars.fluidThermalConductivity(Indices::wPhaseIdx);
@@ -90,7 +92,7 @@ public:
                                                const Scalar porosity,
                                                const Scalar rhoSolid = 0.0 /*unused*/)
     {
-        assert(numEnergyEquations != 3) ;
+        assert(numEnergyEquationsFluid != 2) ;
 
         // Franz Lindner / Shi & Wang 2011
         using std::max;
@@ -100,7 +102,7 @@ public:
 
         Scalar keff ;
 
-        if (numEnergyEquations == 2){ // solid dealed with individually (extra balance equation)
+        if (numEnergyEquationsFluid == 1){ // solid dealed with individually (extra balance equation)
             keff = kfeff ;
         }
         else {
-- 
GitLab