CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > FLOW-3D

how to write an UDF programming in 3D

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

Reply
 
LinkBack Thread Tools Display Modes
Old   March 16, 2009, 09:15
Default how to write an UDF programming in 3D
  #1
New Member
 
oscar
Join Date: Mar 2009
Posts: 7
Rep Power: 7
coolyihao is on a distinguished road
i have a 3D domain as a seawater and a turbine locate inside the seawater.. I had set the inlet as velocity inlet in Gambit..And now come into Fluent, i have to use a UDF programming to set a parabolic flow veloctiy inlet and difference pressure at the inlet.. cuz when the increasing the depth(h) , pressure will increse as well.. But i dont know how to write a programme about this 3D domain... Anyone can help? thanks
coolyihao is offline   Reply With Quote

Old   March 16, 2009, 09:59
Default
  #2
New Member
 
Mavis Milton
Join Date: Mar 2009
Posts: 10
Rep Power: 7
milton.tafadzwa is on a distinguished road
You can try this maybe it will work.
#include "udf.h"
Define all your constants here.
DEFINE_PROFILE(inlet_velocity, thread, index)
{
real x[ND_ND];
real y, z;
face_t f;
begin_f_loop(f, thread)
{
F_CENTROID(x,f,thread);
y =? ; write value of z and y at your entrance.
z=?;
F_PROFILE(f, thread, index) = write your parabolic equation here;
}
end_f_loop(f, thread)
}
milton.tafadzwa is offline   Reply With Quote

Reply

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
UDF programming fullmonty FLUENT 5 June 30, 2011 02:40
Whose programming is more difficult?DNS or LES? Adonis Main CFD Forum 5 January 6, 2006 16:23
programming fluent pieizquierdo (miguel) FLUENT 2 January 14, 2005 10:29
Programming in CFD Lam Main CFD Forum 7 May 27, 2004 05:12
Programming in C Tony Main CFD Forum 5 March 7, 2002 12:40


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