# units in hsEqn

 Register Blogs Members List Search Today's Posts Mark Forums Read

 October 17, 2011, 09:53 units in hsEqn #1 Member   Tibo Join Date: Jun 2011 Posts: 68 Rep Power: 8 Sponsored Links Hi, I am confused about the parameters used in hsEqn (in my case, in reactingFoam: http://foam.sourceforge.net/docs/cpp/a02385_source.html) and their respective units. No problem with the right side: both terms are in kg/(ms3). However, this does not seem to be the case of the terms on the left side. Firstly, hs is supposed to be in J/kmkol (see janafThermo, where it is computed) but kmol wonīt cancel out here. So I assume hs has here the same units as Hs (J/kg). This leaves the first two terms with units kg/(sm3) and the third one with units m2/s3. 1) What is wrong here? I did a similar unit check with UEqn and YEqn and got no problem. 2) Can someone show me why hs should suddenly be in J/kg instead of J/kmol? Where does it get converted? Thx. Tibo

 October 17, 2011, 10:26 #2 Member   Tibo Join Date: Jun 2011 Posts: 68 Rep Power: 8 Ok, first two terms actually are in kg/(ms3) if we assume hs is J/kg, not in J/kmol. My bad. Third term appers to be fine if we multiply it by density. Still: 1) Can someone explain me why hs should suddenly be in J/kg instead of J/kmol? Where does it get converted? 2) Is there a mistake or is the density actually missing in the code? Tibo Last edited by megacrout; October 17, 2011 at 10:44.

 October 17, 2011, 11:02 #3 Senior Member   Adhiraj Join Date: Sep 2010 Location: Maryland, United States Posts: 104 Rep Power: 8 OpenFOAM's definition of Alpha corresponds to "rho times alpha" in terms of units. hs is in units of energy/mass, and the conversion is done when computing hs at the cell level. I think the function hs(T) returns hs(in J/Kmol)/W.

 October 17, 2011, 11:16 #4 Member   Tibo Join Date: Jun 2011 Posts: 68 Rep Power: 8 Thanks for the quick reply Adhiraj. That would explain pretty well what I observed. Can you tell me what files to look at to see what you mention, i.e. can you proof what you wrote? I still have to learn quite a lot about C++ so I might have missed some code specificity too. Thank you. Tibo

 October 17, 2011, 11:33 #5 Senior Member   Adhiraj Join Date: Sep 2010 Location: Maryland, United States Posts: 104 Rep Power: 8 Just check the units of alpha where it is defined. \$FOAM/src/thermophysicalModels/basic/basicThermo For the other thing, you might want to check the file specieThermo files. \$FOAM/src/thermophysicalModels/specie/thermo Hope this helps.

 October 18, 2011, 08:00 #6 Member   Tibo Join Date: Jun 2011 Posts: 68 Rep Power: 8 It does. Thx. I needed some time to understand how reactingFoam is related to basicThermo: it is used in basicPsiThermo which is in turn used in hsCombustionThermo on which reactingFoam is based. I donīt really see how alphaEff ends up being called from basicThermo (i.e. with the properties of basicThermo) to hsEqn though. Can you help me on this?

 October 18, 2011, 08:18 #7 Senior Member   Adhiraj Join Date: Sep 2010 Location: Maryland, United States Posts: 104 Rep Power: 8 I believe that the turbulence model had a copy of the thermo package, and could thus access the alpha value. But I don't work in turbulence, and further do not use OpenFOAM's transport models, so I am not qualified enough to answer this.

 Tags hseqn, reactingfoam, units

 Thread Tools Display Modes Linear Mode

 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 OffTrackbacks are On Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post megacrout OpenFOAM 4 July 19, 2011 08:04 SoobY ANSYS Meshing & Geometry 2 January 10, 2011 04:58 nite_surfer FLUENT 0 July 12, 2007 12:51 Rob Phoenics 1 March 30, 2005 10:06 tolani owosina Main CFD Forum 8 November 13, 1999 14:45

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