CFD Online Logo CFD Online URL
Home > Forums > Fluent UDF and Scheme Programming

define boundary condition in just one cell face

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

LinkBack Thread Tools Display Modes
Old   June 16, 2010, 19:11
Default define boundary condition in just one cell face
New Member
Join Date: Mar 2010
Posts: 17
Rep Power: 9
om1234 is on a distinguished road
Hi all
i'm going to analysis 2d centrifugal outlet line,i try to define static pressure in a single face of grid. i use this udf. but it doesn't work correctlly.
i have some questions and i wish any one could answer me.
is the define adjust updated in every iteration and is it usefull in this udf?
any one know any thing about the working of fluent memory?
is the memory values updated in each iteration,i mean is the previous values deleted and replaced by the new pressure value or not?


real p;
face_t f;
int ID=7;/*this is the outlet ID*/
int k=0;

Thread *t=Lookup_Thread(domain,ID); /*this macro is used to define specific thread*/

p=F_P(f,t); /*F_P read the pressure of each face and assign it to p*/
F_UDMI(f,t,k)= p; /*this macro is used to store/access the values of the user-defined memory on the face.the outlet boundary is devided to 12 i set the number of memory 12.define>user deine>memory*/

DEFINE_PROFILE(pressure_outlet, t, i) /* this macro is used to define values in BCs*/
real pr;
real x[ND_ND];
real y;
face_t f;
int j=0;
if(!Data_Valid_P()) /*check for the availability of data*/
begin_f_loop(f, t)
y=x[0]; /* the outlet line is horizontal and i need the x coordinate*/
if (y>-0.005 && y<0.001) /* there is a face centroid in this interior*/
F_PROFILE(f, t, i) = 100000; /* the desired value of the defined face cell*/
pr=F_UDMI(f,t,j); /* access to stored values for each face*/
F_PROFILE(f, t, i) = pr;
end_f_loop(f, t)
best regard

Last edited by om1234; June 21, 2010 at 09:08.
om1234 is offline   Reply With Quote


Thread Tools
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 On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Import problem ARC Open Source Meshers: Gmsh, Netgen, CGNS, ... 0 February 27, 2010 11:56
[GAMBIT] different boundary condition on one volume face slawek.mikula ANSYS Meshing & Geometry 8 May 2, 2009 11:23
Missing math.h header Travis FLUENT 4 January 15, 2009 12:48
boundary condition of face for liquid and gas Luke FLUENT 6 May 21, 2006 13:45
Trimmed cell and embedded refinement mesh conversion issues michele OpenFOAM Other Meshers: ICEM, Star, Ansys, Pointwise, GridPro, Ansa, ... 2 July 15, 2005 04:15

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