You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Although the calculation is often done separately for efficiency, the molar enthalpy, internal energy, entropy, Gibbs free energy, and volume should be equal to the mole fraction weighted sum of the corresponding partial molar properties. For LatticePhase, most of these do not agree. The partial_molar_enthalpies seem to be particularly bad.
Additionally, the implementations of getStandardChemPotentials and getGibbs_RT (which is supposed to calculated the nondimensional standard chemical potentials) are inconsistent.
Steps to reproduce
>>>p=ct.Solution('test/data/thermo-models.yaml', 'Li7Si3-interstitial')
>>>p.gibbs_mole, sum(p.X*p.chemical_potentials)
-349994.3375144891, -349042.0221149627)
>>>p.enthalpy_mole, sum(p.X*p.partial_molar_enthalpies)
(261425.4600475561, 174272.0)
>>>p.volume_mole, sum(p.X*p.partial_molar_volumes)
(0.09557086388415284, 0.09661515524531131)
>>>p.entropy_mole, sum(p.X*p.partial_molar_entropies)
(843.3376518097174, 843.3376518097147) # this one is OK# partial_molar_int_energies is not implemented
Problem description
Although the calculation is often done separately for efficiency, the molar enthalpy, internal energy, entropy, Gibbs free energy, and volume should be equal to the mole fraction weighted sum of the corresponding partial molar properties. For
LatticePhase
, most of these do not agree. Thepartial_molar_enthalpies
seem to be particularly bad.Additionally, the implementations of
getStandardChemPotentials
andgetGibbs_RT
(which is supposed to calculated the nondimensional standard chemical potentials) are inconsistent.Steps to reproduce
System information
main
at 1ab81acAdditional context
This was discovered as part of #1299, which implements Cantera/enhancements#114.
The text was updated successfully, but these errors were encountered: