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

SA turbulence model implementation issue

Register Blogs Community New Posts Updated Threads Search

Like Tree2Likes
  • 1 Post By SergeAS
  • 1 Post By som87

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 6, 2014, 06:31
Default SA turbulence model implementation issue
  #1
New Member
 
shikhar
Join Date: Apr 2010
Posts: 22
Rep Power: 16
jaiswal is on a distinguished road
i am trying to implement spalart almaras turbulence model in 2D Navier-Stokes solver.

Even after spending lot of time im not successful.

My first doubt is whether im using d (distance from the closest surface) correctly or not.

How is d calculated?

I am doing calculation on NACA 0012 airfoil. And to find the distance from closest surface for a grid point, im calculating distance from the grid point to all the points on the body (in this case NACA 0012 airfoil) and using the minimum of the distance among them.

Is this the correct way to find distance from the closest surface?
jaiswal is offline   Reply With Quote

Old   February 6, 2014, 13:07
Default
  #2
Member
 
Join Date: May 2012
Posts: 68
Rep Power: 14
som87 is on a distinguished road
The way you are calculating the wall distance is highly dependent to your mesh.
If your have unstructured (say triangular) mesh, then it'll not give you correct answer.
If that is the case, I suggest to maintain the index and try to use the index (say j=1 to j=2) to get the grid distance
__________________
Best wishes,

Somdeb Bandopadhyay
som87 is offline   Reply With Quote

Old   February 6, 2014, 23:59
Default
  #3
New Member
 
shikhar
Join Date: Apr 2010
Posts: 22
Rep Power: 16
jaiswal is on a distinguished road
Hi Somdeb!... thank you for ur reply

I am not very clear what you are telling Somdeb. I am using structured mesh. I am using C-grid of 257*60 size. I have 197 points on the airfoil. Suppose i want to find closest distance from surface for a grid point say i = 30 & j = 20 then i find distance for this grid point from all the points on the airfoil i.e. j = 1 & i = 31 to 227 ( 197 points) and take minimum of the distance among them.

Is this the right way to find distance from the closest surface, for use in turbulence model calculations? Or is there a better way to do it?
jaiswal is offline   Reply With Quote

Old   February 7, 2014, 14:41
Default
  #4
Member
 
SergeAS's Avatar
 
Serge A. Suchkov
Join Date: Oct 2011
Location: Moscow, Russia
Posts: 74
Blog Entries: 5
Rep Power: 15
SergeAS is on a distinguished road
Send a message via Skype™ to SergeAS
Quote:
Originally Posted by jaiswal View Post
I am using C-grid of 257*60 size. I have 197 points on the airfoil. Suppose i want to find closest distance from surface for a grid point say i = 30 & j = 20 then i find distance for this grid point from all the points on the airfoil i.e. j = 1 & i = 31 to 227 ( 197 points) and take minimum of the distance among them.
Your algorithm is correct, but you keep in mind that for huge meshes and complicated wall shape this algorithm quite slow. For above specified mesh it will be insignificant, but if you want to propagate it to a larger 3D mesh, you will see this. Moreover, if you need to deform the mesh, this procedure will be repeated after each mesh modification. I use a similar algorithm in my 3D code but I have special parallel version for this case.

As example on 600k nodes mesh for ~1200 wall nodes this procedure takes 15 sec on 4-core CPU and less 5 sec on GPU
jaiswal likes this.
__________________
OpenHyperFLOW2D Project
SergeAS is offline   Reply With Quote

Old   February 7, 2014, 21:27
Default
  #5
Member
 
Join Date: May 2012
Posts: 68
Rep Power: 14
som87 is on a distinguished road
Hi again, sorry for late reply.
Yes, your algorithm is correct.
About my previous comment, I didnt know about your grid's details

While we are in topic, SA turb model is a static type model right? So it will not give good result most cases

Cheers
jaiswal likes this.
__________________
Best wishes,

Somdeb Bandopadhyay

Last edited by som87; February 10, 2014 at 00:55.
som87 is offline   Reply With Quote

Old   February 10, 2014, 00:30
Default
  #6
New Member
 
shikhar
Join Date: Apr 2010
Posts: 22
Rep Power: 16
jaiswal is on a distinguished road
Thank you Serge ... Now it is very clear to me... your information was very helpful... since i am calculating d correctly there is some other implementation issue... I will try to sort out...
jaiswal is offline   Reply With Quote

Old   February 10, 2014, 00:37
Default
  #7
New Member
 
shikhar
Join Date: Apr 2010
Posts: 22
Rep Power: 16
jaiswal is on a distinguished road
Hi Somdeb!... thank u once again for replying...

Now it is clear to me that my algorithm to find distance is correct.

what do u mean by static type model?... I am still not successful in my implementation, so maybe it is important to me... can u pls explain?
jaiswal is offline   Reply With Quote

Old   February 10, 2014, 01:15
Default
  #8
Member
 
Join Date: May 2012
Posts: 68
Rep Power: 14
som87 is on a distinguished road
Hi again, I just commented on the fact that we marely calculate the eddy viscosity in SA model and there is no further coupling between the original NS PDE (like it is in k omega or k epsilon).
I am sure it will not affect your work in implementing SA model in your code. I didnt want to cause any misunderstanding
__________________
Best wishes,

Somdeb Bandopadhyay
som87 is offline   Reply With Quote

Old   February 10, 2014, 23:42
Default
  #9
New Member
 
shikhar
Join Date: Apr 2010
Posts: 22
Rep Power: 16
jaiswal is on a distinguished road
K... Thank you Somdeb
jaiswal 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
Implementation of turbulence model idefix OpenFOAM Programming & Development 1 March 28, 2013 06:43
Implementation of turbulence model idefix OpenFOAM Programming & Development 5 March 27, 2013 02:22
issue compiling new turbulence model perplexed user OpenFOAM Programming & Development 1 January 13, 2012 04:40
Fan heater model: what turbulence source to use? andy20 Main CFD Forum 0 March 2, 2008 13:46
A reference on implementation of Spalart-Alam. Turbulence Model? Mohammad Kermani Main CFD Forum 2 December 26, 1999 03:56


All times are GMT -4. The time now is 12:53.