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

How to access species molecular weight in UDFs

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 12, 2009, 15:20
Default How to access species molecular weight in UDFs
  #1
Ellen
Guest
 
Posts: n/a
Hi,

I'm trying to write a User-defined mixing law for a species transport problem, and I need to use the molecular weight of species in the calculation. First I tried to use the macro C_RGAS(c,t) to get Mw: Mw = UNIVERSAL_GAS_CONSTANT/C_RGAS(c,t); but this didn't work, since C_RGAS returns 0 in my testing.

I saw that some DEFINE macros use Mw as one of its arguments, such as DEFINE_VR_RATE, but I don't know how to apply that to the macro I use (DEFINE_PROPERTY).

Could anyone please help me on how to access the molecular weight data? Thank you very much.

Ellen
  Reply With Quote

Old   March 13, 2009, 00:16
Default Re: How to access species molecular weight in UDFs
  #2
sathees kannan
Guest
 
Posts: n/a
molecular weight is a constant value. so, no need to get this as arguments. You just define like, MW_Water=18, MW_Air=29 inside your DEFINE Macro.
  Reply With Quote

Old   March 13, 2009, 11:17
Default Re: How to access species molecular weight in UDFs
  #3
Ellen
Guest
 
Posts: n/a
Thanks for replying me, Sathees. But I can't define them as constants in the program. I need to obtain these values for calculation in a species loop, I think there should be a macro for accessing the molecular weight...

Ellen
  Reply With Quote

Old   June 2, 2019, 19:55
Default
  #4
Senior Member
 
Weiqiang Liu
Join Date: Feb 2018
Posts: 278
Rep Power: 9
Weiqiang Liu is on a distinguished road
Quote:
Originally Posted by Ellen
;157395
Thanks for replying me, Sathees. But I can't define them as constants in the program. I need to obtain these values for calculation in a species loop, I think there should be a macro for accessing the molecular weight...

Ellen
Hi
have you solved this problem?
Weiqiang Liu 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 and molecular weight ? Jane FLUENT 0 January 2, 2009 04:17
Unit of Molecular weight clark FLUENT 2 March 15, 2008 05:28
How get Species Molecular Weight in UDF hesam FLUENT 1 April 14, 2007 18:55
UDFs for species molecular wt Sisir FLUENT 0 February 18, 2007 10:02
Molecular Weight Ari FLUENT 0 August 22, 2004 07:36


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