Databases#

Warning

Combustion Toolbox v1.2.7 introduces an updated Burcat’s Third Millennium database (latest public release, January 2023), which includes new species entries and revised thermodynamic coefficients for existing ones.

To ensure full compatibility and avoid inconsistencies in thermodynamic lookups, it is strongly recommended to perform a clean installation of the toolbox so that the updated database is correctly loaded.

Combustion Toolbox generates its own databases using an up-to-date version of NASA’s 9-coefficient polynomial fits [McBride, 2002] that incorporates the Third Millennium database [Burcat and Ruscic, 2005], including the available values from Active Thermochemical Tables. This fitting allows to evaluate the dimensionless thermodynamic functions of the species for the specific heat at constant pressure, enthalpy, and entropy as a function of temperature, namely

\begin{eqnarray} c_p^\circ/R &=& a_1T^{-2} + a_2T^{-1} + a_3 + a_4T + a_5T^2 + a_6T^3 + a_7T^4,\\ h^\circ/RT &=& -a_1T^{-2} + a_2T^{-1} \ln{T} + a_3 + a_4T/2 + a_5T^2/3 + a_6T^3/4 \\ &\phantom{{}={}}& + a_7T^4/5 + a_8/T,\\ s^\circ/R &=& -a_1T^{-2}/2 - a_2T^{-1} + a_3\ln{T} + a_4T + a_5T^2/2 + a_6T^3/3 \\ &\phantom{{}={}}& + a_7T^4/4 + a_9, \end{eqnarray}

where \(a_i\) from \(i=1, \dots, 7\) are the temperature coefficients and \(i =8, 9\) are the integration constants, respectively. Depending of the species the polynomials fit up to 20000 K [McBride, 2002]. These values are available in the source code and can be also obtained from NASA’s thermo build website.

To compute the dimensionless Gibbs energy, \(g^\circ (T) / RT\), from NASA’s polynomials we use the next expression

\begin{equation} g^\circ/RT = h^\circ/RT - s^\circ/R, \end{equation}

or equivalently

\begin{eqnarray} g^\circ/RT &=& -a_1T^{-2}/2 + a_2T^{-1} (1 + \ln{T}) + a_3(1 - \ln{T}) - a_4T/2 - a_5T^2/6 - a_6T^3/12 \\ &\phantom{{}={}}& - a_7T^4/20 + a_8/T - a_9. \end{eqnarray}

This data is collected from the thermo_CT.inp file and next formatted into a more accessible structure (DB_master) with the built-in function generate_DB_master.m. Then, for faster data access, we generate a new database DB using griddedInterpolant objects that contain piecewise cubic Hermite interpolating polynomials (PCHIP) [Fritsch and Carlson, 1980]. This allows the evaluation of the thermodynamic functions at a given temperature with ease. The use of piecewise cubic Hermite interpolating polynomials increments the performance of Combustion Toolbox in approximate 200% as shown in Fig. 18 obtaining the same results as seen in Fig. 19.

Note

For temperatures outside the bounds, we avoid the higher order terms of the polynomials by linear extrapolation, similar to Stock et al. [2018], extending the range of validity of the thermodynamic data available. It should be emphasized that this extension is limited to a narrow temperature range and may not apply to temperatures significantly outside of this range.

To evaluate the thermodynamic functions, e.g., the Gibbs energy [kJ/mol] function, or the thermal enthalpy [kJ/mol] of \(\text{CO}_2\) at \(T = 2000 \text{ K}\) is as simple as using these callbacks

g0_CO2  = species_g0('CO2', 2000, DB)
DhT_CO2 = species_DhT('CO2', 2000, DB) 
../../_images/performance_thermo.svg

Fig. 18 Performance test, execution times for over \(10^5\) calculations of the specific heat at constant pressure, enthalpy, Gibbs energy, and entropy, denoted as \(c_p\), \(h_0\), \(g_0\), and \(s_0\), respectively, using the NASA’s 9 coefficient polynomials (dark blue) and the piecewise cubic Hermite interpolating polynomials (teal). The test has been carried out with an Intel(R) Core(TM) i7-8700 CPU @ 3.20GHz. Note: lower is better.#

../../_images/validation_thermo.svg

Fig. 19 Comparison of entropy [kJ/(mol-K)] as a function of temperature [K] obtained using the piecewise cubic Hermite interpolating polynomials (lines) and using the NASA’s 9 coefficient polynomials (symbols) for a set of species.#