Coverage for eminus/xc/lda_xc_corr_ksdt.py: 100.00%

24 statements  

« prev     ^ index     » next       coverage.py v7.8.2, created at 2025-06-02 10:16 +0000

1# SPDX-FileCopyrightText: 2025 The eminus developers 

2# SPDX-License-Identifier: Apache-2.0 

3"""Corrected KSDT LDA exchange-correlation. 

4 

5The corrected KSDT functional has not been parameterized for spin-polarized calculations. 

6 

7Reference: Phys. Rev. Lett. 120, 076401. 

8""" 

9 

10import dataclasses 

11 

12from .lda_xc_ksdt import Coefficients, lda_xc_ksdt 

13 

14 

15@dataclasses.dataclass 

16class Zeta0Coeffs(Coefficients): 

17 """Coefficient class using the parameters for zeta=0. 

18 

19 Reference: Phys. Rev. Lett. 120, 076401. 

20 """ 

21 

22 omega: float = 1 

23 b1: float = 0.342554 

24 b2: float = 9.141315 

25 b3: float = 0.448483 

26 b4: float = 18.553096 

27 c1: float = 0.87513 

28 c2: float = -0.25632 

29 c3: float = 0.953988 

30 d1: float = 0.725917 

31 d2: float = 2.237347 

32 d3: float = 0.280748 

33 d4: float = 4.185911 

34 d5: float = 0.692183 

35 e1: float = 0.255415 

36 e2: float = 0.931933 

37 e3: float = 0.115398 

38 e4: float = 17.234117 

39 e5: float = 0.451437 

40 

41 

42def lda_xc_corr_ksdt(n, T=0, **kwargs): 

43 """Corrected KSDT exchange-correlation functional (spin-paired). 

44 

45 Similar to the functional with the label LDA_XC_CORRKSDT and ID 318 in Libxc, but the 

46 implementations differ: https://gitlab.com/libxc/libxc/-/issues/525 

47 Exchange and correlation cannot be separated. 

48 

49 Reference: Phys. Rev. Lett. 120, 076401. 

50 

51 Args: 

52 n: Real-space electronic density. 

53 

54 Keyword Args: 

55 T: Temperature in Hartree. 

56 **kwargs: Throwaway arguments. 

57 

58 Returns: 

59 Corrected KSDT exchange-correlation energy density and potential. 

60 """ 

61 return lda_xc_ksdt(n, T=T, zeta0_coeffs=Zeta0Coeffs, **kwargs)