0% found this document useful (0 votes)
6 views

Turbulence-Modelling-in-OpenFOAM-Additionalmaterial

Uploaded by

Ashish Pawar
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views

Turbulence-Modelling-in-OpenFOAM-Additionalmaterial

Uploaded by

Ashish Pawar
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 8

CFD-OpenFOAM

FOSSEE, IIT Bombay


Spoken Tutorial

Additional Reading Material


Turbulence Modelling in OpenFOAM

Calculation of yp and y+

Turbulence models uses wall functions to model near wall regions in a turbulent flow. In order
to satisfy the physics near the wall, the first cell centre 𝑦𝑝 should be within the log-law region
from the wall.
The dimensionless wall distance 𝑦 + is given by

2
𝑦𝑝 √0.5𝐶𝑓 𝑈∞
𝑦+ = (1)
𝜈
Where, 𝑦 is the distance from the wall,
𝑈∞ is the free stream velocity, and
𝜈 is the kinematic viscosity.
The skin friction coefficient 𝐶𝑓 is given by the -1/4 power law,

1
𝐶𝑓 = 0.078 𝑅𝑒 −4 (2)

Where, 𝑅𝑒 is the Reynolds number.


For the first cell centre 𝑦𝑝 to be within the log-law region from the wall, the dimensionless wall
distance 𝑦 + should be
30 < 𝑦 + < 300
In this tutorial, we have considered 𝒚+ = 𝟐𝟎𝟎. Therefore, from (1)
2
𝑦𝑝 √0.5𝐶𝑓 𝑈∞
+
𝑦 = = 200 (3)
𝜈
Since the 𝑹𝒆 = 𝟐 × 𝟏𝟎𝟔 the skin friction coefficient is
1
𝐶𝑓 = 0.078 (2 × 106 )−4 = 2.074 × 10−3 (4)

Also, in this tutorial, 𝝂 = 𝟏 × 𝟏𝟎−𝟓 𝐦𝟐 /𝐬 and 𝑼∞ = 𝟐𝟎 𝐦/𝐬.


Therefore, from (3)
200 × (1 × 10−5 )
𝑦𝑝 = = 0.0031 m
√0.5 × (2.074 × 10−3 ) × 202
Therefore, the cell centre of the first cell should be 𝟎. 𝟎𝟎𝟑𝟏 𝐦 away from the wall.
The cell width along 𝒚-axis is therefore double this distance, i.e. 𝟎. 𝟎𝟎𝟔𝟐 𝐦.
CFD-OpenFOAM
FOSSEE, IIT Bombay
Spoken Tutorial

Expansion Ratio

The channel geometry in our tutorial is divided into two blocks as shown in fig. 1.

Figure 1. Blocks in the Channel Geometry


The bottom face of block 1 is the wall. Therefore, the cells near the bottom of block 1 needs to
be refined. We do this using expansion ratio along 𝑦-axis. Let this expansion ratio be 𝑒. Since
we have prescribed uniform cell expansion using the keyword simpleGrading in the
blockMeshDict file, the cell widths, along 𝑦-axis, forms a geometric progression. If the cell
width along 𝑦-axis of the cell closest to the wall is 𝑎, then the cell width of cell above it would
be 𝑎𝑟 and the one above it 𝑎𝑟 2 and so on. We have 30 cells running along the 𝑦-direction,
therefore, the cells width of the topmost cell of block 1 is 𝑎𝑟 29 .
From the previous section we know that cell closest to the wall has a cell width of 0.0062 m.

𝑎 = 0.0062 m (5)
Since the channel width of block 1 along the 𝑦-axis is 0.5 m,

𝑎 + 𝑎𝑟 + 𝑎𝑟 2 + ⋯ + 𝑎𝑟 29 = 0.5 m (6)

Solving (5) and (6), we get two real solutions for 𝑟. Since one of them is 𝑟 = 1 and this means
the cell width is uniform, we neglect this solution. The other real solution is

𝑟 = 1.0611
The expansion ratio is defined as the ratio of the width of the last cell to that of the first cell.
Therefore,

𝑎𝑟 29
𝑒= = 𝑟 29 = 5.57 (7)
𝑎
The expansion ratio along 𝑦-axis for block 1 is 5.57.
And the same way it is 0.18 for block 2.
CFD-OpenFOAM
FOSSEE, IIT Bombay
Spoken Tutorial

𝒌 − 𝜺 model
𝑘 − 𝜀 model solves two additional equations, for turbulent kinematic energy 𝑘 and rate of
dissipation of turbulence energy 𝜀. It performs poorly for complex flows involving severe
pressure gradient, separation, strong streamline curvature. Suitable for initial iterations, initial
screening of alternative designs, and parametric studies. Can be only used with wall functions.
To use this model following boundary conditions are required:

p U k epsilon nut
Where,
𝑘 is turbulent kinetic energy,
epsilon is turbulent dissipation rate,
nut is turbulent kinematic viscosity

𝒌 − 𝒐𝒎𝒆𝒈𝒂 model
𝑘 − 𝜔 model solves two additional equations, for turbulent kinematic energy 𝑘 and specific
dissipation rate 𝜔. It performs better for complex flows involving severe pressure gradient,
separation, strong streamline curvature. For the external flow it works better and near to the
walls its performance is not that good.
To use this model following boundary conditions are required:

