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

UDF - Inlet Velocity Profile (Ansys Fluent)

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 2, 2015, 09:18
Default UDF - Inlet Velocity Profile (Ansys Fluent)
  #1
New Member
 
vinayak
Join Date: Oct 2013
Posts: 19
Rep Power: 13
vinayak4399 is on a distinguished road
Hi Everyone,
I want to write a UDF at inlet with velocity profile of fully developed flow.
The geometry is 3D, having 25.4 mm inlet diameter & free stream velocity is 1 m/s.

Also in case of pressure inlet or mass flow inlet boundary condition , there is no need to put velocity profile.
Then how we can say that flow is hydrodynamically fully developed.

It would be helpful to me , If any one gives solution.
Thanks.
vinayak4399 is offline   Reply With Quote

Old   June 26, 2020, 18:04
Default
  #2
Senior Member
 
acalado's Avatar
 
André
Join Date: Mar 2016
Posts: 133
Rep Power: 10
acalado is on a distinguished road
Check the below

Quote:
/************************************************** *********************
vprofile.c
UDF for specifying steady-state velocity profile boundary condition
************************************************** **********************/

#include "udf.h"

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

h = 0.016; /* inlet height in m */

begin_f_loop(f,thread)
{
F_CENTROID(x, f, thread);
y = 2.*(x[1]-0.5*h)/h; /* non-dimensional y coordinate */
F_PROFILE(f, thread, position) = 0.1*(1.0-y*y);
}
end_f_loop(f, thread)
}
https://www.afs.enea.it/project/nept...df/node243.htm
__________________
Sapere aude!
acalado is offline   Reply With Quote

Old   August 25, 2020, 11:27
Default
  #3
New Member
 
Kaboka
Join Date: Dec 2019
Posts: 19
Rep Power: 6
kaboka is on a distinguished road
Quote:
Originally Posted by acalado View Post

Hello acalado,

I am also working on a Define_Profile velocity, my case is very similar with that problem but I don't get why they define an extra "h" and put that into the definition of "y". Do you know how the code works in that system and do we have to define the position of coordinate vectors like that or is it enough to say y = x [1] and insert that code into inlet boundary condition Does UDF understand where is the [0,0] point of my coordinates? Would be very appreciated if you answer. Thanks.

Best regards,
Bora
kaboka is offline   Reply With Quote

Old   August 25, 2020, 15:15
Default
  #4
Senior Member
 
acalado's Avatar
 
André
Join Date: Mar 2016
Posts: 133
Rep Power: 10
acalado is on a distinguished road
Quote:
Originally Posted by kaboka View Post

Hello acalado,

I am also working on a Define_Profile velocity, my case is very similar with that problem but I don't get why they define an extra "h" and put that into the definition of "y". Do you know how the code works in that system and do we have to define the position of coordinate vectors like that or is it enough to say y = x [1] and insert that code into inlet boundary condition Does UDF understand where is the [0,0] point of my coordinates? Would be very appreciated if you answer. Thanks.

Best regards,
Bora
The y should be x[1] with global system coordinates you have in your geometry but this should be easy to check. The h parameter is just the height of the channel which is used to scale the parabolic velocity profile.
__________________
Sapere aude!
acalado 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 profile: Fluent method for coupling inlet and outlet I-mech Fluent UDF and Scheme Programming 0 May 10, 2014 11:36
Velocity inlet user defined function UDF in fluent Ammofreak Fluent UDF and Scheme Programming 0 January 14, 2014 05:59
(UDF) Sinusoidal inlet velocity in Fluent star Fluent UDF and Scheme Programming 1 December 19, 2013 17:23
logarithmic velocity profile for velocity inlet in Fluent amarendernag FLUENT 3 August 25, 2012 06:44
Ansys FLUENT UDF - Velocity profile (of known values) across edge / surface emmkell Fluent UDF and Scheme Programming 2 October 21, 2011 14:12


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