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

UDS problem with wall boundary condition

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 12, 2005, 12:14
Default UDS problem with wall boundary condition
  #1
Alex F.
Guest
 
Posts: n/a
As we know, face values of quantities in FLUENT are allocated in memory only for boundary faces (e.g., wall zones).

I wrote a UDF which adds a UDS equation to the system of equations. I have a problem with WALL boundary condition.

The problem is that FLUENT does not have access to face values of WALL boundary condition (e.g., F_R, F_U) and when calling these face values ACCESS_VIOLATION occured.

I did not see this problem for other kinds of boundary condition like OUTFLOW, VELOCITY INLET.

Thanks in advance.
  Reply With Quote

Old   November 13, 2005, 05:02
Default Re: UDS problem with wall boundary condition
  #2
RoM
Guest
 
Posts: n/a
F_U should be zero at walls (no slip) if not statet otherwise. Other face values can be calculated from cell gradient and vector cell_center->face_center (dr0). For density: face_density=NV_DOT(C_R_G(c0,t0),dr0).

RoM
  Reply With Quote

Old   November 13, 2005, 06:52
Default Re: UDS problem with wall boundary condition
  #3
Alex F.
Guest
 
Posts: n/a
Dear RoM, Thanks for your prompt response.

FLUENT should automatically return F_U=0 at WALL boundary. But when F_U is called in the UDF for WALL boundary, ACCESS_VIOLATION occured.

There is a sample for DEFINE_UDS_FLUX in UDF manual in which F_R, F_U and F_V has been used. But when these functions want to return the value of WALL boundary ACCESS_VIOLATION occured.
  Reply With Quote

Old   November 13, 2005, 10:03
Default Re: UDS problem with wall boundary condition
  #4
KP
Guest
 
Posts: n/a
Is there by any chance u want to code for wall force?? KP
  Reply With Quote

Old   November 13, 2005, 14:28
Default Re: UDS problem with wall boundary condition
  #5
Alex F.
Guest
 
Posts: n/a
No, I want to calculate flux through wall. I used a face loop:

thread_loop_f(t,d) {

begin_f_loop(f,t)

{

flux=F_R(f,t)*F_U(f,t);

}end_f_loop(f,t) }

this will cause ACCESS_VIOLATION when "f" belongs to WALL boundary. Other type of boundary such as "Inlet", "Outflow" does not cause ACCESS_VIOLATION.
  Reply With Quote

Old   November 14, 2005, 02:41
Default Re: UDS problem with wall boundary condition
  #6
RoM
Guest
 
Posts: n/a
You can use the F_FLUX(f,t) macro for that purpose.

RoM
  Reply With Quote

Old   November 14, 2005, 04:26
Default Re: UDS problem with wall boundary condition
  #7
Luca
Guest
 
Posts: n/a
Dear Alex, the problem is that F_ macros, works only with the segregated solver.Luca
  Reply With Quote

Old   November 14, 2005, 04:30
Default Re: UDS problem with wall boundary condition
  #8
RoM
Guest
 
Posts: n/a
F_R(f,t) crashes on segeregated solver when used on walls. I tried it.

RoM
  Reply With Quote

Old   November 14, 2005, 04:40
Default Re: UDS problem with wall boundary condition
  #9
Luca
Guest
 
Posts: n/a
Yes I had the same problem. In the fluent users guide, it's written clearly that F_ are only for the segregated. So if you use the coupled 2nd order you can use the gradient to build wall variables. Luca
  Reply With Quote

Old   November 14, 2005, 05:11
Default Re: UDS problem with wall boundary condition
  #10
RoM
Guest
 
Posts: n/a
@Luca, Do you have some experience with calculation of face data from cell data? I had some problems with it and started a thread one week ago, but nobody had an answer. Maybe you can help. Thats what i wrote:

I have got a problem with the calculation of face vaules from cell center values. For an interior face i could caculate the face value either from the c0 cell side or the c1 cell side, using the cell values and the gradient. For a species it looks like this

from c0

face_value0=C_YI(c0,c0thread,i)+NV_DOT(C_YI_G(c0,c 0thread,i),dr0)

and from c1

face_value1=C_YI(c1,c1thread,i)+NV_DOT(C_YI_G(c1,c 1thread,i),dr1)

dr is the vector from cell center to the face center. Both face values should be identical but unfortunatly they are not. I tried it on a sturcured meshe with full converged soultion. Is there any other way to get consistent values for the faces?

Thanks for any suggestions

RoM

  Reply With Quote

Old   November 14, 2005, 06:16
Default Re: UDS problem with wall boundary condition
  #11
Luca
Guest
 
Posts: n/a
Dear RoM, I used only c0 to build wall pressure, so I haven't tested my routine on interior faces. Sorry. I hope the difference you found is not so large beetween using c0 or c1.It should depend on the gradient. Try using node based gradient and let me know how it works. Luca
  Reply With Quote

Old   November 14, 2005, 06:23
Default Re: UDS problem with wall boundary condition
  #12
RoM
Guest
 
Posts: n/a
I will give it try. Thanks for the suggestion. The manual stated one should use reconstruction gradients (RG) to build face values from cell values but i never got this to work. Everytime i try to access a RG fluent gives a nice access violation. I wonder if RG are available at all.

RoM
  Reply With Quote

Old   November 14, 2005, 06:31
Default Re: UDS problem with wall boundary condition
  #13
Luca
Guest
 
Posts: n/a
I found out that sometimes instead of using reconstructed gradient, you should use the default one. It depends on the solver you're using (segregated or coupled).Luca
  Reply With Quote

Old   November 14, 2005, 06:39
Default Re: UDS problem with wall boundary condition
  #14
RoM
Guest
 
Posts: n/a
I only use the segragated solver so i think i am stuck with the default gradients.

Thanks, RoM
  Reply With Quote

Old   August 6, 2014, 06:08
Default Reconstruction Gradient
  #15
New Member
 
hanSolo
Join Date: Aug 2014
Posts: 1
Rep Power: 0
User89 is on a distinguished road
Hi, did you find a way to store cell values at faces by using the reconstruction Gradient?

Thanks a lot
User89 is offline   Reply With Quote

Old   September 21, 2015, 10:28
Default
  #16
Member
 
Join Date: Nov 2014
Posts: 42
Rep Power: 11
Maryam-A is on a distinguished road
Thanks for all posts.

Last edited by Maryam-A; September 22, 2015 at 04:17.
Maryam-A is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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
Water subcooled boiling Attesz CFX 7 January 5, 2013 04:32
[Gmsh] Import problem ARC OpenFOAM Meshing & Mesh Conversion 0 February 27, 2010 11:56
problem with boundary condition??? smn CFX 5 November 24, 2009 07:37
UDF hook on the WALL boundary condition Luke FLUENT 0 June 7, 2006 12:54
New topic on same subject - Flow around race car Tudor Miron CFX 15 April 2, 2004 07:18


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