Heat Capacity (chemicals.heat_capacity)

This module contains many heat capacity model equations, heat capacity estimation equations, enthalpy and entropy integrals of those heat capacity equations, enthalpy/entropy flash initialization routines, and many dataframes of coefficients.

For reporting bugs, adding feature requests, or submitting pull requests, please use the GitHub issue tracker.

Gas Heat Capacity Model Equations

chemicals.heat_capacity.TRCCp(T, a0, a1, a2, a3, a4, a5, a6, a7)[source]

Calculates ideal gas heat capacity using the model developed in [1]. The ideal gas heat capacity is given by:

Cp=R(a0+(a1/T2)exp(a2/T)+a3y2+(a4a5/(Ta7)2)yj)C_p = R\left(a_0 + (a_1/T^2) \exp(-a_2/T) + a_3 y^2 + (a_4 - a_5/(T-a_7)^2 )y^j \right)
y=Ta7T+a6 for T>a7 otherwise 0y = \frac{T-a_7}{T+a_6} \text{ for } T > a_7 \text{ otherwise } 0
Parameters
Tfloat

Temperature [K]

a1-a7float

Coefficients

Returns
Cpfloat

Ideal gas heat capacity , [J/mol/K]

Notes

j is set to 8. Analytical integrals are available for this expression.

References

1

Kabo, G. J., and G. N. Roganov. Thermodynamics of Organic Compounds in the Gas State, Volume II: V. 2. College Station, Tex: CRC Press, 1994.

Examples

>>> TRCCp(300, 4.0, 7.65E5, 720., 3.565, -0.052, -1.55E6, 52., 201.)
42.065271080974654
chemicals.heat_capacity.TRCCp_integral(T, a0, a1, a2, a3, a4, a5, a6, a7, I=0)[source]

Integrates ideal gas heat capacity using the model developed in [1]. Best used as a delta only. The difference in enthalpy with respect to 0 K is given by:

H(T)HrefRT=a0+a1x(a2)/(a2T)+I/T+h(T)/T\frac{H(T) - H^{ref}}{RT} = a_0 + a_1x(a_2)/(a_2T) + I/T + h(T)/T
h(T)=(a5+a7)[(2a3+8a4)ln(1y)+{a3(1+11y)+a4(7+11y)}y+a4{3y2+(5/3)y3+y4+(3/5)y5+(1/3)y6}+(1/7){a4a5(a6+a7)2}y7]h(T) = (a_5 + a_7)\left[(2a_3 + 8a_4)\ln(1-y)+ \left\{a_3\left(1 + \frac{1}{1-y}\right) + a_4\left(7 + \frac{1}{1-y}\right)\right\}y + a_4\left\{3y^2 + (5/3)y^3 + y^4 + (3/5)y^5 + (1/3)y^6\right\} + (1/7)\left\{a_4 - \frac{a_5}{(a_6+a_7)^2}\right\}y^7\right]
h(T)=0 for Ta7y=Ta7T+a6 for T>a7 otherwise 0h(T) = 0 \text{ for } T \le a_7 y = \frac{T-a_7}{T+a_6} \text{ for } T > a_7 \text{ otherwise } 0
Parameters
Tfloat

Temperature [K]

a1-a7float

Coefficients

Ifloat, optional

Integral offset

Returns
H-H(0)float

Difference in enthalpy from 0 K , [J/mol]

Notes

Analytical integral as provided in [1] and verified with numerical integration.

References

1(1,2)

Kabo, G. J., and G. N. Roganov. Thermodynamics of Organic Compounds in the Gas State, Volume II: V. 2. College Station, Tex: CRC Press, 1994.

Examples

>>> TRCCp_integral(298.15, 4.0, 7.65E5, 720., 3.565, -0.052, -1.55E6, 52.,
... 201., 1.2)
10802.536262068483
chemicals.heat_capacity.TRCCp_integral_over_T(T, a0, a1, a2, a3, a4, a5, a6, a7, J=0)[source]

Integrates ideal gas heat capacity over T using the model developed in [1]. Best used as a delta only. The difference in ideal-gas entropy with respect to 0 K is given by:

SR=J+a0lnT+a1a22(1+a2T)x(a2)+s(T)s(T)=[{a3+(a4a72a5a62)(a7a6)4}(a7a6)2lnz+(a3+a4)ln(T+a6a6+a7)+i=17{(a4a72a5a62)(a7a6)6ia4}yii{a3a6(a6+a7)+a5y67a7(a6+a7)}y]\frac{S^\circ}{R} = J + a_0\ln T + \frac{a_1}{a_2^2}\left(1 + \frac{a_2}{T}\right)x(a_2) + s(T) s(T) = \left[\left\{a_3 + \left(\frac{a_4 a_7^2 - a_5}{a_6^2}\right) \left(\frac{a_7}{a_6}\right)^4\right\}\left(\frac{a_7}{a_6}\right)^2 \ln z + (a_3 + a_4)\ln\left(\frac{T+a_6}{a_6+a_7}\right) +\sum_{i=1}^7 \left\{\left(\frac{a_4 a_7^2 - a_5}{a_6^2}\right)\left( \frac{-a_7}{a_6}\right)^{6-i} - a_4\right\}\frac{y^i}{i} - \left\{\frac{a_3}{a_6}(a_6 + a_7) + \frac{a_5 y^6}{7a_7(a_6+a_7)} \right\}y\right]
s(T)=0 for Ta7s(T) = 0 \text{ for } T \le a_7
z=TT+a6a7+a6a7z = \frac{T}{T+a_6} \cdot \frac{a_7 + a_6}{a_7}
y=Ta7T+a6 for T>a7 otherwise 0y = \frac{T-a_7}{T+a_6} \text{ for } T > a_7 \text{ otherwise } 0
Parameters
Tfloat

Temperature [K]

a1-a7float

Coefficients

Jfloat, optional

Integral offset

Returns
S-S(0)float

Difference in entropy from 0 K , [J/mol/K]

Notes

Analytical integral as provided in [1] and verified with numerical integration.

References

1(1,2)

Kabo, G. J., and G. N. Roganov. Thermodynamics of Organic Compounds in the Gas State, Volume II: V. 2. College Station, Tex: CRC Press, 1994.

Examples

>>> TRCCp_integral_over_T(300, 4.0, 124000, 245, 50.539, -49.469,
... 220440000, 560, 78)
213.80156219151888
chemicals.heat_capacity.Shomate(T, A, B, C, D, E)[source]

Calculates heat capacity using the Shomate polynomial model [1]. The heat capacity is given by:

Cp=A+BT+CT2+DT3+ET2C_p = A + BT + CT^2 + DT^3 + \frac{E}{T^2}
Parameters
Tfloat

Temperature [K]

Afloat

Parameter, [J/(mol*K)]

Bfloat

Parameter, [J/(mol*K^2)]

Cfloat

Parameter, [J/(mol*K^3)]

Dfloat

Parameter, [J/(mol*K^4)]

Efloat

Parameter, [J*K/(mol)]

Returns
Cpfloat

Heat capacity , [J/mol/K]

Notes

Analytical integrals are available for this expression. In some sources such as [1], the equation is written with temperature in units of kilokelvin. The coefficients can be easily adjusted to be in the proper SI form.

References

1(1,2,3)

Shen, V.K., Siderius, D.W., Krekelberg, W.P., and Hatch, H.W., Eds., NIST WebBook, NIST, http://doi.org/10.18434/T4M88Q

Examples

Coefficients for water vapor from [1]:

>>> water_low_gas_coeffs = [30.09200, 6.832514/1e3, 6.793435/1e6, -2.534480/1e9, 0.082139*1e6]
>>> Shomate(500, *water_low_gas_coeffs)
35.21836175
chemicals.heat_capacity.Shomate_integral(T, A, B, C, D, E)[source]

Calculates the enthalpy integral using the Shomate polynomial model [1]. The difference in enthalpy with respect to 0 K is given by:

H(T)H0=AT+BT22+CT33+DT44ET{H(T) - H^{0}} = A T + \frac{B T^{2}}{2} + \frac{C T^{3}}{3} + \frac{D T^{4}}{4} - \frac{E}{T}
Parameters
Tfloat

Temperature [K]

Afloat

Parameter, [J/(mol*K)]

Bfloat

Parameter, [J/(mol*K^2)]

Cfloat

Parameter, [J/(mol*K^3)]

Dfloat

Parameter, [J/(mol*K^4)]

