CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

understanding kEpsilon model source code

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 8, 2009, 13:55
Default understanding kEpsilon model source code
  #1
jet
New Member
 
Join Date: Nov 2009
Posts: 12
Rep Power: 17
jet is on a distinguished road
Hi,

I have a question about the implementation of the kEpsilon source code in the file kEpsilon.C (.../src/turbulenceModels/incompressible/RAS/kEpsilon). In line 181 the divDevReff()-function is declared. Can anybody explain the code in line 185 and 186 to me?

Thanks!
jet is offline   Reply With Quote

Old   November 11, 2009, 23:25
Default
  #2
New Member
 
Nelson HO
Join Date: Jul 2009
Posts: 12
Rep Power: 17
chingyinh is on a distinguished road
Can you post that lines out?
chingyinh is offline   Reply With Quote

Old   November 14, 2009, 17:22
Default
  #3
jet
New Member
 
Join Date: Nov 2009
Posts: 12
Rep Power: 17
jet is on a distinguished road
Hi, I don't understand the following lines:

return
(
-laplacian(nuEff(), U)
-div(nuEff()*dev(grad(U)().T()))
);

The whole expression is defined as divDevReff() and should return the source term for the momentum equation. I tried to write it down mathematically but I failed!

Thanks for your help!
jet is offline   Reply With Quote

Old   November 15, 2009, 05:14
Default
  #4
Senior Member
 
sega's Avatar
 
Sebastian Gatzka
Join Date: Mar 2009
Location: Frankfurt, Germany
Posts: 729
Rep Power: 20
sega is on a distinguished road
Some people don't know that dev() is a transposition!
Well - at least it was me who doesn't know until I was told.

But what is this T() ?
__________________
Schrödingers wife: "What did you do to the cat? It's half dead!"
sega is offline   Reply With Quote

Old   November 15, 2009, 09:21
Default
  #5
jet
New Member
 
Join Date: Nov 2009
Posts: 12
Rep Power: 17
jet is on a distinguished road
Hmm, are you sure that dev() is a transposition? I think that .T() is a transposition and dev() ist the deviatoric component ( tensor -1/3*(trace tensor)*I ) of the tensor grad(U)().T()?

But I wonder if dev() shouldn't be dev2()?
jet is offline   Reply With Quote

Old   November 15, 2009, 09:52
Default
  #6
Senior Member
 
sega's Avatar
 
Sebastian Gatzka
Join Date: Mar 2009
Location: Frankfurt, Germany
Posts: 729
Rep Power: 20
sega is on a distinguished road
Actually your statement makes more sense.
I haven't thought about the fact that grad(U) is a tensor and not a vector like U itself!
__________________
Schrödingers wife: "What did you do to the cat? It's half dead!"
sega is offline   Reply With Quote

Reply


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
add a source term in kEpsilon model maurice OpenFOAM Running, Solving & CFD 0 May 18, 2009 08:54
add a source term in incompressible k-epsilon model maurice OpenFOAM 0 May 18, 2009 02:41
Kepsilon code for flow through pipe rakesh1434 OpenFOAM 2 August 9, 2007 09:23
DecomposePar links against liblamso0 with OpenMPI jens_klostermann OpenFOAM Bugs 11 June 28, 2007 18:51
public CFD Code development Heinz Wilkening Main CFD Forum 38 March 5, 1999 12:44


All times are GMT -4. The time now is 16:49.