CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT

Distance to the nearest wall...

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 13, 2001, 05:53
Default Distance to the nearest wall...
  #1
Michal
Guest
 
Posts: n/a
Hi,

How can I obtain a normal distance from any point in computational domain to the nearest wall - for UDF purposes.

I need to define a wall-distance based, turbulent Reynolds number so I have to know this...

Thanks

Michal
  Reply With Quote

Old   February 13, 2001, 08:06
Default Re: Distance to the nearest wall...
  #2
Jonas Larsson
Guest
 
Posts: n/a
You can't do this in Fluent. This is also why Fluent does not offer any y+ dependent near-wall turbulence models. Your best bet is to derive a wall y* based on turbulent quantities instead. That is what Fluent does.

I guess that this lack of nearest-wall distance was an early design-decision for their unstructured solver - keeping track of this everywhere would give too much overhead. I miss this feature a lot in post-processing. Being able to extract data at a certain y+ isn't possible either, for example.
  Reply With Quote

Old   February 13, 2001, 09:57
Default Re: Distance to the nearest wall...
  #3
Michal
Guest
 
Posts: n/a
Thanks for your reply - Jonas.

What is a meaning of C_WALL_DIST(c,t) variable?

Michal
  Reply With Quote

Old   February 13, 2001, 10:15
Default Re: Distance to the nearest wall...
  #4
keith
Guest
 
Posts: n/a
The variable C_WALL_DIST(c,t) will in fact give you the distance to the nearest wall, with one small caveat. It appears that Fluent calculates the distance to the nearest wall bordering the particular cell zone that your cell is within. If the (physically) nearest wall is actually bounding a different cell zone, Fluent won't "see" it. Fortunately, this is rarely a problem, and I also have to admit that a couple of versions have come out since I noticed this, and it may be different now. For almost all problems, C_WALL_DIST(c,t) will work fine.

Now, what is tricky is finding the _vector_ definition to the nearest wall...

Keith
  Reply With Quote

Old   February 13, 2001, 10:27
Default Re: Distance to the nearest wall...
  #5
Michal
Guest
 
Posts: n/a
Thanks for your explanation - Keith.

Michal
  Reply With Quote

Old   February 13, 2001, 11:03
Default Re: Distance to the nearest wall...
  #6
Jonas Larsson
Guest
 
Posts: n/a
Interesting. Does this mean that this routine will work also for interior cells as long as the cell is within the same zone as the nearest wall? I thought the distance was only available for cells bordering to walls. Do you know how the distance is defined for interior cells? (I assume that they don't compute the correct normal distance)
  Reply With Quote

Old   February 13, 2001, 15:49
Default Re: Distance to the nearest wall...
  #7
keith
Guest
 
Posts: n/a
Yes, the C_WALL_DIST(c,t) variable gives values for all interior cells as well as 1st-layer cells. And my experience has been that it gives the distance to the nearest wall bounding its own cell zone, although that may have been changed in the latest versions to find the nearest wall regardless of cell zone.

You can actually display contours of this variable under "Grid-->Cell Wall Distance" from the GUI, and it appears to be just the shortest distance to any wall. My guess is that whenever you initialize a .dat file, the routine loops through each interior cell and then in a nested loop through all boundary faces, calculates the distance between their centroids, and keeps the smallest one it finds.

Regards, Keith
  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
[Commercial meshers] Fluent3DMeshToFoam simvun OpenFOAM Meshing & Mesh Conversion 50 January 19, 2020 16:33
calculate distance from wall to neighbourig cell centroid rr123 Fluent UDF and Scheme Programming 39 March 14, 2017 02:41
Wall distance in BC Sylvain OpenFOAM 1 June 14, 2011 20:54
UDF problem about nearest wall ! alex FLUENT 2 December 24, 2010 22:31
Multicomponent fluid Andrea CFX 2 October 11, 2004 06:12


All times are GMT -4. The time now is 03:28.