Efloat

Parameter, [J*K/(mol)]

Returns
H-H(0)float

Difference in enthalpy from 0 K , [J/mol]

References

1(1,2)

Shen, V.K., Siderius, D.W., Krekelberg, W.P., and Hatch, H.W., Eds., NIST WebBook, NIST, http://doi.org/10.18434/T4M88Q

Examples

Coefficients for water vapor from [1]:

>>> water_low_gas_coeffs = [30.09200, 6.832514/1e3, 6.793435/1e6, -2.534480/1e9, 0.082139*1e6]
>>> Shomate_integral(500, *water_low_gas_coeffs)
15979.2447
chemicals.heat_capacity.Shomate_integral_over_T(T, A, B, C, D, E)[source]

Integrates the heat capacity over T using the model developed in [1]. The difference in entropy with respect to 0 K is given by:

s(T)=Alog(T)+BT+CT22+DT33E2T2s(T) = A \log{\left(T \right)} + B T + \frac{C T^{2}}{2} + \frac{D T^{3}}{3} - \frac{E}{2 T^{2}}
Parameters
Tfloat

Temperature [K]

Afloat

Parameter, [J/(mol*K)]

Bfloat

Parameter, [J/(mol*K^2)]

Cfloat

Parameter, [J/(mol*K^3)]

Dfloat

Parameter, [J/(mol*K^4)]

Efloat

Parameter, [J*K/(mol)]

Returns
S-S(0)float

Difference in entropy from 0 K , [J/mol/K]

References

1(1,2)

Shen, V.K., Siderius, D.W., Krekelberg, W.P., and Hatch, H.W., Eds., NIST WebBook, NIST, http://doi.org/10.18434/T4M88Q

Examples

Coefficients for water vapor from [1]:

>>> water_low_gas_coeffs = [30.09200, 6.832514/1e3, 6.793435/1e6, -2.534480/1e9, 0.082139*1e6]
>>> Shomate_integral_over_T(500, *water_low_gas_coeffs)
191.00554
class chemicals.heat_capacity.ShomateRange(coeffs, Tmin, Tmax)[source]

Implementation of a range of the Shomate equation presented in [1] for calculating the heat capacity of a chemical. Implements the enthalpy and entropy integrals as well.

Parameters
coeffslist[float]

Six coefficients for the equation, [-]

Tminfloat

Minimum temperature any experimental data was available at, [K]

Tmaxfloat

Maximum temperature any experimental data was available at, [K]

References

1

Shen, V.K., Siderius, D.W., Krekelberg, W.P., and Hatch, H.W., Eds., NIST WebBook, NIST, http://doi.org/10.18434/T4M88Q

Methods

calculate(T)

Return heat capacity as a function of temperature.

calculate_integral(Ta, Tb)

Return the enthalpy integral of heat capacity from Ta to Tb.

calculate_integral_over_T(Ta, Tb)

Return the entropy integral of heat capacity from Ta to Tb.

calculate(T)[source]

Return heat capacity as a function of temperature.

Parameters
Tfloat

Temperature, [K]

Returns
Cpfloat

Liquid heat capacity as T, [J/mol/K]

calculate_integral(Ta, Tb)[source]

Return the enthalpy integral of heat capacity from Ta to Tb.

Parameters
Tafloat

Initial temperature, [K]

Tbfloat

Final temperature, [K]

Returns
dHfloat

Enthalpy difference between Ta and Tb, [J/mol]

calculate_integral_over_T(Ta, Tb)[source]

Return the entropy integral of heat capacity from Ta to Tb.

Parameters
Tafloat

Initial temperature, [K]

Tbfloat

Final temperature, [K]

Returns
dSfloat

Entropy difference between Ta and Tb, [J/mol/K]

chemicals.heat_capacity.Poling(T, a, b, c, d, e)[source]

Return the ideal-gas molar heat capacity of a chemical using polynomial regressed coefficients as described by Poling et. al. [1].

Parameters
Tfloat

Temperature, [K]

a,b,c,d,efloat

Regressed coefficients.

Returns
Cpgmfloat

Gas molar heat capacity, [J/mol/K]

Notes

The ideal gas heat capacity is given by:

Cn=R(a+bT+cT2+dT3+eT4)C_n = R*(a + bT + cT^2 + dT^3 + eT^4)

The data is based on the Poling data bank.

References

1

Poling, Bruce E. The Properties of Gases and Liquids. 5th edition. New York: McGraw-Hill Professional, 2000.

Examples

Compute the gas heat capacity of Methane at 300 K:

>>> Poling(T=300., a=4.568, b=-0.008975, c=3.631e-05, d=-3.407e-08, e=1.091e-11)
35.850973388425
chemicals.heat_capacity.Poling_integral(T, a, b, c, d, e)[source]

Return the integral of the ideal-gas constant-pressure heat capacity of a chemical using polynomial regressed coefficients as described by Poling et. al. [1].

Parameters
Tfloat

Temperature, [K]

a,b,c,d,efloat

Regressed coefficients.

Returns
Hfloat

Difference in enthalpy from 0 K, [J/mol]

Notes

Integral was computed with SymPy.

References

1

Poling, Bruce E. The Properties of Gases and Liquids. 5th edition. New York: McGraw-Hill Professional, 2000.

Examples

Compute the gas enthalpy of Methane at 300 K (with reference to 0 K):

>>> Poling_integral(T=300., a=4.568, b=-0.008975, c=3.631e-05, d=-3.407e-08, e=1.091e-11)
10223.67533722261
chemicals.heat_capacity.Poling_integral_over_T(T, a, b, c, d, e)[source]

Return the integral over temperature of the ideal-gas constant-pressure heat capacity of a chemical using polynomial regressed coefficients as described by Poling et. al. [1].

Parameters
Tfloat

Temperature, [K]

a,b,c,d,efloat

Regressed coefficients.

Returns
Sfloat

Difference in entropy from 0 K, [J/mol/K]

Notes

Integral was computed with SymPy.

References

1

Poling, Bruce E. The Properties of Gases and Liquids. 5th edition. New York: McGraw-Hill Professional, 2000.

Examples

Compute the gas entropy of Methane at 300 K (with reference to 0 K):

>>> Poling_integral_over_T(T=300., a=4.568, b=-0.008975, c=3.631e-05, d=-3.407e-08, e=1.091e-11)
205.46526328058
chemicals.heat_capacity.PPDS2(T, Ts, C_low, C_inf, a1, a2, a3, a4, a5)[source]

Calculates the ideal-gas heat capacity using the [1] emperical (parameter-regressed) method, called the PPDS 2 equation for heat capacity.

\frac{C_p^0}{R} = C_{low} + (C_\inf - C_{low})y^2\left(1 + (y-1) \left[\sum_{i=0}^4 a_i y^i\right]\right)
y=TT+Tsy = \frac{T}{T + T_s}
Parameters
Tfloat

Temperature of fluid [K]

Tsfloat

Fit temperature; no physical meaning [K]

C_lowfloat

Fit parameter equal to Cp/R at a low temperature, [-]

C_inffloat

Fit parameter equal to Cp/R at a high temperature, [-]

a1float

Regression parameter, [-]

a2float

Regression parameter, [-]

a3float

Regression parameter, [-]

a4float

Regression parameter, [-]

a5float

Regression parameter, [-]

Returns
Cpgmfloat

Gas molar heat capacity, [J/mol/K]

References

1(1,2)

