diff --git a/dumux/boxmodels/2p2c/2p2cmodel.hh b/dumux/boxmodels/2p2c/2p2cmodel.hh index 9883cfb0ff75c42d87901a66bfb01c3a6ec0f243..c59755e211e2a04ed6efcc25e2d1888139447baf 100644 --- a/dumux/boxmodels/2p2c/2p2cmodel.hh +++ b/dumux/boxmodels/2p2c/2p2cmodel.hh @@ -220,9 +220,6 @@ public: setSwitched_(false); resetPhasePresence_(); - /*this->localJacobian().updateStaticData(this->curSolFunction(), - this->prevSolFunction()); - */ }; /*! @@ -668,9 +665,11 @@ protected: if (xll + xlg > xlMax) { // liquid phase appears - std::cout << "liquid phase appears at vertex " << globalIdx + /* + std::cout << "Liquid phase appears at vertex " << globalIdx << ", coordinates: " << globalPos << ", xll + xlg: " << xll + xlg << std::endl; + */ newPhasePresence = bothPhases; if (formulation == pgSl) globalSol[globalIdx][switchIdx] = 0.001; @@ -696,9 +695,11 @@ protected: if (xgl + xgg > xgMax) { // gas phase appears + /* std::cout << "gas phase appears at vertex " << globalIdx << ", coordinates: " << globalPos << ", x_gl + x_gg: " << xgl + xgg << std::endl; + */ newPhasePresence = bothPhases; if (formulation == pgSl) globalSol[globalIdx][switchIdx] = 0.999; @@ -716,9 +717,11 @@ protected: { wouldSwitch = true; // gas phase disappears + /* std::cout << "Gas phase disappears at vertex " << globalIdx << ", coordinates: " << globalPos << ", Sg: " << volVars.saturation(gPhaseIdx) << std::endl; + */ newPhasePresence = lPhaseOnly; globalSol[globalIdx][switchIdx] @@ -728,9 +731,11 @@ protected: { wouldSwitch = true; // liquid phase disappears + /* std::cout << "Liquid phase disappears at vertex " << globalIdx << ", coordinates: " << globalPos << ", Sl: " << volVars.saturation(lPhaseIdx) << std::endl; + */ newPhasePresence = gPhaseOnly; globalSol[globalIdx][switchIdx] diff --git a/dumux/boxmodels/2p2c/2p2cnewtoncontroller.hh b/dumux/boxmodels/2p2c/2p2cnewtoncontroller.hh index 0001582c22e567ec4b803f609dc6f0b8d2888177..1b4ad9376fd8d6f8ab5f390fa68750454ba2e787 100644 --- a/dumux/boxmodels/2p2c/2p2cnewtoncontroller.hh +++ b/dumux/boxmodels/2p2c/2p2cnewtoncontroller.hh @@ -68,7 +68,7 @@ public: TwoPTwoCNewtonController() { this->setRelTolerance(1e-7); - this->setTargetSteps(9); + this->setTargetSteps(10); this->setMaxSteps(18); }; diff --git a/dumux/boxmodels/2p2c/2p2cvolumevariables.hh b/dumux/boxmodels/2p2c/2p2cvolumevariables.hh index cc8a5ff625d18b7798c770ec8ec8b235178e7ef1..04734d91a29fc706ff2bc3e1081302f8ba2ec7a6 100644 --- a/dumux/boxmodels/2p2c/2p2cvolumevariables.hh +++ b/dumux/boxmodels/2p2c/2p2cvolumevariables.hh @@ -159,10 +159,10 @@ public: ///////////// // update the temperature part of the energy module Scalar T = asImp_().getTemperature(priVars, - element, - elemGeom, - scvIdx, - problem); + element, + elemGeom, + scvIdx, + problem); Valgrind::CheckDefined(T); for (int i = 0; i < numPhases; ++i) fs.setTemperature(i, T); @@ -431,15 +431,23 @@ public: #endif protected: - - Scalar getTemperature_(const PrimaryVariables &priVars, - const Element &element, - const FVElementGeometry &elemGeom, - int scvIdx, - const Problem &problem) + Scalar getTemperature(const PrimaryVariables &priVars, + const Element &element, + const FVElementGeometry &elemGeom, + int scvIdx, + const Problem &problem) { return problem.temperature(element, elemGeom, scvIdx); } + + template <class MutableParameters> + void updateEnergy(MutableParameters &mutParams, + const PrimaryVariables &priVars, + const Element &element, + const FVElementGeometry &elemGeom, + int scvIdx, + const Problem &problem) + {}; Scalar porosity_; //!< Effective porosity within the control volume Scalar mobility_[numPhases]; //!< Effective mobility within the control volume