CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT > Fluent UDF and Scheme Programming

3D velocity profile UDF

Register Blogs Community New Posts Updated Threads Search

Like Tree2Likes
  • 1 Post By ghost82
  • 1 Post By ghost82

 
 
LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old   November 16, 2012, 17:31
Default 3D velocity profile UDF
  #1
New Member
 
Hadi
Join Date: Nov 2012
Location: Netherlands
Posts: 2
Rep Power: 0
hadiCFD is on a distinguished road
Hi guys

I would like to define a 3D velocity profile but I don't know how. I read lots of 2D examples, but I am still confused about 3D. Is there any one who can help me?
It is one of the samples for 2D How can I add the third dimension to this code?

The desired velocity is
Vz = (1-(x^2+y^2)/25)

#include "udf.h"

DEFINE_PROFILE(inlet_x_velocity, thread, position)
{
real x[ND_ND]; /* this will hold the position vector */
real y;
face_t f;

begin_f_loop(f, thread)
{
F_CENTROID(x,f,thread);
y = x[1];
F_PROFILE(f, thread, position) = 20. - y*y/(.0745*.0745)*20.;
}
end_f_loop(f, thread)
}
hadiCFD is offline   Reply With Quote

 


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 problems - velocity profile Oli Fluent UDF and Scheme Programming 6 October 24, 2016 10:38
Velocity profile UDF egge24 Fluent UDF and Scheme Programming 2 May 10, 2012 13:03
Logarithmic velocity profile cfdworker Fluent UDF and Scheme Programming 0 April 23, 2009 19:09
How to specify the Velocity profile (eqn) by UDF Anant FLUENT 1 February 27, 2008 14:54
Multi step transient UDF velocity profile problem William177 FLUENT 1 February 3, 2008 06:47


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