Total enthalpy (sensible + chemical) for each species

295 views
Skip to first unread message

Solal Amouyal

unread,
Aug 31, 2017, 5:10:16 AM8/31/17
to Cantera Users' Group
Hi,

In my CFD code, I need to get the total enthalpy of each species at every grid point. So far here's the way I'm doing it for species "s":
- Set all moles fractions to 0 except for species "s" which is 1
- call "setState_TPX" with local temperature, pressure and mole fraction previously defined
- get enthalpy from enthalpy_mass(my_gas)

This seems to be an overkill. I could numerically integrate the temperature along Cp and add it to the enthalpy of formation at the reference state. Another method would be to tabulate all the total enthalpies for each species for the expected temperature range and then interpolate. However, I first wanted to know if there was any built in function or a better way to do it with Cantera? Even if it involves introducing minor changes to the source code.

Thanks,

Solal Amouyal

Ray Speth

unread,
Aug 31, 2017, 1:42:22 PM8/31/17
to Cantera Users' Group
Solal,

What interface are you using? The underlying C++ functions that provide the information you're looking for are ThermoPhase::getPartialMolarEnthalpies and ThermoPhase::getEnthalpy_RT. There is certainly no need to integrate or tabulate anything yourself.

Regards,
Ray

Solal Amouyal

unread,
Sep 3, 2017, 5:33:56 AM9/3/17
to Cantera Users' Group
Ray,

Thank you for your answer.

I am using the Fortran interface, which contains ThermoPhase::getEnthalpy_RT but not ThermoPhase::getPartialMolarEnthalpies. I just compared the former with thermodynamic tables and it seems to yield what I want.

Out of curiosity, what is the difference between the two? Just the non-dimensionalization?

Thank you!

Solal Amouyal

Ray Speth

unread,
Sep 3, 2017, 7:10:24 PM9/3/17
to Cantera Users' Group

Solal,

Besides the nondimensionalization, the values returned by getPartialMolarEnthalpies include any nonideal effects (e.g. non-unity activity coefficients) while those returned by getEnthalpy_RT do not. Of course, for an ideal gas these are same so it doesn’t matter for your application.

Regards,
Ray

Reply all
Reply to author
Forward
0 new messages