CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > General Forums > Main CFD Forum

Turbulence kinetic energy and dissipation rate - problem with computation

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 6, 2015, 05:04
Default Turbulence kinetic energy and dissipation rate - problem with computation
  #1
New Member
 
jiri kozak
Join Date: Jan 2013
Posts: 21
Rep Power: 13
Kozan is on a distinguished road
Hello!

I'm quite new in OpenFoam and Python, therefore I have decided to write short script for the turbulence kinetic energy and dissipation rate computation.Code of the sripts follows:

def VypocetTurbVelicin(velocity, hydraulic_diameter, mu):
reynolds = (velocity * hydraulic_diameter)/mu
cmu = 0.09
intensity = 0.05
fluct_velocity = intensity * velocity
global k
k = 3/2 * ((fluct_velocity)**2)
turbulence_lengthScale = 0.038 * hydraulic_diameter
global epsilon
epsilon = (cmu * k**(3/2))/turbulence_lengthScale
return k, epsilon

k = None
velocity = float(raw_input("Velocity: "))
hydraulic_diameter = float(raw_input("Hydraulic diamter: "))
mu = float(raw_input("Kinematic viscosity : "))

VypocetTurbVelicin(velocity, hydraulic_diameter, mu)
print "turbulence kinetic energy: " + str(k)
print "turbulence dissipation rate: " + str(epsilon)

Problem is that the results of my script are different compared to the calculator which is available on the cfd-online (http://www.cfd-online.com/Tools/turbulence.php)

I can't find the problem. Thank you very much for any advice

For example results for
vel = 4.2 m.s^(-1)
visc = 1E-6 m^(2).s^(-1)
hydraulic diameter = 0.3 m
turbulence intensity = 5%

are:
My script:

k = 0.0441
eps = 0.348157894737

CFD online calculator
(Turbulence variables (k, ε, ω) from turbulence intensity (Tu), length-scale (TuL) and freestream velocity (U∞)):

k = 0.06615000000000001
eps = 0.13431744774423365
Kozan is offline   Reply With Quote

Reply

Tags
dissipation rate, epsilon, kinetic energy, openfoam, turbulence


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Turbulence postprocessing Mohsin FLUENT 2 October 3, 2016 15:18
change a variable in dissipation tem of turbulence model behest Fluent UDF and Scheme Programming 0 March 28, 2014 09:31
how to define the turbulent kinetic energy and turbulent dissipation rate? fanke FLOW-3D 4 March 26, 2013 21:40
turbulent kinetic energy and turbulent dissipation rate D_L Main CFD Forum 5 July 17, 2010 03:35
how to decide boundary condition of turbulence energy dissipation rate? Vincent B. Main CFD Forum 5 October 28, 1999 05:07


All times are GMT -4. The time now is 17:59.