24#ifndef DUMUX_LOWREKEPSILON_PROBLEM_HH
25#define DUMUX_LOWREKEPSILON_PROBLEM_HH
45template<
class TypeTag>
74 storedDissipationTilde_.resize(this->
gridGeometry().elementMapper().size(), 0.0);
75 storedDynamicEddyViscosity_.resize(this->
gridGeometry().elementMapper().size(), 0.0);
76 storedTurbulentKineticEnergy_.resize(this->
gridGeometry().elementMapper().size(), 0.0);
84 template<
class SolutionVector>
90 for (
const auto& element : elements(this->
gridGeometry().gridView()))
92 unsigned int elementIdx = this->
gridGeometry().elementMapper().index(element);
93 fvGeometry.bindElement(element);
95 for (
auto&& scv : scvs(fvGeometry))
97 const int dofIdx = scv.dofIndex();
98 const auto& cellCenterPriVars = curSol[GridGeometry::cellCenterIdx()][dofIdx];
102 storedDissipationTilde_[elementIdx] = elemSol[0][Indices::dissipationEqIdx];
103 storedTurbulentKineticEnergy_[elementIdx] = elemSol[0][Indices::turbulentKineticEnergyEqIdx];
105 VolumeVariables volVars;
106 volVars.update(elemSol, asImp_(), element, scv);
107 storedDynamicEddyViscosity_[elementIdx] = volVars.calculateEddyViscosity();
119 {
return storedDissipationTilde_[elementIdx]; }
122 {
return storedDynamicEddyViscosity_[elementIdx]; }
125 {
return storedTurbulentKineticEnergy_[elementIdx]; }
128 std::vector<Scalar> storedDissipationTilde_;
129 std::vector<Scalar> storedDynamicEddyViscosity_;
130 std::vector<Scalar> storedTurbulentKineticEnergy_;
133 Implementation &asImp_()
134 {
return *
static_cast<Implementation *
>(
this); }
137 const Implementation &asImp_()
const
138 {
return *
static_cast<const Implementation *
>(
this); }
Base class for all staggered fv problems.
Free function to get the local view of a grid cache object.
The available discretization methods in Dumux.
The available free flow turbulence models in Dumux.
TurbulenceModel
The available free flow turbulence models in Dumux.
Definition turbulencemodel.hh:38
@ lowrekepsilon
Definition turbulencemodel.hh:39
GridCache::LocalView localView(const GridCache &gridCache)
Free function to get the local view of a grid cache object.
Definition localview.hh:38
auto elementSolution(const Element &element, const SolutionVector &sol, const GridGeometry &gg) -> std::enable_if_t< GridGeometry::discMethod==DiscretizationMethods::box, BoxElementSolution< typename GridGeometry::LocalView, std::decay_t< decltype(std::declval< SolutionVector >()[0])> > >
Make an element solution for box schemes.
Definition box/elementsolution.hh:118
PrimaryVariables makePriVarsFromCellCenterPriVars(const CellCenterPrimaryVariables &cellCenterPriVars)
Helper function to create a PrimaryVariables object from CellCenterPrimaryVariables.
Definition staggered/elementsolution.hh:41
T getParamFromGroup(Args &&... args)
A free function to get a parameter from the parameter tree singleton with a model group.
Definition parameters.hh:161
Adaption of the non-isothermal two-phase two-component flow model to problems with CO2.
Definition adapt.hh:29
typename GetProp< TypeTag, Property >::type GetPropType
get the type alias defined in the property
Definition propertysystem.hh:180
const std::string & paramGroup() const
The parameter group in which to retrieve runtime parameters.
Definition common/fvproblem.hh:544
const GridGeometry & gridGeometry() const
The finite volume grid geometry.
Definition common/fvproblem.hh:540
void updateDynamicWallProperties(const SolutionVector &curSol)
Update the dynamic (solution dependent) turbulence parameters.
Definition freeflow/rans/problem.hh:143
void updateStaticWallProperties()
Update the static (solution independent) relations to the walls and neighbors.
Definition freeflow/rans/problem.hh:127
RANSProblemBase(std::shared_ptr< const GridGeometry > gridGeometry, const std::string ¶mGroup="")
The constructor.
Definition freeflow/rans/problem.hh:102
Scalar storedDissipationTilde(const int elementIdx) const
Definition freeflow/rans/twoeq/lowrekepsilon/problem.hh:118
void updateDynamicWallProperties(const SolutionVector &curSol)
Update the dynamic (solution dependent) relations to the walls.
Definition freeflow/rans/twoeq/lowrekepsilon/problem.hh:85
void updateStaticWallProperties()
Correct size of the static (solution independent) wall variables.
Definition freeflow/rans/twoeq/lowrekepsilon/problem.hh:69
RANSProblemImpl(std::shared_ptr< const GridGeometry > gridGeometry, const std::string ¶mGroup="")
The constructor sets the gravity, if desired by the user.
Definition freeflow/rans/twoeq/lowrekepsilon/problem.hh:62
Scalar storedTurbulentKineticEnergy(const int elementIdx) const
Definition freeflow/rans/twoeq/lowrekepsilon/problem.hh:124
Scalar storedDynamicEddyViscosity(const int elementIdx) const
Definition freeflow/rans/twoeq/lowrekepsilon/problem.hh:121
bool useStoredEddyViscosity() const
Definition freeflow/rans/twoeq/lowrekepsilon/problem.hh:112
Declares all properties used in Dumux.
A single-phase, isothermal low-Reynolds k-epsilon model.
the turbulence-model-specfic RANS problem
The local element solution class for staggered methods.