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

3D velocity inlet UDF

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

LinkBack Thread Tools Display Modes
Old   June 2, 2010, 14:20
Default 3D velocity inlet UDF
New Member
Join Date: Jan 2010
Posts: 11
Rep Power: 7
zumaqiong is on a distinguished road
I have a problem with 3D velocity inlet UDF.
My velocity is parabolic time dependent.
and I write UDF like this:

DEFINE_PROFILE(inlet_y_velocity, thread, position)
real x[ND_ND]; real r; face_t f;
real t;
int n;
real T=1;
real y,z;

begin_f_loop(f, thread)


r=sqrt(pow(y,2)+pow(z,2)); /*radius of cylinder*/


end_f_loop(f, thread)

but if I add #include "surf.h"
at the beginning of this UDF, the velocity is not parabolic. it will be constant changing only with time.

Is there anybody who knows why this will happen?
and what is the meaning of #include "surf.h"?

Thank you!
zumaqiong is offline   Reply With Quote

Old   June 4, 2010, 19:31
New Member
Join Date: Mar 2010
Posts: 17
Rep Power: 7
om1234 is on a distinguished road
as i know, udf.h is used in the beginig of your udf and surf.h is the library that the macros you use in your udf are defined in there. now depending in your importing your udf to fluent, if u use interpret, u dont need to do additional works(and the udf beginig must be udf.h).but when u use compile u must define the library(surf.h) in "add header" next to "add udf"
om1234 is offline   Reply With Quote


3d model, udf inlet boundary, velocity inlet

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
USED UDF for inlet velocity in 3D sara FLUENT 0 October 11, 2007 18:04
Urgent! Help on UDF to set inlet velocity Ray Hong FLUENT 4 December 30, 2005 13:32
udf parabolic velocity inlet with unsteady case Faruk Beyca FLUENT 3 November 28, 2005 15:25
Create hemisphere like velocity profile at inlet Nelson Main CFD Forum 3 July 27, 2005 12:05
UDF paraboloid velocity inlet Ronak Shah FLUENT 0 June 4, 2003 09:44

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