p U k omega nut
Where,
omega is specific dissipation rate,

𝒌 − 𝒐𝒎𝒆𝒈𝒂 𝑺𝑺𝑻 model


This model solves two additional equations, for turbulent kinematic energy k and specific
dissipation rate. It gives best performance for wall-bounded boundary layer, free shear, and
low Reynolds number flows compared to the 𝑘 − 𝜀 model. It is a hybrid model of k-omega and
𝑘 − 𝜀 models. It uses 𝑘 − 𝜀 formulas in the centre region and k-omega formulas near to the
wall. Suitable for complex boundary layer flows. Provides more accurate prediction of flow
separation than other RANS models. Can be used with and without wall functions. This is the
most widely used RANS turbulence model.
To use this model following boundary conditions are required:

p U k omega nut
CFD-OpenFOAM
FOSSEE, IIT Bombay
Spoken Tutorial

Calculations for 𝒌

Turbulent kinetic energy 𝑘 can be represent by this equation,


1 1
𝑘= 𝑢′ ∙ 𝑢′ = 𝑢′2 + 𝑣 ′2 + 𝑤 ′2
2 2

If we assume isentropic turbulence 𝑢′2 = 𝑣 ′2 = 𝑤 ′2 we will get


3 ′2
𝑘= 𝑢
2
Isentropic turbulence assumption is valid in core region only. Which is far from walls where
wall effects are negligible.
𝑚2 𝐽
Units of 𝑘 is = 𝑘𝑔
𝑠2

3
𝑘= (𝑈 𝐼)2
2 ∞
Where,
𝑈∞ is a characteristic velocity scale,
I is the turbulent intensity

𝑢′ √𝑢′2 + 𝑣 ′2 + 𝑤 ′2 √𝑢′2 + 𝑣 ′2 + 𝑤 ′2
𝐼= = =
𝑢 √𝑢2 + 𝑣2 + 𝑤 2 𝑈∞

Note, that I is a dimensionless quantity.


I typically has a value ranging from [0, 20] %, and [0, 1] % is considered low intensity, [1, 5]
% is medium intensity, and [5, 20] % is considered high turbulent intensity.
Turbulent intensity can be predicted from experimental data. For fully developed pipe flow we
can use this relation,
−1
𝐼 = 0.16𝑅𝑒 8

In our case,

𝑹𝒆 = 𝟐𝟎, 𝟎𝟎, 𝟎𝟎𝟎


𝒎
𝑼∞ = 𝟐𝟎 𝟑
𝒔 Turbulent kinetic energy: 𝒌 = (𝑼∞ 𝑰)𝟐
𝟐
−𝟏
Turbulent Intensity: 𝑰 = 𝟎. 𝟏𝟔𝑹𝒆 𝟖 𝟑
𝒌= (𝟐𝟎 ∙ 𝟎. 𝟎𝟐𝟔𝟏)𝟐
−𝟏
𝟐
𝟑
𝑰 = 𝟎. 𝟏𝟔(𝟐𝟎, 𝟎𝟎, 𝟎𝟎𝟎) 𝟖 𝒌 = ∙ 𝟎. 𝟐𝟕𝟐𝟒𝟖𝟒
𝑰 = 𝟎. 𝟎𝟐𝟔𝟏 𝟐
𝒎𝟐
𝒌 = 𝟎. 𝟒𝟎𝟖𝟕𝟓 𝒔𝟐
CFD-OpenFOAM
FOSSEE, IIT Bombay
Spoken Tutorial

Calculations for 𝜺

Calculation of turbulent dissipation rate 𝜀 is very straight forward. Put data of 𝑘 and
characteristic length of the channel in this formula,
3
𝐶𝜇 ⁄4 ∙ 𝑘1.5
𝜀=
0.07 ∙ 𝐿
Where, 𝐶𝜇 is an empirical constant. Value of 𝐶𝜇 is 0.09.

In our case,
𝒎𝟐
𝒌 = 𝟎. 𝟒𝟎𝟖𝟕𝟓 &𝑳=𝟏𝒎
𝒔𝟐

𝟎.𝟏𝟔𝟒∙𝒌𝟏.𝟓
Turbulent dissipation rate: 𝜺 = 𝟎.𝟎𝟕∙𝑳

𝒎𝟐 𝟏.𝟓
𝟎. 𝟏𝟔𝟒 ∙ (𝟎. 𝟒𝟎𝟖𝟕𝟓 )
𝜺= 𝒔𝟐
𝟎. 𝟎𝟕 ∙ 𝟏

𝜺 = 𝟎. 𝟔𝟏

Calculations for 𝒐𝒎𝒆𝒈𝒂

Calculation of specific dissipation rate 𝜔 is very straight forward. Put data of 𝑘 and
characteristic length of the channel in this formula,
𝜀
𝜔=
𝐶𝜇 ∙ 𝜅
1
−1⁄ 𝜅 ⁄2
𝜔 = 𝐶𝜇 4
0.07 ∙ 𝐿
Where, 𝐶𝜇 is an empirical constant. Value of 𝐶𝜇 is 0.09.

