Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Translational entropy calculations #649

Open
dgarayr opened this issue Jun 16, 2022 · 1 comment · May be fixed by #1077
Open

Translational entropy calculations #649

dgarayr opened this issue Jun 16, 2022 · 1 comment · May be fixed by #1077
Labels
documentation Improvements or additions to documentation

Comments

@dgarayr
Copy link

dgarayr commented Jun 16, 2022

Checking thermochemical calculations from xTB, I find the way in which translational entropy is calculated a bit weird (although results are right). The expression in the thermodyn subroutine from thermo.f90 for s_tr involves a simplified expression including two hard-coded values named magic4 and magic5.

s_tr=magic4*(5.0_wp*log10(t)+3.0_wp*log10(molmass))-magic5

There is no direct reference to the source of these values, although they can be traced to an equation presented by Stewart and Tseng, J. Am. Chem. Soc. 1971, 93, 5, 1273, which was derived from the Sackur-Tetrode equation as presented in S. Glasstone, “Theoretical Chemistry”, 1944. Following the original text, it is found that the simplified equation is reached by rearranging constants, changing the logarithms to base 10, and converting P to atm and R to cal mol-1 K-1. Although the expression is correct and thus the obtained values are valid, it is quite confusing to encounter this quite old and non-referenced expression for the translational entropy when the rest of magnitudes in the subroutine, including the own translational partition function, are computed directly from physical constants using common expressions for statistical thermodynamics.

Moreover, the employed expression drops the pressure dependence of translational entropy, assuming P = 1 to cancel the logarithm. I could not find the pressure reference state used by xTB for thermochemical calculations neither in the module nor in the documentation, so it might be stated more explicitly at some point, maybe even in the output together with the temperature. Going a bit beyond this, I think the ideal feature would be to allow the user to change the pressure reference state as it is done with temperature, like in other codes such as Gaussian or ADF.

@awvwgk
Copy link
Member

awvwgk commented Jun 16, 2022

When refactoring this part of the code I didn't track all constants back to the Sackur–Tetrode equation for the translational entropy, mainly because the code was using a mix of CGS and SI units (now we use a mix of Hartree and SI units). The leftover inline constants were numbered with the intent to resolve at some point in the future.

Translating everything to Hartree units and using meaningful variable names would of course be useful.

Contributions are of course welcome, xtb is an open source project after all.

@marcelmbn marcelmbn added the documentation Improvements or additions to documentation label Aug 7, 2024
@marcelmbn marcelmbn assigned marcelmbn and unassigned marcelmbn Aug 7, 2024
@marcelmbn marcelmbn linked a pull request Aug 7, 2024 that will close this issue
@marcelmbn marcelmbn linked a pull request Aug 7, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants