Databases#
Combustion Toolbox generates its own databases taking into account the NASA-9 polynomials fitting to evaluate the dimensionless thermodynamic functions of the species for the specific heat, enthalpy, and entropy as function of temperature, namely
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 [1]. 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_i^\circ (T) / RT\), from NASA’s polynomials we use the next expression
or equivalently
This data is collected and formatted into a more accessible structure. We can distinguish from:
DB_master
: structured database from NASA’s thermo file.DB
: structured database with piecewise cubic Hermite interpolating polynomials and linear extrapolation for faster data access.
The use of piecewise cubic Hermite interpolating polynomials increments the performance of Combustion Toolbox in approximate 200% as shown in Figure 1 obtaining the same results as seen in Figure 2. 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)
Figure 1: 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.
Figure 2: 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.
Another important parameter comes from the conservation of mass, which is the stoichiometric matrix \(A_0\), by generalizing this constraint condition we have
or in matricial form
where \(a_{ij}\) are the stoichiometric coefficients of the species, which represent the number of atoms of element \(i\) per mole of species \(j\). The number of moles and the total number of atoms of the \(j\) species and \(i\) element reads \(n_j\) and \(b_i\), respectively. This is computed during the initialization of the variable self
. Using one of the predefined list of species, e.g., soot formation
, this can be initializate as
self = App('soot formation')
A simple test can be performed by considering the global exothermic reaction of hydrogen bromide with \(n_j\) moles
which have only three species involve. The system obtained is
A quick check using Combustion Toolbox:
self = App({'H2', 'Br2', 'HBr'});
print_stoichiometric_matrix(self, 'transpose')
Transpose stoichiometric matrix:
H2 Br2 HBr
__ ___ ___
BR 0 2 1
H 2 0 1
McBride, Bonnie J. NASA Glenn coefficients for calculating thermodynamic properties of individual species. National Aeronautics and Space Administration, John H. Glenn Research Center at Lewis Field, 2002.