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

how to get pressure and pressure gradient using UDF

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 24, 2012, 06:47
Default how to get pressure and pressure gradient using UDF
  #1
New Member
 
honglin wang
Join Date: May 2012
Posts: 4
Rep Power: 13
Honglin is on a distinguished road
Hello every,

I am newer,. I want to seeking help for UDF.The question is how to get pressure and pressure gradient for Specified boundary or cell adject the boundary after every time steps using UDF. Then setting mass flow rate which it is relation to the pressure and pressure gradien fo next time steps.

First, pressure and pressure gradient using UDF. The fllowing is my UDF code,
but I think it is not correct.

#include"udf.h"
real p ;
real detal p ;

DEFINE_EXECUTE_AT_END
{
Domain *d;

cell_t c;
Thread *t;
face_t f;
d = Get_Domain(1);
t= Lookup_Thread(d, 12);

begin_f_loop(f,t)
{
p = C_P(c,t);
detal p=C(c,t)[i][COLOR="Red"]

}
end_f_loop(f,t)

printf("static pressure = %g\n", p);
printf("pressure gradient= %g\n", detal p)

}


Thanks your help!!!!!!!!!!!!!!!!!
Honglin 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
Pressure BC for combustion chamber Giuki FLUENT 1 July 19, 2011 11:35
Inputting pressure gradient in Fluent Josyula FLUENT 2 December 23, 2009 07:26
Pressure profile UDF for unsteady-state problem? Mohsen Keshavarzian FLUENT 2 August 20, 2008 04:22
UDF to monitor minimum pressure on the wall Arvind Jayaprakash FLUENT 0 September 20, 2007 11:53
pressure gradient??? Mech FLUENT 2 July 5, 2006 07:25


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