diff --git a/dumux/freeflow/rans/problem.hh b/dumux/freeflow/rans/problem.hh index dc07959d55d737905bf094498c7828f573ff8014..f7147298adbd47876394f8cc24d996ae868b3450 100644 --- a/dumux/freeflow/rans/problem.hh +++ b/dumux/freeflow/rans/problem.hh @@ -371,6 +371,28 @@ public: const Scalar karmanConstant() const { return 0.41; } + /*! + * \brief Return the turbulent Prandtl number \f$ [-] \f$ which is used to convert + * the eddy viscosity to an eddy thermal conductivity + */ + Scalar turbulentPrandtlNumber() const + { + static const Scalar turbulentPrandtlNumber + = getParamFromGroup<Scalar>(this->paramGroup(), "RANS.TurbulentPrandtlNumber", 1.0); + return turbulentPrandtlNumber; + } + + /*! + * \brief Return the turbulent Schmidt number \f$ [-] \f$ which is used to convert + * the eddy viscosity to an eddy diffusivity + */ + Scalar turbulentSchmidtNumber() const + { + static const Scalar turbulentSchmidtNumber + = getParamFromGroup<Scalar>(this->paramGroup(), "RANS.TurbulentSchmidtNumber", 1.0); + return turbulentSchmidtNumber; + } + public: std::vector<unsigned int> wallElementID_; std::vector<Scalar> wallDistance_; diff --git a/dumux/freeflow/rans/twoeq/kepsilon/volumevariables.hh b/dumux/freeflow/rans/twoeq/kepsilon/volumevariables.hh index 8edfa0e4f4e264fb026ed468e36fa6b490c148c7..b1039e9167f18fc78836b12cf27641377dab56ae 100644 --- a/dumux/freeflow/rans/twoeq/kepsilon/volumevariables.hh +++ b/dumux/freeflow/rans/twoeq/kepsilon/volumevariables.hh @@ -155,10 +155,8 @@ public: template<class Problem> void calculateEddyDiffusivity(const Problem& problem) { - static const auto turbulentSchmidtNumber - = getParamFromGroup<Scalar>(problem.paramGroup(), - "RANS.TurbulentSchmidtNumber", 1.0); - eddyDiffusivity_ = RANSParentType::kinematicEddyViscosity() / turbulentSchmidtNumber; + eddyDiffusivity_ = RANSParentType::kinematicEddyViscosity() + / problem.turbulentSchmidtNumber(); } /*! diff --git a/dumux/freeflow/rans/twoeq/komega/volumevariables.hh b/dumux/freeflow/rans/twoeq/komega/volumevariables.hh index cdf92057934863aa9dabf0bd79c47296598c0b38..7220511bee0b624f3606b858e97b6696bd6c3d5f 100644 --- a/dumux/freeflow/rans/twoeq/komega/volumevariables.hh +++ b/dumux/freeflow/rans/twoeq/komega/volumevariables.hh @@ -161,10 +161,8 @@ public: template<class Problem> void calculateEddyDiffusivity(const Problem& problem) { - static const auto turbulentSchmidtNumber - = getParamFromGroup<Scalar>(problem.paramGroup(), - "RANS.TurbulentSchmidtNumber", 1.0); - eddyDiffusivity_ = RANSParentType::kinematicEddyViscosity() / turbulentSchmidtNumber; + eddyDiffusivity_ = RANSParentType::kinematicEddyViscosity() + / problem.turbulentSchmidtNumber(); } /*! diff --git a/dumux/freeflow/rans/twoeq/lowrekepsilon/volumevariables.hh b/dumux/freeflow/rans/twoeq/lowrekepsilon/volumevariables.hh index c8bec8f87942052d5a905297a2e6d54280478551..5521c6f5fdc46788acf1b715290b43549ef55fcd 100644 --- a/dumux/freeflow/rans/twoeq/lowrekepsilon/volumevariables.hh +++ b/dumux/freeflow/rans/twoeq/lowrekepsilon/volumevariables.hh @@ -144,10 +144,8 @@ public: template<class Problem> void calculateEddyDiffusivity(const Problem& problem) { - static const auto turbulentSchmidtNumber - = getParamFromGroup<Scalar>(problem.paramGroup(), - "RANS.TurbulentSchmidtNumber", 1.0); - eddyDiffusivity_ = RANSParentType::kinematicEddyViscosity() / turbulentSchmidtNumber; + eddyDiffusivity_ = RANSParentType::kinematicEddyViscosity() + / problem.turbulentSchmidtNumber(); } /*! diff --git a/dumux/freeflow/rans/volumevariables.hh b/dumux/freeflow/rans/volumevariables.hh index 24ba47261a5dc8c8bb6fd2f6547b19eedbf6dfa3..a0182d443057dce013ac8c924157ad8de42935d8 100644 --- a/dumux/freeflow/rans/volumevariables.hh +++ b/dumux/freeflow/rans/volumevariables.hh @@ -215,14 +215,10 @@ public: template<class Problem> void calculateEddyThermalConductivity(const Problem& problem) { - static const auto turbulentPrandtlNumber - = getParamFromGroup<Scalar>(problem.paramGroup(), - "RANS.TurbulentPrandtlNumber", 1.0); - eddyThermalConductivity_ = ParentType::kinematicEddyViscosity() * ParentType::asImp_().density() * ParentType::asImp_().heatCapacity() - / turbulentPrandtlNumber; + / problem.turbulentPrandtlNumber(); } /*! diff --git a/dumux/freeflow/rans/zeroeq/volumevariables.hh b/dumux/freeflow/rans/zeroeq/volumevariables.hh index 4f61a3d95f3eca7099053bef421956e3b9ecf374..efb256f8560062987ba56ac38ecd2ab07d0ada07 100644 --- a/dumux/freeflow/rans/zeroeq/volumevariables.hh +++ b/dumux/freeflow/rans/zeroeq/volumevariables.hh @@ -183,10 +183,8 @@ public: template<class Problem> void calculateEddyDiffusivity(const Problem& problem) { - static const auto turbulentSchmidtNumber - = getParamFromGroup<Scalar>(problem.paramGroup(), - "RANS.TurbulentSchmidtNumber", 1.0); - eddyDiffusivity_ = RANSParentType::kinematicEddyViscosity() / turbulentSchmidtNumber; + eddyDiffusivity_ = RANSParentType::kinematicEddyViscosity() + / problem.turbulentSchmidtNumber(); } /*!