CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

Strange nheptane density

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   September 8, 2008, 07:48
Default I investigated some fluid prop
  #1
Member
 
Tomislav Sencic
Join Date: Mar 2009
Posts: 42
Rep Power: 17
tsencic is on a distinguished road
I investigated some fluid properties and I found a strange low density for heptane used in OpenFOAM.
In src/thermophisicalModels/liquids/C7H16 is said that density is described by NSRDSfunc5 with coefficients (61.38396836, 0.26211, 540.2, 0.28141).
In src/thermophysicalModels/thermophisicalFunctions/NSRDSfunctions/NSRDSfunc5.h is given the function:
return a/pow(b,1+pow(1-T/c,d))
When I print this on a graph, I obtain a density that is lower than 360kg/m3, while I think it should be over 700kg/m3.
Beside other sources, the NIST pages on the web http://webbook.nist.gov/chemistry/fluid/
conferm that it should be around 700kg/m3.
Is it a mistake or I am missing something?
tsencic is offline   Reply With Quote

Old   September 8, 2008, 10:31
Default I've checked the data and it l
  #2
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
I've checked the data and it looks ok to me.
at what temperature and pressure are you looking?

approximate values...
rho(T = 300) = 679
rho(T = 400) = 585
rho(T = 500) = 446
rho(T = 540) = 270

the data is using the NSRDS functions and coefficients (reference is in the source-files)

and is only valid at around athmospheric pressures and up to critical temperature (around 540 K), but I'd say that accuracy around critical conditions is probably poor.

NIST also reveals that at p=1bar liquid does not exist above ~370K (which is ~normal boiling point)

at 100 bar NIST yields
rho(300K) ~ 687
rho(500K) ~ 509
rho(540K) ~ 463

so not too shabby by NSRDS neglecting the pressure influence Id say
niklas is offline   Reply With Quote

Old   September 9, 2008, 03:12
Default Sorry, my mistake! n-heptane i
  #3
Member
 
Tomislav Sencic
Join Date: Mar 2009
Posts: 42
Rep Power: 17
tsencic is on a distinguished road
Sorry, my mistake! n-heptane is OK.
It is n-heksadecane C16H34 that has strange low density:
coeffs: rho_(61.94656776, 0.25442, 720.6, 0.3238),
func: return a_/pow(b_, 1 + pow(1 - T/c_, d_));
aproximate values
rho(T = 300) = 355
rho(T = 400) = 332
rho(T = 500) = 305
rho(T = 540) = 293

I do not have the refference, but I would expect that C16H34 has bigger density.
tsencic is offline   Reply With Quote

Old   September 9, 2008, 07:07
Default Yup, something is weird here..
  #4
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
Yup, something is weird here...

I ran hexadecane in supertrapp and got this:
p = 100 bar.
rho(T=300) = 790.2
rho(T=400) = 708.4
rho(T=500) = 637.6

for n-heptane:
rho(T=300) = 686.3
rho(T=400) = 601.6
rho(T=500) = 504.0

so supertrapp predicts reasonable values for n-heptane, but that is not a guarantee that it will do so for hexadecane, however, its supposed to be pretty accurate for hydrocarbons.

so I then ran hexadecane in openfoam and got this.
rho(T=300) = 768.8
rho(T=400) = 697.9
rho(T=500) = 618.9

so Im guessing the mistake is on your side.

this was my setup in thermophysicalProperties.

liquidComponents
(
C16H34
);

liquidProperties
{
C16H34 C16H34 defaultCoeffs;
}
niklas is offline   Reply With Quote

Old   September 16, 2008, 17:57
Default Hi! I have a short question
  #5
New Member
 
Boris Elling
Join Date: Mar 2009
Posts: 2
Rep Power: 0
borise is on a distinguished road
Hi!

I have a short question to those of you who solve the equation of state for a number of liquids.

The NIST webpage includes calculations for greenhouse gases like C02 and CH4. Are these equations included in Openfoam or in some other software (together with the sourcecode)?

thanks!
Boris
borise is offline   Reply With Quote

Old   September 17, 2008, 02:08
Default Short answer is - nope. Even
  #6
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
Short answer is - nope.
Even shorter is - no haha.

A while back i implemented Peng Robinson EOS and sent it to Henry, but it has not been included yet
and I think its because he really wants to re-write the entire thermo treatment before making it into an even bigger beast.
For ideal gases it's ok, but its hard to extend it to handle mixtures with complex mixing rules.
niklas is offline   Reply With Quote

Old   September 17, 2008, 10:40
Default Thank you, Niklas, for the sho
  #7
New Member
 
Boris Elling
Join Date: Mar 2009
Posts: 2
Rep Power: 0
borise is on a distinguished road
Thank you, Niklas, for the short answer. I am also interested in EOS calculators outside of Openfoam. As long as these are open source, it shouldn't be too difficult to access them from Openfoam.