In our case,
𝒎𝟐
𝒌 = 𝟎. 𝟒𝟎𝟖𝟕𝟓 &𝑳=𝟏𝒎
𝒔𝟐

𝟏
−𝟏⁄ 𝜿 ⁄𝟐
Turbulent dissipation rate: 𝝎 = 𝑪𝝁 𝟒
𝟎.𝟎𝟕∙𝑳

𝟏⁄
−𝟏⁄ (𝟎. 𝟒𝟎𝟖𝟕𝟓) 𝟐
𝝎= 𝟎. 𝟎𝟗 𝟒
𝟎. 𝟎𝟕 ∙ 𝟏

𝝎 = 𝟏𝟔. 𝟔𝟕
CFD-OpenFOAM
FOSSEE, IIT Bombay
Spoken Tutorial

Calculations for 𝒏𝒖𝒕

Turbulent viscosity 𝜈𝑡 will automatically calculated by OpenFoam.


For 𝒌 − 𝜺,
Formula, OpenFoam calculates for 𝜈𝑡 is,
𝐶𝜇 𝑘 2
𝜈𝑡 =
𝜀
Where, 𝐶𝜇 is an empirical constant. Value of 𝐶𝜇 is 0.09.

For k-Omega,
Formula, OpenFoam calculates for 𝜈𝑡 is,
𝑘
𝜈𝑡 =
𝜔
Effective viscosity, 𝜈𝑒𝑓𝑓 = 𝜈 + 𝜈𝑡

Wall functions
The k-ε equations are only valid for fully turbulent high Reynolds number flow, and are thus
not valid near the wall. Therefore, k-ε equations are not integrated all the way to the walls. We
can divide near-wall region in three different categories:
• Viscous sub-layer 0 < y+ < 5
• Buffer layer 5 < y+ < 30
• Log-law layer 30 < y+ < 300

Source: https://www.computationalfluiddynamics.com.au/turbulence-part-3-selection-
of-wall-functions-and-y-to-best-capture-the-turbulent-boundary-layer/
CFD-OpenFOAM
FOSSEE, IIT Bombay
Spoken Tutorial

If we keep first cell centre in the viscous sub-layer, all turbulence equations give us accurate
results. But that is very difficult to simulate. This approach leads to requirement of abundant
mesh number, which means a substantial computational resource is needed.
The viscous sub-layer: (y+ < 5)
In the viscous layer the fluid is dominated by the viscous affect so it can be assumed that the
shear stress of fluid is equal to the wall shear stress 𝜏𝜔 . In viscous layer viscous stress decide
the flow and the velocity profile is liner, given by
u+= y+
Another way of getting accurate simulation results is applying some additional boundary
condition at wall which calculates non-linearity of velocity near to the wall. For that we need
to add a logarithmic velocity function at walls. This log functions are only valid in log-law
region where y+ value is between 30 & 300.
The log-law layer: (30 < y+ < 300)
In the logarithmic layer turbulence stress dominate the flow and velocity profile varies very
slowly with a logarithmic function along the distance y, given by
1
u+ = 𝜅 × ln(𝐸𝑦 + )

Let 𝑈𝑝 be a velocity component at a node p closest to the wall. We then impose that the velocity
at this node should follow the logarithmic wall law according to

𝑈𝑝 1 𝑣 ∗ 𝑦𝑝
= ln ( )+𝐵
𝑣∗ 𝜅 𝜈

Where, 𝑣 ∗ is the wall friction velocity


1
𝜏𝜔 ⁄2
𝑣∗ = ( )
𝜌
𝜅 ≈ 0.40 is the Von Karman constant
𝐵 ≈ 5.0 is also a constant

Without Wall function With Wall function


CFD-OpenFOAM
FOSSEE, IIT Bombay
Spoken Tutorial

The Buffer layer: (5 < y+ < 30)


Viscous and turbulent stresses are of similar magnitude and since it is complex velocity profile
is not well defined and the original wall functions avoid the first cell centre located in this
region. However, the improved wall functions allow the first cell centre is located in buffer
layer. In OpenFOAM buffer layer is divided 2 parties. One is using the liner relation as that in
viscous sublayer, the other is to use logarithmic function as that in logarithmic region. Cells in
this layer will not get accurate results. So always avoid to keep cells in this region.
The wall functions used in spoken tutorial are:
1. Wall function for k
1.1. kqRWallFunction
1.2. kLowReWallFunction
2. Wall function for epsilon
2.1. epsilonWallFunction
2.2. epsilonLowReWallFunction
3. Wall function for omega
3.1. OmegaWallFunction
4. Wall function for nut
4.1. nutkWallFunction
4.2. nutkRoughWallFunction
4.3. nutkAtmRoughWallFunction
4.4. nutkFilmWallFunction
4.5. nutLowReWallFunction
4.6. nutUWallFunction
4.7. nutURoughWallFunction
4.8. nutUSpaldingWallFunction
4.9. nutUTabulatedWallFunction
To study wall functions in detail, please go through the link here.

You might also like