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

Pressure Initial Conditions

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

Reply
 
LinkBack Thread Tools Display Modes
Old   February 26, 2012, 17:04
Unhappy Pressure Initial Conditions
  #1
New Member
 
OscarD
Join Date: Sep 2011
Posts: 4
Rep Power: 6
OscarD is on a distinguished road
Hi,
I've been trying to set initial values of pressure and temperature in a simple 2d-axisymmetric geometry that generates an enclosed volume, with no inlet/outlet for fluid, steady state.
I got the initialization of all the cells' temperature as I wanted by using DEFINE_INIT (coaxial values of same value ), but when it comes to pressure, it starts ok beside the axis, but when it continues radially, the value drops to almost -Pmax!!
Am I forgetting to set something within the UDF or in the FLUENT case?

Thanks in advance for any help related!!!

PS. The 'complex' code I'm using (just omitted the definition and value of the pX and tY constants)


************************************************** ********
#include "udf.h"

DEFINE_INIT(init_temp_press,d)
{

cell_t c;
Thread *t;
real xc[ND_ND]
thread_loop_c(t,d)
{

begin_c_loop_all(c,t)
{
C_CENTROID(xc,c,t);
if(xc[1] < 4.7e-4)
C_T(c,t) = t1*pow(xc[1],9.) + t2*pow(xc[1],8.) + t3*pow(xc[1],7.) + t4*pow(xc[1],6.) + t5*pow(xc[1],5.) + t6*pow(xc[1],4.) + t7*pow(xc[1],3.) + t8*pow(xc[1],2.) + t9*xc[1] + t10;
else
C_T(c,t) = 293;

if(xc[1] < 4e-4)
C_P(c,t) = p1*pow(xc[1],8.) + p2*pow(xc[1],7.) + p3*pow(xc[1],6.) + p4*pow(xc[1],5.) + p5*pow(xc[1],4.) + p6*pow(xc[1],3.) + p7*pow(xc[1],2.) + p8*xc[1] + p9;
else
C_P(c,t) = 6800;

end_c_loop_all(c,t)
}
}
}


************************************************** ******
OscarD is offline   Reply With Quote

Old   June 4, 2013, 02:37
Default with respect to your problem
  #2
New Member
 
zhang guoqing
Join Date: May 2011
Posts: 10
Rep Power: 7
qing123 is on a distinguished road
Dear Sir:
Recently I have met the same problem as yours. Have you solved it? Could you tell me the steps to use this UDF in Fluent? Thank you so much for your help.
Yours
Zhang
qing123 is offline   Reply With Quote

Reply

Tags
initial conditions, pressure, udf

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
Forces in OF15 richard OpenFOAM Running, Solving & CFD 167 June 18, 2016 06:04
SLTS+rhoPisoFoam: what is rDeltaT??? nileshjrane OpenFOAM Running, Solving & CFD 4 February 25, 2013 05:13
Error log vw.cfd OpenFOAM 6 August 7, 2009 05:44
Computational time sunnysun OpenFOAM Running, Solving & CFD 5 March 16, 2009 04:32
Could anybody help me see this error and give help liugx212 OpenFOAM Running, Solving & CFD 3 January 4, 2006 19:07


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