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

how to write an UDF programming in 3D

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread 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: 17
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: 17
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


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


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