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

C_P and C_T not working for me

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

Reply
 
LinkBack Thread Tools Display Modes
Old   July 2, 2009, 03:03
Lightbulb C_P and C_T not working for me
  #1
New Member
 
songok
Join Date: Jul 2009
Posts: 4
Rep Power: 9
mmoja is on a distinguished road
I have a simple C code
real temp= C_T(c,t);
real press =C_P(c,t);
rho = D*pow(press,B)/pow(temp,Q);
for calculating density real gas.D,B and Q are all constants. if i hook up and iterate i get floating point error and when i add some constants value to temp and press it calculates and returns the density of the constant values and ignores the C_T and C_P... What should I do?
mmoja is offline   Reply With Quote

Old   July 2, 2009, 05:18
Default
  #2
Senior Member
 
Max
Join Date: Mar 2009
Posts: 133
Rep Power: 9
coglione is on a distinguished road
Hello mmoja,

this is just a presumption of what may went wrong, but C_P returns the static gauge pressure which may be a negative value depending on your operating pressure and boundary settings! Thus if constant B is not an even number pow(press,B) may become negative as well as your calculated density. A negative density is definitely a problem for any FV-code.

cheers
coglione is offline   Reply With Quote

Old   July 2, 2009, 15:19
Lightbulb
  #3
New Member
 
songok
Join Date: Jul 2009
Posts: 4
Rep Power: 9
mmoja is on a distinguished road
Thanks for the reply, the constant B is 1.01 which is not an even number and my operating pressure is between 1-100bars...not atmospheric. Concerning the boundary conditions I have the gauge pressure as zero at the outlet pressure.... and mass flow for inlet boundary condition...
mmoja is offline   Reply With Quote

Reply

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



All times are GMT -4. The time now is 03:26.