CFD Online Discussion Forums

CFD Online Discussion Forums (
-   CFX (
-   -   How to set the properties of a real gas (

kiwishall June 19, 2013 04:07

How to set the properties of a real gas
I'd like to define a real gas. However I can't be sure how to set the property such as the density and the specific heat with the expressions. So for a real gas, I should set the density as a function of T and P or just T? And the specific heat?
Thanks in advance!

ghorrocks June 19, 2013 19:12

Have you read the documentation? Have a look at the real gas models in CFX. Also, your comments suggest you are looking for simply a variable density fluid (eg ideal gas), not a real gas.

kiwishall June 19, 2013 21:35

Thanks for your reply!
I have read the help documents. What I need is a material of which the properties vary with T and P,not only the density. The problem is that CFX doesn't work if everything is set as the function of T and P.

ghorrocks June 20, 2013 06:30

Which properties do you want to have as a function of T and P? And what function do you want to use?

kiwishall June 20, 2013 07:14

I set the specific heat as the function of P and T. But when I set the density as the function of P or both P and T, error occurs. So I want to know others how to set the properties of dynamic and thermodynamic and how to get a better simulation of the actual property value.

ghorrocks June 20, 2013 18:46

Setting the density as a function of P and T leads to some very complex terms in the Navier Stokes equations. For gases like ideal gas, and the real gas models these have been taken care of, but if you arbitrarily make up a new constitutive equation they are not accounted for - which is why CFX does not let you do it.

What function are you trying to apply for density?

kiwishall June 20, 2013 21:54

I want to set it as a function of T by expressions. And I have gotten a result which is obvious wrong. I don't know why. How do you define a mixture property? Regarding it as a pure substance or mix two pure substance in CFX?

ghorrocks June 21, 2013 03:43

CFX already has models to work out the properties of mixtures. If you are modelling a mixture then best define it as its constitutive gases and use a mixture model to work out the properties.

kiwishall June 21, 2013 06:07

Is there any other mixture model except the ideal mixture model?

ghorrocks June 21, 2013 07:57

Not that I know of, but if you talk to CFX support there may be others.

Do you have a model where the ideal mixture model is not adequate?

kiwishall June 21, 2013 08:14

I don't know. But when I mix the substance with rgp files, the solve suggests that Newtons method failed to converge in100 iterations. Even increase the number, the suggestions still occurs. Besides, if only taking one substance into account, one material is gas while the other one is liquid at the working condition. But if I regard the mixture as a pure substance and get the properties in NIST REFPRO, I found the mixture is at the state of gas. So if I only define the material at the liquid state, is it right? And how should I do ?

ghorrocks June 21, 2013 08:38

Can you please tell us what materials are in your mixture?

kiwishall June 21, 2013 08:42

Methane and ethane. T is about from 200K to 240K. P is from 3MPa to 6MPa.

ghorrocks June 21, 2013 09:23

Are they both gasses at this T/P ranges? If they are both gasses then this should be easy with the multicomponent mixture model. If they start to change phase things are a lot more complex, but a multicomponent mixture of a real gas model of each of methane and ethane look like they would work.

kiwishall June 21, 2013 09:27

NO...Ethane is at state of liquid. That is why I ask for help.

ghorrocks June 21, 2013 09:34

The Peng Robinson real gas model looks like it should be able to cover both vapour and liquid phases - can you use this real gas model to cover it? Which real gas model did you use before?

Note I am saying to use one Peng Robinson real gas model for methane and another one for ethane and combine them together in a multicomponent fluid.

kiwishall June 21, 2013 10:01

I didn't use the real gas model for I get the details from the NIST REFPRO. And I define the material with values but not real gas model.
For the real gas model, is there any easy way to get the parameters such as the zero pressure coefficients?

ghorrocks June 23, 2013 06:36

I have not looked for this sort of data before for methane and ethane but they are pretty standard engineering gases so should be available. A hunt around and you should find it.

kiwishall June 23, 2013 11:50

Okay! Thauk you for your help in the recent days!

All times are GMT -4. The time now is 01:15.