“ThermoData Engine (TDE103b V10.1) User`s Guide.” https://trc.nist.gov/TDE/TDE_Help/Eqns-Pure-Cp0/PPDS2Cp0.htm.

Examples

n-pentane at 350 K from [1]

>>> PPDS2(T=350.0, Ts=462.493, C_low=4.54115, C_inf=9.96847, a1=-103.419, a2=695.484, a3=-2006.1, a4=2476.84, a5=-1186.47)
136.46338956689

Gas Heat Capacity Estimation Models

chemicals.heat_capacity.Lastovka_Shaw(T, similarity_variable, cyclic_aliphatic=False, MW=None, term_A=None)[source]

Calculate ideal-gas constant-pressure heat capacity with the similarity variable concept and method as shown in [1].

termA=A1+A2a if cyclic aliphaticterm_A = A1 + A2*a \text{ if cyclic aliphatic}
termA=(A2+A1A21+exp(αA3A4)) if not cyclic aliphaticterm_A = \left(A_2 + \frac{A_1 - A_2}{1 + \exp(\frac{\alpha-A_3}{A_4})}\right) \text{ if not cyclic aliphatic}
Cp0=termA+(B11+B12α)((C11+C12α)T)2exp((C11+C12α)/T)[1exp((C11+C12α)/T)]2+(B21+B22α)((C21+C22α)T)2exp((C21+C22α)/T)[1exp((C21+C22α)/T)]2C_p^0 = term_A + (B_{11} + B_{12}\alpha)\left(-\frac{(C_{11} + C_{12}\alpha)}{T}\right)^2 \frac{\exp(-(C_{11} + C_{12}\alpha)/T)}{[1-\exp(-(C_{11}+C_{12}\alpha)/T)]^2} + (B_{21} + B_{22}\alpha)\left(-\frac{(C_{21} + C_{22}\alpha)}{T}\right)^2 \frac{\exp(-(C_{21} + C_{22}\alpha)/T)}{[1-\exp(-(C_{21}+C_{22}\alpha)/T)]^2}
Parameters
Tfloat

Temperature of gas [K]

similarity_variablefloat

Similarity variable as defined in [1], [mol/g]

cyclic_aliphatic: bool, optional

Whether or not chemical is cyclic aliphatic, [-]

MWfloat, optional

Molecular weight, [g/mol]

term_Afloat, optional

Term A in Lastovka-Shaw equation, [J/g]

Returns
Cpgfloat

Gas constant-pressure heat capacity, J/mol/K if MW given; J/kg/K otherwise

Notes

Original model is in terms of J/g/K.

A1 = -0.1793547 text{ if cyclic aliphatic}

A1 = 0.58 text{ if not cyclic aliphatic}

A2 = 3.86944439 text{ if cyclic aliphatic}

A2 = 1.25 text{ if not cyclic aliphatic}

A3 = 0.17338003

A4 = 0.014

B11 = 0.73917383

B12 = 8.88308889

C11 = 1188.28051

C12 = 1813.04613

B21 = 0.0483019

B22 = 4.35656721

C21 = 2897.01927

C22 = 5987.80407

References

1(1,2)

Lastovka, Vaclav, and John M. Shaw. “Predictive Correlations for Ideal Gas Heat Capacities of Pure Hydrocarbons and Petroleum Fractions.” Fluid Phase Equilibria 356 (October 25, 2013): 338-370. doi:10.1016/j.fluid.2013.07.023.

Examples

Estimate the heat capacity of n-decane gas in J/kg/K:

>>> Lastovka_Shaw(1000.0, 0.22491)
3730.2807601773725

Estimate the heat capacity of n-decane gas in J/mol/K:

>>> Lastovka_Shaw(1000.0, 0.22491, MW=142.28)
530.7443465580366
chemicals.heat_capacity.Lastovka_Shaw_integral(T, similarity_variable, cyclic_aliphatic=False, MW=None, term_A=None)[source]

Calculate the integral of ideal-gas constant-pressure heat capacity with the similarity variable concept and method as shown in [1].

Parameters
Tfloat

Temperature of gas [K]

cyclic_aliphatic: bool, optional

Whether or not chemical is cyclic aliphatic, [-]

MWfloat, optional

Molecular weight, [g/mol]

term_Afloat, optional

Term A in Lastovka-Shaw equation, [J/g]

Returns
Hfloat

Difference in enthalpy from 0 K, J/mol if MW given; J/kg otherwise

Notes

Original model is in terms of J/g/K. Integral was computed with SymPy.

References

1

Lastovka, Vaclav, and John M. Shaw. “Predictive Correlations for Ideal Gas Heat Capacities of Pure Hydrocarbons and Petroleum Fractions.” Fluid Phase Equilibria 356 (October 25, 2013): 338-370. doi:10.1016/j.fluid.2013.07.023.

Examples

>>> Lastovka_Shaw_integral(300.0, 0.1333)
5283095.816018478
chemicals.heat_capacity.Lastovka_Shaw_integral_over_T(T, similarity_variable, cyclic_aliphatic=False, MW=None, term_A=None)[source]

Calculate the integral over temperature of ideal-gas constant-pressure heat capacity with the similarity variable concept and method as shown in [1].

Parameters
Tfloat

Temperature of gas [K]

similarity_variablefloat

Similarity variable as defined in [1], [mol/g]

cyclic_aliphatic: bool, optional

Whether or not chemical is cyclic aliphatic, [-]

MWfloat, optional

Molecular weight, [g/mol]

term_Afloat, optional

Term A in Lastovka-Shaw equation, [J/g]

Returns
Sfloat

Difference in entropy from 0 K, [J/mol/K if MW given; J/kg/K otherwise]

Notes

Original model is in terms of J/g/K. Note that the model is for predicting mass heat capacity, not molar heat capacity like most other methods! Integral was computed with SymPy.

References

1(1,2)

Lastovka, Vaclav, and John M. Shaw. “Predictive Correlations for Ideal Gas Heat Capacities of Pure Hydrocarbons and Petroleum Fractions.” Fluid Phase Equilibria 356 (October 25, 2013): 338-370. doi:10.1016/j.fluid.2013.07.023.

Examples

>>> Lastovka_Shaw_integral_over_T(300.0, 0.1333)
3609.791928945323
chemicals.heat_capacity.Lastovka_Shaw_T_for_Hm(Hm, MW, similarity_variable, T_ref=298.15, factor=1.0, cyclic_aliphatic=None, term_A=None)[source]

Uses the Lastovka-Shaw ideal-gas heat capacity correlation to solve for the temperature which has a specified Hm, as is required in PH flashes, as shown in [1].

Parameters
Hmfloat

Molar enthalpy spec, [J/mol]

MWfloat

Molecular weight of the pure compound or mixture average, [g/mol]

similarity_variablefloat

Similarity variable as defined in [1], [mol/g]

T_reffloat, optional

Reference enthlapy temperature, [K]

factorfloat, optional

A factor to increase or decrease the predicted value of the method, [-]

cyclic_aliphatic: bool, optional

Whether or not chemical is cyclic aliphatic, [-]

term_Afloat, optional

Term A in Lastovka-Shaw equation, [J/g]

Returns
Tfloat

Temperature of gas to meet the molar enthalpy spec, [K]

References

1(1,2)

Lastovka, Vaclav, and John M. Shaw. “Predictive Correlations for Ideal Gas Heat Capacities of Pure Hydrocarbons and Petroleum Fractions.” Fluid Phase Equilibria 356 (October 25, 2013): 338-370. doi:10.1016/j.fluid.2013.07.023.

Examples

>>> Lastovka_Shaw_T_for_Hm(Hm=55000, MW=80.0, similarity_variable=0.23)
600.0943429567602
chemicals.heat_capacity.Lastovka_Shaw_T_for_Sm(Sm, MW, similarity_variable, T_ref=298.15, factor=1.0, cyclic_aliphatic=None, term_A=None)[source]

Uses the Lastovka-Shaw ideal-gas heat capacity correlation to solve for the temperature which has a specified Sm, as is required in PS flashes, as shown in [1].

Parameters
Smfloat

Molar entropy spec, [J/mol/K]

MWfloat

Molecular weight of the pure compound or mixture average, [g/mol]

similarity_variablefloat

Similarity variable as defined in [1], [mol/g]

T_reffloat, optional

Reference enthlapy temperature, [K]

factorfloat, optional

A factor to increase or decrease the predicted value of the method, [-]

cyclic_aliphatic: bool, optional

Whether or not chemical is cyclic aliphatic, [-]

term_Afloat, optional

Term A in Lastovka-Shaw equation, [J/g]

Returns
Tfloat

Temperature of gas to meet the molar entropy spec, [K]

References

1(1,2)

Lastovka, Vaclav, and John M. Shaw. “Predictive Correlations for Ideal Gas Heat Capacities of Pure Hydrocarbons and Petroleum Fractions.” Fluid Phase Equilibria 356 (October 25, 2013): 338-370. doi:10.1016/j.fluid.2013.07.023.

Examples

>>> Lastovka_Shaw_T_for_Sm(Sm=112.80, MW=72.151, similarity_variable=0.2356)
603.4298291570276
chemicals.heat_capacity.Lastovka_Shaw_term_A(similarity_variable, cyclic_aliphatic)[source]

Return Term A in Lastovka-Shaw equation.

Parameters
similarity_variablefloat

Similarity variable as defined in [1], [mol/g]

cyclic_aliphatic: bool, optional

Whether or not chemical is cyclic aliphatic, [-]

Returns
term_Afloat

Term A in Lastovka-Shaw equation, [J/g]

References

1

Lastovka, Vaclav, and John M. Shaw. “Predictive Correlations for Ideal Gas Heat Capacities of Pure Hydrocarbons and Petroleum Fractions.” Fluid Phase Equilibria 356 (October 25, 2013): 338-370. doi:10.1016/j.fluid.2013.07.023.

Gas Heat Capacity Theory

chemicals.heat_capacity.Cpg_statistical_mechanics(T, thetas, linear=False)[source]

Calculates the ideal-gas heat capacity using of a molecule using its characteristic temperatures, themselves calculated from each of the frequencies of vibration of the molecule. These can be obtained from spectra or quantum mechanical calculations.

Cp0R=Cp0Rrotational+Cp0Rtranslational+Cp0Rvibrational\frac{C_p^{0}}{R} = \frac{C_p^{0}}{R} \text{rotational} + \frac{C_p^{0}}{R} \text{translational} + \frac{C_p^{0}}{R} \text{vibrational}
Cp0Rrotational=2.5\frac{C_p^{0}}{R} \text{rotational} = 2.5
Cp0Rtranslational=1 if linear else 1.5\frac{C_p^{0}}{R} \text{translational} = 1 \text{ if linear else } 1.5
Cp0Rvibrational=i=13nA6+δ(θiT)2[exp(θi/T)(exp(θi/T)1)2]\frac{C_p^{0}}{R} \text{vibrational} = \sum_{i=1}^{3n_A-6+\delta} \left(\frac{\theta_i}{T}\right)^2 \left[\frac{\exp(\theta_i/T)} {\left(\exp(\theta_i/T)-1\right)^2}\right]

In the above equation, deltadelta is 1 if the molecule is linear otherwise 0.

Parameters
Tfloat

Temperature of fluid [K]

thetaslist[float]

Characteristic temperatures, [K]

Returns
Cpgmfloat

Gas molar heat capacity at specified temperature, [J/mol/K]

Notes

This equation implies that there is a maximum heat capacity for an ideal gas, and all diatomic or larger gases

Monoatomic gases have a simple heat capacity of 2.5R, the lower limit for ideal gas heat capacity. This function does not cover that type of a gas. The specific gases that are monoatomic are helium, neon, argon, krypton, xenon, radon.

At very low temperatures hydrogen behaves like a monoatomic gas as well.

References

1

Green, Don, and Robert Perry. Perry’s Chemical Engineers’ Handbook, Eighth Edition. McGraw-Hill Professional, 2007.

Examples

Sample calculation in [1] for ammonia:

>>> thetas = [1360, 2330, 2330, 4800, 4880, 4880]
>>> Cpg_statistical_mechanics(300.0, thetas)
35.55983440173097
chemicals.heat_capacity.Cpg_statistical_mechanics_integral(T, thetas, linear=False)[source]

Calculates the integral of ideal-gas heat capacity using of a molecule using its characteristic temperatures.

Cp0=2.5RT+RT if linear else 1.5RT+Cp0vibrational\int {C_p^{0}} = 2.5RT + RT \text{ if linear else } 1.5RT + \int C_p^{0}\text{vibrational}
Cp0vibrational=Ri=13nA6+δθiexp(θi/T)1\int {C_p^{0}} \text{vibrational} = R\sum_{i=1}^{3n_A-6+\delta} \frac{\theta_i}{\exp(\theta_i/T)-1}
Parameters
Tfloat

Temperature of fluid [K]

thetaslist[float]

Characteristic temperatures, [K]

Returns
Hfloat

Integrated gas molar heat capacity at specified temperature, [J/mol]

Examples

>>> thetas = [1360, 2330, 2330, 4800, 4880, 4880]
>>> Cpg_statistical_mechanics_integral(300.0, thetas)
10116.6053294
chemicals.heat_capacity.Cpg_statistical_mechanics_integral_over_T(T, thetas, linear=False)[source]
Calculates the integral over T of ideal-gas heat capacity using of a

molecule using its characteristic temperatures.

Cp0T=2.5Rlog(T)+1Rlog(T) if linear else 1.5Rlog(T)+Cp0Tvibrational\int \frac{C_p^{0}}{T} = 2.5R\log(T) + 1R\log(T) \text{ if linear else } 1.5R\log(T) + \int \frac{C_p^{0}}{T}\text{vibrational}
Cp0Tvibrational=i=13nA6+δθiTexp(θi/T)Tlog(exp(θi/T)1)+θi/T\int \frac{C_p^{0}}{T} \text{vibrational} = \sum_{i=1}^{3n_A-6+\delta} \frac{\theta_i}{T\exp(\theta_i/T)-T} - \log(\exp(\theta_i/T)-1) + \theta_i/T
Parameters
Tfloat

Temperature of fluid [K]

thetaslist[float]

Characteristic temperatures, [K]

Returns
Sfloat

Entropy integral of gas molar heat capacity at specified temperature, [J/mol/K]

Examples

>>> thetas = [1360, 2330, 2330, 4800, 4880, 4880]
>>> Cpg_statistical_mechanics_integral_over_T(300.0, thetas)
190.25658088
chemicals.heat_capacity.vibration_frequency_cm_to_characteristic_temperature(frequency, scale=1)[source]

Convert a vibrational frequency in units of 1/cm to a characteristic temperature for use in calculating heat capacity.

θ=100hcscalek\theta = \frac{100\cdot h\cdot c\cdot \text{scale}}{k}
Parameters
frequencyfloat

Vibrational frequency, [1/cm]

scalefloat

A scale factor used to adjust the frequency for differences in experimental vs. calculated values, [-]

Returns
thetafloat

Characteristic temperature [K]

Notes

In the equation, k is Boltzmann’s constant, c is the speed of light, and h is the Planck constant.

A scale factor for the MP2/6-31G** method recommended by NIST is 0.9365. Using this scale factor will not improve results in all cases however.

Examples

>>> vibration_frequency_cm_to_characteristic_temperature(667)
959.6641613636505

Liquid Heat Capacity Model Equations

chemicals.heat_capacity.Zabransky_quasi_polynomial(T, Tc, a1, a2, a3, a4, a5, a6)[source]

Calculates liquid heat capacity using the model developed in [1].

CR=A1ln(1Tr)+A21Tr+j=0mAj+3Trj\frac{C}{R}=A_1\ln(1-T_r) + \frac{A_2}{1-T_r} + \sum_{j=0}^m A_{j+3} T_r^j
Parameters
Tfloat

Temperature [K]

Tcfloat

Critical temperature of fluid, [K]

a1-a6float

Coefficients

Returns
Cpfloat

Liquid heat capacity, [J/mol/K]

Notes

Used only for isobaric heat capacities, not saturation heat capacities. Designed for reasonable extrapolation behavior caused by using the reduced critical temperature. Used by the authors of [1] when critical temperature was available for the fluid. Analytical integrals are available for this expression.

References

1(1,2)

Zabransky, M., V. Ruzicka Jr, V. Majer, and Eugene S. Domalski. Heat Capacity of Liquids: Critical Review and Recommended Values. 2 Volume Set. Washington, D.C.: Amer Inst of Physics, 1996.

Examples

>>> Zabransky_quasi_polynomial(330, 591.79, -3.12743, 0.0857315, 13.7282, 1.28971, 6.42297, 4.10989)
165.472878778683
chemicals.heat_capacity.Zabransky_quasi_polynomial_integral(T, Tc, a1, a2, a3, a4, a5, a6)[source]

Calculates the integral of liquid heat capacity using the quasi-polynomial model developed in [1].

Parameters
Tfloat

Temperature [K]

a1-a6float

Coefficients

Returns
Hfloat

Difference in enthalpy from 0 K, [J/mol]

Notes

The analytical integral was derived with SymPy; it is a simple polynomial plus some logarithms.

References

1

Zabransky, M., V. Ruzicka Jr, V. Majer, and Eugene S. Domalski. Heat Capacity of Liquids: Critical Review and Recommended Values. 2 Volume Set. Washington, D.C.: Amer Inst of Physics, 1996.

Examples

>>> H2 = Zabransky_quasi_polynomial_integral(300, 591.79, -3.12743,
... 0.0857315, 13.7282, 1.28971, 6.42297, 4.10989)
>>> H1 = Zabransky_quasi_polynomial_integral(200, 591.79, -3.12743,
... 0.0857315, 13.7282, 1.28971, 6.42297, 4.10989)
>>> H2 - H1
14662.031376528757
chemicals.heat_capacity.Zabransky_quasi_polynomial_integral_over_T(T, Tc, a1, a2, a3, a4, a5, a6)[source]

Calculates the integral of liquid heat capacity over T using the quasi-polynomial model developed in [1].

Parameters
Tfloat

Temperature [K]

a1-a6float

Coefficients

Returns
Sfloat

Difference in entropy from 0 K, [J/mol/K]

Notes

The analytical integral was derived with Sympy. It requires the Polylog(2,x) function, which is unimplemented in SciPy. A very accurate numerical approximation was implemented as fluids.numerics.polylog2. Relatively slow due to the use of that special function.

References

1

Zabransky, M., V. Ruzicka Jr, V. Majer, and Eugene S. Domalski. Heat Capacity of Liquids: Critical Review and Recommended Values. 2 Volume Set. Washington, D.C.: Amer Inst of Physics, 1996.

Examples

>>> S2 = Zabransky_quasi_polynomial_integral_over_T(300, 591.79, -3.12743,
... 0.0857315, 13.7282, 1.28971, 6.42297, 4.10989)
>>> S1 = Zabransky_quasi_polynomial_integral_over_T(200, 591.79, -3.12743,
... 0.0857315, 13.7282, 1.28971, 6.42297, 4.10989)
>>> S2 - S1
59.16999297436473
chemicals.heat_capacity.Zabransky_cubic(T, a1, a2, a3, a4)[source]

Calculates liquid heat capacity using the model developed in [1].

CR=j=03Aj+1(T100K)j\frac{C}{R}=\sum_{j=0}^3 A_{j+1} \left(\frac{T}{100 \text{K}}\right)^j
Parameters
Tfloat

Temperature [K]

a1float

Coefficient, [-]

a2float

Coefficient, [-]

a3float

Coefficient, [-]

a4float

Coefficient, [-]

Returns
Cpfloat

Liquid heat capacity, [J/mol/K]

Notes

Most often form used in [1]. Analytical integrals are available for this expression.

References

1(1,2)

Zabransky, M., V. Ruzicka Jr, V. Majer, and Eugene S. Domalski. Heat Capacity of Liquids: Critical Review and Recommended Values. 2 Volume Set. Washington, D.C.: Amer Inst of Physics, 1996.

Examples

>>> Zabransky_cubic(298.15, 20.9634, -10.1344, 2.8253, -0.256738)
75.31465144297
chemicals.heat_capacity.Zabransky_cubic_integral(T, a1, a2, a3, a4)[source]

Calculates the integral of liquid heat capacity using the model developed in [1].

Parameters
Tfloat

Temperature [K]

a1float

Coefficient, [-]

a2float

Coefficient, [-]

a3float

Coefficient, [-]

a4float

Coefficient, [-]

Returns
Hfloat

Difference in enthalpy from 0 K, [J/mol]

Notes

The analytical integral was derived with Sympy; it is a simple polynomial.

References

1

Zabransky, M., V. Ruzicka Jr, V. Majer, and Eugene S. Domalski. Heat Capacity of Liquids: Critical Review and Recommended Values. 2 Volume Set. Washington, D.C.: Amer Inst of Physics, 1996.

Examples

>>> Zabransky_cubic_integral(298.15, 20.9634, -10.1344, 2.8253, -0.256738)
31051.690370364
chemicals.heat_capacity.Zabransky_cubic_integral_over_T(T, a1, a2, a3, a4)[source]

Calculates the integral of liquid heat capacity over T using the model developed in [1].

Parameters
Tfloat

Temperature [K]

a1float

Coefficient, [-]

a2float

Coefficient, [-]

a3float

Coefficient, [-]

a4float

Coefficient, [-]

Returns
Sfloat

Difference in entropy from 0 K, [J/mol/K]

Notes

The analytical integral was derived with Sympy; it is a simple polynomial, plus a logarithm

References

1

Zabransky, M., V. Ruzicka Jr, V. Majer, and Eugene S. Domalski. Heat Capacity of Liquids: Critical Review and Recommended Values. 2 Volume Set. Washington, D.C.: Amer Inst of Physics, 1996.

Examples

>>> Zabransky_cubic_integral_over_T(298.15, 20.9634, -10.1344, 2.8253,
... -0.256738)
24.732465342840
class chemicals.heat_capacity.ZabranskySpline(coeffs, Tmin, Tmax)[source]

Implementation of the cubic spline method presented in [1] for calculating the heat capacity of a chemical. Implements the enthalpy and entropy integrals as well.

CR=j=03Aj+1(T100)j\frac{C}{R}=\sum_{j=0}^3 A_{j+1} \left(\frac{T}{100}\right)^j
Parameters
coeffslist[float]

Six coefficients for the equation, [-]

Tminfloat

Minimum temperature any experimental data was available at, [K]

Tmaxfloat

Maximum temperature any experimental data was available at, [K]

References

1

Zabransky, M., V. Ruzicka Jr, V. Majer, and Eugene S. Domalski. Heat Capacity of Liquids: Critical Review and Recommended Values. 2 Volume Set. Washington, D.C.: Amer Inst of Physics, 1996.

Methods

calculate(T)

Return heat capacity as a function of temperature.

calculate_integral(Ta, Tb)

Return the enthalpy integral of heat capacity from Ta to Tb.

calculate_integral_over_T(Ta, Tb)

Return the entropy integral of heat capacity from Ta to Tb.

calculate(T)[source]

Return heat capacity as a function of temperature.

Parameters
Tfloat

Temperature, [K]

Returns
Cpfloat

Liquid heat capacity as T, [J/mol/K]

calculate_integral(Ta, Tb)[source]

Return the enthalpy integral of heat capacity from Ta to Tb.

Parameters
Tafloat

Initial temperature, [K]

Tbfloat

Final temperature, [K]

Returns
dHfloat

Enthalpy difference between Ta and Tb, [J/mol]

calculate_integral_over_T(Ta, Tb)[source]

Return the entropy integral of heat capacity from Ta to Tb.

Parameters
Tafloat

Initial temperature, [K]

Tbfloat

Final temperature, [K]

Returns
dSfloat

Entropy difference between Ta and Tb, [J/mol/K]

class chemicals.heat_capacity.ZabranskyQuasipolynomial(coeffs, Tc, Tmin, Tmax)[source]

Quasi-polynomial object for calculating the heat capacity of a chemical. Implements the enthalpy and entropy integrals as well.

CR=A1ln(1Tr)+A21Tr+j=0mAj+3Trj\frac{C}{R}=A_1\ln(1-T_r) + \frac{A_2}{1-T_r} + \sum_{j=0}^m A_{j+3} T_r^j
Parameters
coeffslist[float]

Six coefficients for the equation, [-]

Tcfloat

Critical temperature of the chemical, as used in the formula, [K]

Tminfloat

Minimum temperature any experimental data was available at, [K]

Tmaxfloat

Maximum temperature any experimental data was available at, [K]

References

1

Zabransky, M., V. Ruzicka Jr, V. Majer, and Eugene S. Domalski. Heat Capacity of Liquids: Critical Review and Recommended Values. 2 Volume Set. Washington, D.C.: Amer Inst of Physics, 1996.

Methods

calculate(T)

Return the heat capacity as a function of temperature.

calculate_integral(Ta, Tb)

Return the enthalpy integral of heat capacity from Ta to Tb.

calculate_integral_over_T(Ta, Tb)

Return the entropy integral of heat capacity from Ta to Tb.

calculate(T)[source]

Return the heat capacity as a function of temperature.

Parameters
Tfloat

Temperature, [K]

Returns
Cpfloat

Liquid heat capacity as T, [J/mol/K]

calculate_integral(Ta, Tb)[source]

Return the enthalpy integral of heat capacity from Ta to Tb.

Parameters
Tafloat

Initial temperature, [K]

Tbfloat

Final temperature, [K]

Returns
dHfloat

Enthalpy difference between Ta and Tb, [J/mol]

calculate_integral_over_T(Ta, Tb)[source]

Return the entropy integral of heat capacity from Ta to Tb.

Parameters
Tafloat

Initial temperature, [K]

Tbfloat

Final temperature, [K]

Returns
dSfloat

Entropy difference between Ta and Tb, [J/mol/K]

chemicals.heat_capacity.PPDS15(T, Tc, a0, a1, a2, a3, a4, a5)[source]

Calculates the saturation liquid heat capacity using the [1] emperical (parameter-regressed) method, called the PPDS 15 equation for heat capacity.

Cp,lR=a0τ+a1+a2τ+a3τ2+a4τ3+a5τ4\frac{C_{p,l}}{R} = \frac{a_0}{\tau} + a_1 + a_2\tau + a_3\tau^2 + a_4\tau^3 + a_5\tau^4
Parameters
Tfloat

Temperature of fluid [K]

Tcfloat

Critical temperature of fluid [K]

a0float

Regression parameter, [-]

a1float

Regression parameter, [-]

a2float

Regression parameter, [-]

a3float

Regression parameter, [-]

a4float

Regression parameter, [-]

a5float

Regression parameter, [-]

Returns
Cplmfloat

Liquid molar saturation heat capacity, [J/mol/K]

References

1(1,2)

“ThermoData Engine (TDE103b V10.1) User`s Guide.” https://trc.nist.gov/TDE/Help/TDE103b/Eqns-Pure-CsatL/PPDS15-Csat.htm.

