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

DEFINE_PROPERTY for solid density

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By macfly

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   September 28, 2014, 03:29
Default DEFINE_PROPERTY for solid density
  #1
Senior Member
 
François Grégoire
Join Date: Jan 2010
Location: Canada
Posts: 392
Rep Power: 17
macfly is on a distinguished road
Hi,

I'm trying to set the density of aluminum via a very simple interpreted DEFINE_PROPERTY udf :
Code:
#include "udf.h"
DEFINE_PROPERTY(my_density, c, t)
{
real rho;
rho=1000;
return rho;
}
I don't understand why it doesn't work, after the solution is converged Fluent returns that the density of aluminum is the default value of 2719 kg/m³, see the pictures. What am I missing? (and yes, I click the Change/Create button before closing the Create/Edit Materials window)
Attached Images
File Type: png 001.png (19.9 KB, 18 views)
File Type: png 002.png (15.4 KB, 16 views)

Last edited by macfly; September 28, 2014 at 13:44.
macfly is offline   Reply With Quote

Old   September 28, 2014, 05:20
Default
  #2
Senior Member
 
ghost82's Avatar
 
Rick
Join Date: Oct 2010
Posts: 1,016
Rep Power: 27
ghost82 will become famous soon enough
Maybe a bug?
Here is the same problem:
http://www.cfd-online.com/Forums/flu...d-density.html

However it seems fluent use the custom defined values for calculation.
Which fluent version do you have?
ghost82 is offline   Reply With Quote

Old   September 28, 2014, 08:21
Default
  #3
Senior Member
 
François Grégoire
Join Date: Jan 2010
Location: Canada
Posts: 392
Rep Power: 17
macfly is on a distinguished road
Yes, I saw that other thread.

I'm using 14.5.7
macfly is offline   Reply With Quote

Old   September 28, 2014, 14:41
Default
  #4
Senior Member
 
François Grégoire
Join Date: Jan 2010
Location: Canada
Posts: 392
Rep Power: 17
macfly is on a distinguished road
My udf works fine for setting the Specific Heat or Thermal Conductivity, it's just with the Density that it doesn't work.
macfly is offline   Reply With Quote

Old   September 29, 2014, 01:29
Default
  #5
Senior Member
 
François Grégoire
Join Date: Jan 2010
Location: Canada
Posts: 392
Rep Power: 17
macfly is on a distinguished road
Ok I retrieved the value of the solid density with C_R(c,t) within a DEFINE_EXECUTE_AT_END macro and I get the value I set in my udf. It looks as if it's just a postprocessing bug.
ghost82 likes this.
macfly 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
Current density visualisation (PEM fuel cell add-on module) pchoopanya FLUENT 10 August 21, 2023 15:33
How to model Salinity, density, fresh water & sea water grayback87 FLUENT 3 December 30, 2014 03:00
A problem about density in liquid air definition alloveyou CFX 2 June 14, 2012 15:20
REAL GAS UDF brian FLUENT 6 September 11, 2006 09:23
Warning 097- AB Siemens 6 November 15, 2004 05:41


All times are GMT -4. The time now is 13:59.