CFD Online Logo CFD Online URL
Home > Forums > Software User Forums > ANSYS > FLUENT

UDF fluent:Change boundary condition. determination inlet and outlet boundary in "t"

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

LinkBack Thread Tools Search this Thread Display Modes
Old   September 27, 2015, 05:32
Default UDF fluent:Change boundary condition. determination inlet and outlet boundary in "t"
New Member
Join Date: Sep 2015
Posts: 11
Rep Power: 10 is on a distinguished road
hi everybody
I want to simulate far field boundary for incompressible flow. in my model , far field boundary is circle. in each step time, I want fluent to specify inlet and outlet boundary. for this purpose, I consider this condition:
1. u.n<0 inlet boundary
2.u.n>0 outlet boundary

n is normal vector, u is velocity vector.

I would like to know how could I apply this condition in fluent. I guess I should develop a UDF do you think that my way is correct?

I appreciate your help!

my udf is as follows:

/* UDF for determination of inlet and outlet */
#include "udf.h"
#include "sg.h"

Domain *d;
face_t f;
Thread *t;
real velocity_vector[2], mag_velocity, normal_vec, mag_normal_vec;
real A[ND_ND], ds, es[ND_ND], A_by_es, dr0[ND_ND];
real X_component,Y_component, Guage_Pressure;
int ID=12; /*Zone ID for farfield zone from boundary condition task page*/
/* find velocities*/

/* magnitude of velocity vector*/
/* magnitude of normal vector*/
/* attack angle*/
double teta=0;
if((mag_velocity* mag_normal_vec*cos(teta))<0)
X_component=F_U(f,t); Y_component=F_V(f,t);
} is offline   Reply With Quote


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
Wind turbine simulation Saturn CFX 58 July 3, 2020 01:13
map outlet boundary profile as an inlet condition using UDF Daniel_Khazaei Fluent UDF and Scheme Programming 2 June 20, 2016 11:53
Wrong flow in ratating domain problem Sanyo CFX 17 August 15, 2015 06:20
An error has occurred in cfx5solve: volo87 CFX 5 June 14, 2013 17:44
Convective Heat Transfer - Heat Exchanger Mark CFX 6 November 15, 2004 15:55

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