Examples

Benzene at 400 K from [1]

>>> PPDS15(T=400.0, Tc=562.05, a0=0.198892, a1=24.1389, a2=-20.2301, a3=5.72481, a4=4.43613e-7, a5=-3.10751e-7)
161.8983143509
chemicals.heat_capacity.TDE_CSExpansion(T, Tc, b, a1, a2=0.0, a3=0.0, a4=0.0)[source]

Calculates the saturation liquid heat capacity using the [1] CSExpansion method from NIST’s TDE:

Cp,l=bτ+a1+a2T+a3T2+a4T3C_{p,l}= \frac{b}{\tau} + a_1 + a_2T + a_3 T^2 + a_4 T^3
Parameters
Tfloat

Temperature of fluid [K]

Tcfloat

Critical temperature of fluid [K]

bfloat

Regression parameter, [-]

a1float

Regression parameter, [-]

a2float

Regression parameter, [-]

a3float

Regression parameter, [-]

a4float

Regression parameter, [-]

Returns
Cplmfloat

Liquid molar saturation heat capacity, [J/mol/K]

References

1(1,2)

“ThermoData Engine (TDE103b V10.1) User`s Guide.” https://trc.nist.gov/TDE/Help/TDE103b/Eqns-Pure-CsatL/CSExpansion.htm

Examples

2-methylquinoline at 550 K from [1]

>>> TDE_CSExpansion(550.0, 778.0, 0.626549, 120.705, 0.255987, 0.000381027, -3.03077e-7)
328.472042686

Liquid Heat Capacity Estimation Models

chemicals.heat_capacity.Rowlinson_Poling(T, Tc, omega, Cpgm)[source]

Calculate liquid constant-pressure heat capacity with the [1] CSP method. This equation is not terrible accurate.

The heat capacity of a liquid is given by:

CpLCpgR=1.586+0.491Tr+ω[4.2775+6.3(1Tr)1/3Tr+0.43551Tr]\frac{Cp^{L} - Cp^{g}}{R} = 1.586 + \frac{0.49}{1-T_r} + \omega\left[ 4.2775 + \frac{6.3(1-T_r)^{1/3}}{T_r} + \frac{0.4355}{1-T_r}\right]
Parameters
Tfloat

Temperature of fluid [K]

Tcfloat

Critical temperature of fluid [K]

omegafloat

Acentric factor for fluid, [-]

Cpgmfloat

Constant-pressure gas heat capacity, [J/mol/K]

Returns
Cplmfloat

Liquid constant-pressure heat capacity, [J/mol/K]

Notes

Poling compared 212 substances, and found error at 298K larger than 10% for 18 of them, mostly associating. Of the other 194 compounds, AARD is 2.5%.

References

1

Poling, Bruce E. The Properties of Gases and Liquids. 5th edition. New York: McGraw-Hill Professional, 2000.

Examples

>>> Rowlinson_Poling(350.0, 435.5, 0.203, 91.21)
143.80196224081436
chemicals.heat_capacity.Rowlinson_Bondi(T, Tc, omega, Cpgm)[source]

Calculate liquid constant-pressure heat capacity with the CSP method shown in [1].

The heat capacity of a liquid is given by:

CpLCpigR=1.45+0.45(1Tr)1+0.25ω[17.11+25.2(1Tr)1/3Tr1+1.742(1Tr)1]\frac{Cp^L - Cp^{ig}}{R} = 1.45 + 0.45(1-T_r)^{-1} + 0.25\omega [17.11 + 25.2(1-T_r)^{1/3}T_r^{-1} + 1.742(1-T_r)^{-1}]
Parameters
Tfloat

Temperature of fluid [K]

Tcfloat

Critical temperature of fluid [K]

omegafloat

Acentric factor for fluid, [-]

Cpgmfloat

Constant-pressure gas heat capacity, [J/mol/K]

Returns
Cplmfloat

Liquid constant-pressure heat capacity, [J/mol/K]

Notes

Less accurate than Rowlinson_Poling.

References

1

Poling, Bruce E. The Properties of Gases and Liquids. 5th edition. New York: McGraw-Hill Professional, 2000.

2

Gesellschaft, V. D. I., ed. VDI Heat Atlas. 2nd edition. Berlin; New York:: Springer, 2010.

3

J.S. Rowlinson, Liquids and Liquid Mixtures, 2nd Ed., Butterworth, London (1969).

Examples

>>> Rowlinson_Bondi(T=373.28, Tc=535.55, omega=0.323, Cpgm=119.342)
175.3976263003074
chemicals.heat_capacity.Dadgostar_Shaw(T, similarity_variable, MW=None, terms=None)[source]

Calculate liquid constant-pressure heat capacity with the similarity variable concept and method as shown in [1].

Cp=24.5(a11α+a12α2)+(a21α+a22α2)T+(a31α+a32α2)T2C_{p} = 24.5(a_{11}\alpha + a_{12}\alpha^2)+ (a_{21}\alpha + a_{22}\alpha^2)T +(a_{31}\alpha + a_{32}\alpha^2)T^2
Parameters
Tfloat

Temperature of liquid [K]

similarity_variablefloat

similarity variable as defined in [1], [mol/g]

MWfloat, optional

Molecular weight of the pure compound or mixture average, [g/mol]

termsfloat, optional

Terms in Dadgostar-Shaw equation as computed by Dadgostar_Shaw_terms

Returns
Cplfloat

Liquid constant-pressure heat capacity, J/mol/K if MW given; J/kg/K otherwise

Notes

Many restrictions on its use. Original model is in terms of J/g/K. Note that the model is for predicting mass heat capacity, not molar heat capacity like most other methods! a11 = -0.3416; a12 = 2.2671; a21 = 0.1064; a22 = -0.3874l; a31 = -9.8231E-05; a32 = 4.182E-04

References

1(1,2)

Dadgostar, Nafiseh, and John M. Shaw. “A Predictive Correlation for the Constant-Pressure Specific Heat Capacity of Pure and Ill-Defined Liquid Hydrocarbons.” Fluid Phase Equilibria 313 (January 15, 2012): 211-226. doi:10.1016/j.fluid.2011.09.015.

Examples

>>> Dadgostar_Shaw(355.6, 0.139)
1802.5291501191516
chemicals.heat_capacity.Dadgostar_Shaw_integral(T, similarity_variable, MW=None, terms=None)[source]

Calculate the integral of liquid constant-pressure heat capacity with the similarity variable concept and method as shown in [1].

Parameters
Tfloat

Temperature of gas [K]

similarity_variablefloat

similarity variable as defined in [1], [mol/g]

MWfloat, optional

Molecular weight of the pure compound or mixture average, [g/mol]

termsfloat, optional

Terms in Dadgostar-Shaw equation as computed by Dadgostar_Shaw_terms

Returns
Hfloat

Difference in enthalpy from 0 K, J/mol if MW given; J/kg otherwise

Notes

Original model is in terms of J/g/K. Note that the model is for predicting mass heat capacity, not molar heat capacity like most other methods! Integral was computed with SymPy.

References

1(1,2)

Dadgostar, Nafiseh, and John M. Shaw. “A Predictive Correlation for the Constant-Pressure Specific Heat Capacity of Pure and Ill-Defined Liquid Hydrocarbons.” Fluid Phase Equilibria 313 (January 15, 2012): 211-226. doi:10.1016/j.fluid.2011.09.015.

Examples

>>> Dadgostar_Shaw_integral(300.0, 0.1333)
238908.15142664989
chemicals.heat_capacity.Dadgostar_Shaw_integral_over_T(T, similarity_variable, MW=None, terms=None)[source]

Calculate the integral of liquid constant-pressure heat capacity with the similarity variable concept and method as shown in [1].

Parameters
Tfloat

Temperature of gas [K]

similarity_variablefloat

similarity variable as defined in [1], [mol/g]

MWfloat, optional

Molecular weight of the pure compound or mixture average, [g/mol]

termsfloat, optional

Terms in Dadgostar-Shaw equation as computed by Dadgostar_Shaw_terms

Returns
Sfloat

Difference in entropy from 0 K, J/mol/K if MW given; J/kg/K otherwise

Notes

Original model is in terms of J/g/K. Note that the model is for predicting mass heat capacity, not molar heat capacity like most other methods! Integral was computed with SymPy.

References

1(1,2)

Dadgostar, Nafiseh, and John M. Shaw. “A Predictive Correlation for the Constant-Pressure Specific Heat Capacity of Pure and Ill-Defined Liquid Hydrocarbons.” Fluid Phase Equilibria 313 (January 15, 2012): 211-226. doi:10.1016/j.fluid.2011.09.015.

Examples

>>> Dadgostar_Shaw_integral_over_T(300.0, 0.1333)
1201.1409113147918
chemicals.heat_capacity.Dadgostar_Shaw_terms(similarity_variable)[source]

Return terms for the computation of Dadgostar-Shaw heat capacity equation.

Parameters
similarity_variablefloat

Similarity variable, [mol/g]

Returns
firstfloat

First term, [-]

secondfloat

Second term, [-]

thirdfloat

Third term, [-]

See also

Dadgostar_Shaw

Solid Heat Capacity Estimation Models

chemicals.heat_capacity.Perry_151(T, a, b, c, d)[source]

Return the solid molar heat capacity of a chemical using the Perry 151 method, as described in [1].

Parameters
a,b,c,dfloat

Regressed coefficients.

Returns
Cpsfloat

Solid constant-pressure heat capacity, [J/mol/K]

Notes

The solid heat capacity is given by:

Cn=4.184(a+bT+cT2+dT2)C_n = 4.184 (a + bT + \frac{c}{T^2} + dT^2)

Coefficients are listed in section 2, table 151 of [1]. Note that the original model was in a Calorie basis, but has been translated to Joules.

References

1(1,2)

Green, Don, and Robert Perry. Perry’s Chemical Engineers’ Handbook, Eighth Edition. McGraw-Hill Professional, 2007.

Examples

Heat capacity of solid aluminum at 300 K:

>>> Perry_151(300, 4.8, 0.00322, 0., 0.)
24.124944
chemicals.heat_capacity.Lastovka_solid(T, similarity_variable, MW=None)[source]

Calculate solid constant-pressure heat capacity with the similarity variable concept and method as shown in [1].

Cp=3(A1α+A2α2)R(θT)2exp(θ/T)[exp(θ/T)1]2+(C1α+C2α2)T+(D1α+D2α2)T2C_p = 3(A_1\alpha + A_2\alpha^2)R\left(\frac{\theta}{T}\right)^2 \frac{\exp(\theta/T)}{[\exp(\theta/T)-1]^2} + (C_1\alpha + C_2\alpha^2)T + (D_1\alpha + D_2\alpha^2)T^2
Parameters
Tfloat

Temperature of solid [K]

similarity_variablefloat

similarity variable as defined in [1], [mol/g]

MWfloat, optional

Molecular weight of the pure compound or mixture average, [g/mol]

Returns
Cpsfloat

Solid constant-pressure heat capacity, J/mol/K if MW given; J/kg/K otherwise

Notes

Many restrictions on its use. Trained on data with MW from 12.24 g/mol to 402.4 g/mol, C mass fractions from 61.3% to 95.2%, H mass fractions from 3.73% to 15.2%, N mass fractions from 0 to 15.4%, O mass fractions from 0 to 18.8%, and S mass fractions from 0 to 29.6%. Recommended for organic compounds with low mass fractions of hetero-atoms and especially when molar mass exceeds 200 g/mol. This model does not show and effects of phase transition but should not be used passed the triple point. Original model is in terms of J/g/K. Note that the model s for predicting mass heat capacity, not molar heat capacity like most other methods!

A1 = 0.013183

A2 = 0.249381

θ\theta = 151.8675

C1 = 0.026526

C2 = -0.024942

D1 = 0.000025

D2 = -0.000123

References

1(1,2)

Laštovka, Václav, Michal Fulem, Mildred Becerra, and John M. Shaw. “A Similarity Variable for Estimating the Heat Capacity of Solid Organic Compounds: Part II. Application: Heat Capacity Calculation for Ill-Defined Organic Solids.” Fluid Phase Equilibria 268, no. 1-2 (June 25, 2008): 134-41. doi:10.1016/j.fluid.2008.03.018.

Examples

>>> Lastovka_solid(300, 0.2139)
1682.0637469909211
chemicals.heat_capacity.Lastovka_solid_integral(T, similarity_variable, MW=None)[source]

Integrates solid constant-pressure heat capacity with the similarity variable concept and method as shown in [1].

uses an explicit form as derived with Sympy.

Parameters
Tfloat

Temperature of solid [K]

similarity_variablefloat

similarity variable as defined in [1], [mol/g]

MWfloat, optional

Molecular weight of the pure compound or mixture average, [g/mol]

Returns
Hfloat

Difference in enthalpy from 0 K, J/mol if MW given; J/kg otherwise

See also

Lastovka_solid

Notes

Original model is in terms of J/g/K. Note that the model is for predicting mass heat capacity, not molar heat capacity like most other methods!

References

1(1,2)

Laštovka, Václav, Michal Fulem, Mildred Becerra, and John M. Shaw. “A Similarity Variable for Estimating the Heat Capacity of Solid Organic Compounds: Part II. Application: Heat Capacity Calculation for Ill-Defined Organic Solids.” Fluid Phase Equilibria 268, no. 1-2 (June 25, 2008): 134-41. doi:10.1016/j.fluid.2008.03.018.

Examples

>>> Lastovka_solid_integral(300, 0.2139)
283246.1519409122
chemicals.heat_capacity.Lastovka_solid_integral_over_T(T, similarity_variable, MW=None)[source]

Integrates over T solid constant-pressure heat capacity with the similarity variable concept and method as shown in [1].

uses an explicit form as derived with Sympy.

Parameters
Tfloat

Temperature of solid [K]

similarity_variablefloat

similarity variable as defined in [1], [mol/g]

MWfloat, optional

Molecular weight of the pure compound or mixture average, [g/mol]

Returns
Sfloat

Difference in entropy from 0 K, J/mol/K if MW given; J/kg/K otherwise

See also

Lastovka_solid

Notes

Original model is in terms of J/g/K. Note that the model is for predicting mass heat capacity, not molar heat capacity like most other methods!

References

1(1,2)

Laštovka, Václav, Michal Fulem, Mildred Becerra, and John M. Shaw. “A Similarity Variable for Estimating the Heat Capacity of Solid Organic Compounds: Part II. Application: Heat Capacity Calculation for Ill-Defined Organic Solids.” Fluid Phase Equilibria 268, no. 1-2 (June 25, 2008): 134-41. doi:10.1016/j.fluid.2008.03.018.

Examples

>>> Lastovka_solid_integral_over_T(300, 0.2139)
1947.5537561495564

Utility methods

class chemicals.heat_capacity.PiecewiseHeatCapacity(models)[source]

Create a PiecewiseHeatCapacity object for calculating heat capacity and the enthalpy and entropy integrals using piecewise models.

Parameters
modelsIterable[HeatCapacity]

Piecewise heat capacity objects, [-]

Attributes
Tmax
Tmin
models

Methods

calculate(T)

Return the heat capacity as a function of temperature.

calculate_integral(Ta, Tb)

Return the enthalpy integral of heat capacity from Ta to Tb.

calculate_integral_over_T(Ta, Tb)

Return the entropy integral of heat capacity from Ta to Tb.

force_calculate(T)

Return the heat capacity as a function of temperature.

force_calculate_integral(Ta, Tb)

Return the enthalpy integral of heat capacity from Ta to Tb.

force_calculate_integral_over_T(Ta, Tb)

Return the entropy integral of heat capacity from Ta to Tb.

Fit Coefficients

All of these coefficients are lazy-loaded, so they must be accessed as an attribute of this module.

chemicals.heat_capacity.Cp_data_Poling

Constains data for gases and liquids from [3]. Simple polynomials for gas heat capacity (not suitable for extrapolation) are available for 308 chemicals. Additionally, constant values in at 298.15 K are available for 348 gases. Constant values in at 298.15 K are available for 245 liquids.

chemicals.heat_capacity.TRC_gas_data

A rigorous expression from [1] for modeling gas heat capacity. Coefficients for 1961 chemicals are available.

chemicals.heat_capacity.CRC_standard_data

Constant values tabulated in [4] at 298.15 K. Data is available for 533 gases. Data is available for 433 liquids. Data is available for 529 solids.

chemicals.heat_capacity.Cp_dict_PerryI

Simple polynomials from [5] with vaious exponents selected for each expression. Coefficients are in units of calories/mol/K. The full expression is Cp=a+bT+c/T2+dT2C_p = a + bT + c/T^2 + dT^2. Data is available for 284 compounds. Some compounds have gas data, some have liquid data, and have solid (crystal structure) data, sometimes multiple coefficients for different solid phases.

chemicals.heat_capacity.zabransky_dicts

Complicated fits covering different cases and with different forms from [2].

chemicals.heat_capacity.Cp_dict_characteristic_temperatures_adjusted_psi4_2022a

Theoretically calculated chatacteristic temperatures from vibrational frequencies using psi4

chemicals.heat_capacity.Cp_dict_characteristic_temperatures_psi4_2022a

Theoretically calculated chatacteristic temperatures from vibrational frequencies using psi4, adjusted using a recommended coefficient

1

Kabo, G. J., and G. N. Roganov. Thermodynamics of Organic Compounds in the Gas State, Volume II: V. 2. College Station, Tex: CRC Press, 1994.

2

Zabransky, M., V. Ruzicka Jr, V. Majer, and Eugene S. Domalski. Heat Capacity of Liquids: Critical Review and Recommended Values. 2 Volume Set. Washington, D.C.: Amer Inst of Physics, 1996.

3

Poling, Bruce E. The Properties of Gases and Liquids. 5th edition. New York: McGraw-Hill Professional, 2000.

4

Haynes, W.M., Thomas J. Bruno, and David R. Lide. CRC Handbook of Chemistry and Physics. [Boca Raton, FL]: CRC press, 2014.

5

Green, Don, and Robert Perry. Perry’s Chemical Engineers’ Handbook, Eighth Edition. McGraw-Hill Professional, 2007.

In [1]: import chemicals

In [2]: chemicals.heat_capacity.Cp_data_Poling
Out[2]: 
                                  Chemical   Tmin  ...     Cpg     Cpl
CAS                                                ...                
56-23-5                tetrachloromethane   200.0  ...   83.43  131.60
60-29-7                     diethyl ether   100.0  ...  119.46  172.60
62-53-3            benzeneamine (aniline)    50.0  ...  107.90  191.90
64-17-5                           ethanol    50.0  ...   65.21  112.25
64-18-6      methanoic acid (formic acid)    50.0  ...   53.45   99.17
...                                    ...    ...  ...     ...     ...
14940-65-9                  tritium oxide     NaN  ...   34.96     NaN
16747-38-9     2,3,3,4-tetramethylpentane   200.0  ...  218.30  275.70
20291-95-6         2,2,5-trimethylheptane   200.0  ...  229.20  306.40
800000-51-5              hydrogen, normal     NaN  ...   28.83     NaN
800000-54-8             deuterium, normal     NaN  ...   29.20     NaN

[368 rows x 10 columns]

In [3]: chemicals.heat_capacity.TRC_gas_data
Out[3]: 
                                    Chemical   Tmin  ...      J       Hfg
CAS                                                  ...                 
50-00-0                             Methanal   50.0  ...   3.46 -104700.0
50-32-8                       Benzo[a]pyrene  298.0  ...  13.44  324000.0
53-70-3                Dibenz[a,h]anthracene  298.0  ...  16.63  375000.0
56-23-5                   Tetrachloromethane  200.0  ...   9.58  -93700.0
56-55-3                    Benz[a]anthracene  298.0  ...  11.45  328000.0
...                                      ...    ...  ...    ...       ...
800000-46-8  2,2,(3RS,4RS)-Tetramethylhexane  200.0  ...  22.45 -188600.0
800000-47-9  2,(3RS,4SR),5-Tetramethylhexane  200.0  ...  22.32  193700.0
800000-48-0  2,(3RS,4RS),5-Tetramethylhexane  200.0  ...  22.14 -194600.0
800000-56-0            1-Methylbutyl radical  200.0  ...  22.25   54600.0
800002-32-8           Propenoic acid (Dimer)   50.0  ...  13.83 -686000.0

[1961 rows x 14 columns]

In [4]: chemicals.heat_capacity.CRC_standard_data
Out[4]: 
                                Chemical        Hfs  ...    S0g    Cpg
CAS                                                  ...              
50-00-0                     Formaldehyde        NaN  ...  218.8   35.4
50-32-8                   Benzo[a]pyrene        NaN  ...    NaN  254.8
50-69-1                         D-Ribose -1047200.0  ...    NaN    NaN
50-78-2        2-(Acetyloxy)benzoic acid  -815600.0  ...    NaN    NaN
50-81-7                  L-Ascorbic acid -1164600.0  ...    NaN    NaN
...                                  ...        ...  ...    ...    ...
92141-86-1             Cesium metaborate  -972000.0  ...    NaN    NaN
99685-96-8        Carbon [fullerene-C60]  2327000.0  ...  544.0  512.0
114489-96-2  Isobutyl 2-chloropropanoate        NaN  ...    NaN    NaN
115383-22-7       Carbon [fullerene-C70]  2555000.0  ...  614.0  585.0
116836-32-9         sec-Butyl pentanoate        NaN  ...    NaN    NaN

[2470 rows x 13 columns]

In [5]: chemicals.heat_capacity.Cp_dict_PerryI['124-38-9'] # gas only
Out[5]: 
{'g': {'Formula': 'CO2',
  'Phase': 'g',
  'Subphase': None,
  'Const': 10.34,
  'Lin': 0.00274,
  'Quadinv': -195500.0,
  'Quad': 0,
  'Tmin': 273.0,
  'Tmax': 1200.0,
  'Error': '1a'}}

In [6]: chemicals.heat_capacity.Cp_dict_PerryI['7704-34-9'] # crystal and gas
Out[6]: 
{'g': {'Formula': 'H2S',
  'Phase': 'g',
  'Subphase': None,
  'Const': 7.2,
  'Lin': 0.0036,
  'Quadinv': 0,
  'Quad': 0,
  'Tmin': 300.0,
  'Tmax': 600.0,
  'Error': 8.0},
 'c': {'Formula': 'S',
  'Phase': 'c',
  'Subphase': 'monoclinic',
  'Const': 4.38,
  'Lin': 0.0044,
  'Quadinv': 0,
  'Quad': 0,
  'Tmin': 368.0,
  'Tmax': 392.0,
  'Error': 3.0}}

In [7]: chemicals.heat_capacity.Cp_dict_PerryI['7440-57-5'] # crystal and liquid
Out[7]: 
{'c': {'Formula': 'Au',
  'Phase': 'c',
  'Subphase': None,
  'Const': 5.61,
  'Lin': 0.00144,
  'Quadinv': 0,
  'Quad': 0,
  'Tmin': 273.0,
  'Tmax': 1336.0,
  'Error': 2.0},
 'l': {'Formula': 'Au',
  'Phase': 'l',
  'Subphase': None,
  'Const': 7.0,
  'Lin': 0,
  'Quadinv': 0,
  'Quad': 0,
  'Tmin': 1336.0,
  'Tmax': 1573.0,
  'Error': 5.0}}

In [8]: chemicals.heat_capacity.zabransky_dicts.keys()
Out[8]: dict_keys(['Zabransky spline, averaged heat capacity', 'Zabransky quasipolynomial, averaged heat capacity', 'Zabransky spline, constant-pressure', 'Zabransky quasipolynomial, constant-pressure', 'Zabransky spline, saturation', 'Zabransky quasipolynomial, saturation'])