CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   Ideal Gas Law Overspecification (http://www.cfd-online.com/Forums/openfoam/90402-ideal-gas-law-overspecification.html)

Cyberholmes July 8, 2011 16:53

Ideal Gas Law Overspecification
 
I was wondering, in the OpenFOAM solver buoyantPimpleFoam, you specify the pressure and temperature in the initial conditions, the volume by creating the geometry that you mesh, and the number of moles of gas in the thermophysicalProperties file. Because of this, you have specified every variable in the equation

pV=nRT.

Isn't this overspecification? Why does the solver not return an error if your set conditions do not adhere to this law, and what are the effects on the solution if they don't?

Thank you.

lichmaster July 11, 2011 03:17

Hi,

I don't know what equations does buoyantPimpleFoam solve, however I bet you're not specifying V with the mesh, since V in the perfect gas laws is a specific volume (inverse of density)... setting P, T and n you can solve for local values of V (or rho, if you prefer), and no overspec occours

Cyberholmes July 11, 2011 10:34

Except that's not the case in the following formula:

pV=nRT.

The volume is a specific volume in the equation

p V_specific = R_specific T.

However, in pV=nRT, p is absolute pressure, V is volume of the chamber (not specific), n is number of moles, R is the molar gas constant, and T is the temperature. Every value in that equation is specified in the solver.

Chris Lucas July 11, 2011 10:58

Hi,

the number of moles within the control volume (grid) is NOT specified. The number of moles you specify in the thermophysical properties is used for mixtures only. The perfect gas law is used to get the density.


Hope this helps :)


Regards,
Christian

Cyberholmes July 11, 2011 11:35

I'm sorry, but what do you mean by 'used for mixtures only'? What exactly is that number of moles specifying?

lichmaster July 12, 2011 04:04

Cyberholmes,
I always work with specific or intensive dimensions, so n for me is moles/kg, and thus volume becomes a specific volume also... You're also right, it just depends how you're used to work...

Cyberholmes July 12, 2011 10:46

The question though is how is OpenFOAM working?


All times are GMT -4. The time now is 21:48.