I am asking, because the project freesteam.sourceforge.net was mentioned in another post, which calculates the IAPWS water and steam properties.

In fact the IAPWS formulation appears to be based on the methane formulation, and so I am wondering whether the following two references have been the target of a project like freesteam, which would be interesting for atmospheric modelling:

Span, R., Wagner, W. A new equation of state for carbon dioxide covering the fluid region from the triple-point temperature to 1100 K at pressures up to 800 MPa. J. Phys. Chem. Ref. Data 25 (1996) 1509-1596

Setzmann, U., Wagner, W. A new equation of state and tables of the thermodynamic properties for methane covering the range from the melting line to 625 K at pressures up to 1000 MPa. J. Phys. Chem. Ref. Data 20 (1991) 1061-1155

Boris
borise is offline   Reply With Quote

Old   June 29, 2009, 06:52
Default Peng-Robinson EOS
  #8
Member
 
Hamed Aghajani
Join Date: Mar 2009
Location: London, UK
Posts: 77
Rep Power: 17
haghajani is on a distinguished road
Dear All,

I want to implement Peng-Robinson EOS, and make use of it in carbon dioxide high pressure release.

I think it is not included yet as Niklas mentioned; I coludn't find it, at least.

Would you please let me have you advise on the how to derive it suitable for OF.

As I had a look into current perfect gas Eos, it seems the psi(rho/P) parameter is more important than rho. Because, later rho is been calculate by, rho = p_*psi

Please let me have your kind advise,

Best Hamed
haghajani is offline   Reply With Quote

Old   August 11, 2014, 11:49
Default
  #9
Member
 
yes
Join Date: Apr 2014
Posts: 32
Rep Power: 12
ENKIME is on a distinguished road
Good Day Mr. Nordin
Did you know where the NSRDS get their equation for density, surface tensión, etc.?
Maybe a good source, I was looking but it seems kind off hard track
Kind regards
ENKIME is offline   Reply With Quote

Old   July 18, 2018, 03:14
Default
  #10
New Member
 
Shailja
Join Date: Nov 2017
Posts: 16
Rep Power: 8
Shailja is on a distinguished road
Quote:
Originally Posted by niklas View Post
Yup, something is weird here...

I ran hexadecane in supertrapp and got this:
p = 100 bar.
rho(T=300) = 790.2
rho(T=400) = 708.4
rho(T=500) = 637.6

for n-heptane:
rho(T=300) = 686.3
rho(T=400) = 601.6
rho(T=500) = 504.0

so supertrapp predicts reasonable values for n-heptane, but that is not a guarantee that it will do so for hexadecane, however, its supposed to be pretty accurate for hydrocarbons.

so I then ran hexadecane in openfoam and got this.
rho(T=300) = 768.8
rho(T=400) = 697.9
rho(T=500) = 618.9

so Im guessing the mistake is on your side.

this was my setup in thermophysicalProperties.

liquidComponents
(
C16H34
);

liquidProperties
{
C16H34 C16H34 defaultCoeffs;
}
Hii Niklas

I want to clear similar confusion on sigma value of C7H16.C using formulation as defined in NSRDFfunc6 a_*pow(1 - Tr, ((e_*Tr + d_)*Tr + c_)*Tr + b_); calculated sigma value
is coming ~264 N/m at 320 K while reference value is 1.85E-2 N/m (taking Tc 540.2K) at the same temperature.

I want to calculate SMD of droplet which is directly related to sigma values provided.
So I tried to make new library of C7H16.C renamed as nC7H16.C in my user library of OpenFoam keeping same pathways as in original code and compiled new libmyliquidlibrary.so, still while running the code sprayFoam, i get follwing error:


code:

--> FOAM FATAL ERROR:
liquids requested, but object is not allocated

From function const Foam::liquidMixtureProperties& Foam::SLGThermo::liquids() const
in file SLGThermo/SLGThermo.C at line 125.



I also defined liquidcomponents and properties in thermophysicalProperties file in similar fashion as you have described in post no. #4 of this conversation. but it seems that new liquid library is not being taken into account.

I also went through tutorials provided by TFD chalmers on the topic but nothing seem working. Please give your suggestions.......

I am using OpenFoam 4.1 on Ubuntu 16.04 with gcc version 5.4.

Do I need to include new liquid library in $FOAM_SRC/thermophysicalModels/properties/liquidProperties/ along with other liquids ??

regards
Shailja
Shailja 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
strange error emre FLUENT 4 July 20, 2011 19:17
mass density or weight density jaichan Main CFD Forum 0 April 2, 2006 18:45
Is it strange? Q FLUENT 0 January 13, 2006 08:28
Strange ? bob FLUENT 1 May 12, 2004 03:16
strange phenominon dan Main CFD Forum 1 March 29, 2004 23:45


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