TB2J 0.9.9rc4__py3-none-any.whl → 0.9.9rc6__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (29) hide show
  1. TB2J/MAE.py +3 -3
  2. TB2J/MAEGreen.py +43 -11
  3. TB2J/contour.py +16 -0
  4. TB2J/exchange.py +30 -27
  5. TB2J/exchangeCL2.py +20 -11
  6. TB2J/exchange_params.py +19 -4
  7. TB2J/green.py +77 -14
  8. TB2J/interfaces/siesta_interface.py +2 -1
  9. TB2J/kpoints.py +86 -1
  10. TB2J/mycfr.py +114 -0
  11. TB2J/orbmap.py +4 -4
  12. TB2J/symmetrize_J.py +17 -7
  13. TB2J/versioninfo.py +2 -1
  14. {TB2J-0.9.9rc4.dist-info → TB2J-0.9.9rc6.dist-info}/METADATA +1 -1
  15. {TB2J-0.9.9rc4.dist-info → TB2J-0.9.9rc6.dist-info}/RECORD +29 -28
  16. {TB2J-0.9.9rc4.dist-info → TB2J-0.9.9rc6.dist-info}/WHEEL +1 -1
  17. {TB2J-0.9.9rc4.data → TB2J-0.9.9rc6.data}/scripts/TB2J_downfold.py +0 -0
  18. {TB2J-0.9.9rc4.data → TB2J-0.9.9rc6.data}/scripts/TB2J_eigen.py +0 -0
  19. {TB2J-0.9.9rc4.data → TB2J-0.9.9rc6.data}/scripts/TB2J_magnon.py +0 -0
  20. {TB2J-0.9.9rc4.data → TB2J-0.9.9rc6.data}/scripts/TB2J_magnon_dos.py +0 -0
  21. {TB2J-0.9.9rc4.data → TB2J-0.9.9rc6.data}/scripts/TB2J_merge.py +0 -0
  22. {TB2J-0.9.9rc4.data → TB2J-0.9.9rc6.data}/scripts/TB2J_rotate.py +0 -0
  23. {TB2J-0.9.9rc4.data → TB2J-0.9.9rc6.data}/scripts/TB2J_rotateDM.py +0 -0
  24. {TB2J-0.9.9rc4.data → TB2J-0.9.9rc6.data}/scripts/abacus2J.py +0 -0
  25. {TB2J-0.9.9rc4.data → TB2J-0.9.9rc6.data}/scripts/siesta2J.py +0 -0
  26. {TB2J-0.9.9rc4.data → TB2J-0.9.9rc6.data}/scripts/wann2J.py +0 -0
  27. {TB2J-0.9.9rc4.dist-info → TB2J-0.9.9rc6.dist-info}/LICENSE +0 -0
  28. {TB2J-0.9.9rc4.dist-info → TB2J-0.9.9rc6.dist-info}/entry_points.txt +0 -0
  29. {TB2J-0.9.9rc4.dist-info → TB2J-0.9.9rc6.dist-info}/top_level.txt +0 -0
TB2J/MAE.py CHANGED
@@ -137,9 +137,9 @@ class MAEGreen(MAE):
137
137
  efermi = occ.efermi(evals)
138
138
  print(f"{efermi=}")
139
139
  self.G = TBGreen(model, kmesh, efermi=efermi, gamma=gamma, **kwargs)
140
- self.emin = -12
140
+ self.emin = -52
141
141
  self.emax = 0
142
- self.nz = 50
142
+ self.nz = 100
143
143
  self._prepare_elist()
144
144
 
145
145
  def _prepare_elist(self, method="legendre"):
@@ -186,7 +186,7 @@ class MAEGreen(MAE):
186
186
  for ie, e in enumerate(tqdm.tqdm(self.contour.path)):
187
187
  dE_angle = self.get_perturbed(e, thetas, phis)
188
188
  es += np.imag(dE_angle * self.contour.weights[ie])
189
- return -es / np.pi
189
+ return -es / np.pi / 2
190
190
 
191
191
 
192
192
  def get_model_energy(model, kmesh, gamma=True):
TB2J/MAEGreen.py CHANGED
@@ -3,10 +3,11 @@ from pathlib import Path
3
3
  import numpy as np
4
4
  import tqdm
5
5
  from HamiltonIO.abacus.abacus_wrapper import AbacusSplitSOCParser
6
- from HamiltonIO.model.occupations import Occupations
6
+ from HamiltonIO.model.occupations import GaussOccupations
7
7
  from typing_extensions import DefaultDict
8
8
 
9
9
  from TB2J.exchange import ExchangeNCL
10
+ from TB2J.external import p_map
10
11
 
11
12
  # from HamiltonIO.model.rotate_spin import rotate_Matrix_from_z_to_axis, rotate_Matrix_from_z_to_sperical
12
13
  # from TB2J.abacus.abacus_wrapper import AbacusWrapper, AbacusParser
@@ -16,7 +17,7 @@ from TB2J.mathutils.rotate_spin import (
16
17
 
17
18
 
18
19
  def get_occupation(evals, kweights, nel, width=0.1):
19
- occ = Occupations(nel=nel, width=width, wk=kweights, nspin=2)
20
+ occ = GaussOccupations(nel=nel, width=width, wk=kweights, nspin=2)
20
21
  return occ.occupy(evals)
21
22
 
22
23
 
@@ -78,6 +79,17 @@ class MAEGreen(ExchangeNCL):
78
79
 
79
80
  def get_perturbed(self, e, thetas, phis):
80
81
  self.tbmodel.set_so_strength(0.0)
82
+ maxsoc = self.tbmodel.get_max_Hsoc_abs()
83
+ maxH0 = self.tbmodel.get_max_H0_spin_abs()
84
+ if maxsoc > maxH0 * 0.01:
85
+ print(f"""Warning: The SOC of the Hamiltonian has a maximum of {maxsoc} eV,
86
+ comparing to the maximum of {maxH0} eV of the spin part of the Hamiltonian.
87
+ The SOC is too strong, the perturbation theory may not be valid.""")
88
+
89
+ print(f"""Warning: The SOC of the Hamiltonian has a maximum of {maxsoc} eV,
90
+ comparing to the maximum of {maxH0} eV of the spin part of the Hamiltonian.
91
+ The SOC is too strong, the perturbation theory may not be valid.""")
92
+
81
93
  G0K = self.G.get_Gk_all(e)
82
94
  Hsoc_k = self.tbmodel.get_Hk_soc(self.G.kpts)
83
95
  na = len(thetas)
@@ -97,6 +109,7 @@ class MAEGreen(ExchangeNCL):
97
109
  dG2 = GdH * GdH.T
98
110
  dG2sum = np.sum(dG2)
99
111
  # print(f"dG2sum-sum: {dG2sum}")
112
+ dG2sum = np.sum(dG2diag)
100
113
 
101
114
  # dG2sum = np.trace(GdH @ GdH)
102
115
  # print(f"dG2sum-Tr: {dG2sum}")
@@ -142,15 +155,33 @@ class MAEGreen(ExchangeNCL):
142
155
  if with_eigen:
143
156
  self.es2 = self.get_band_energy_vs_angles_from_eigen(thetas, phis)
144
157
 
145
- for ie, e in enumerate(tqdm.tqdm(self.contour.path)):
146
- dE_angle, dE_angle_atom, dE_angle_atom_orb = self.get_perturbed(
147
- e, thetas, phis
148
- )
149
- self.es += dE_angle * self.contour.weights[ie]
150
- self.es_atom += dE_angle_atom * self.contour.weights[ie]
158
+ # for ie, e in enumerate(tqdm.tqdm(self.contour.path)):
159
+ # dE_angle, dE_angle_atom, dE_angle_atom_orb = self.get_perturbed(
160
+ # e, thetas, phis
161
+ # )
162
+ # self.es += dE_angle * self.contour.weights[ie]
163
+ # self.es_atom += dE_angle_atom * self.contour.weights[ie]
164
+ # for key, value in dE_angle_atom_orb.items():
165
+ # self.es_atom_orb[key] += (
166
+ # dE_angle_atom_orb[key] * self.contour.weights[ie]
167
+ # )
168
+
169
+ # rewrite the for loop above to use p_map
170
+ def func(e):
171
+ return self.get_perturbed(e, thetas, phis)
172
+
173
+ if self.nproc > 1:
174
+ results = p_map(func, self.contour.path, num_cpus=self.nproc)
175
+ else:
176
+ npole = len(self.contour.path)
177
+ results = map(func, tqdm.tqdm(self.contour.path, total=npole))
178
+ for i, result in enumerate(results):
179
+ dE_angle, dE_angle_atom, dE_angle_atom_orb = result
180
+ self.es += dE_angle * self.contour.weights[i]
181
+ self.es_atom += dE_angle_atom * self.contour.weights[i]
151
182
  for key, value in dE_angle_atom_orb.items():
152
183
  self.es_atom_orb[key] += (
153
- dE_angle_atom_orb[key] * self.contour.weights[ie]
184
+ dE_angle_atom_orb[key] * self.contour.weights[i]
154
185
  )
155
186
 
156
187
  self.es = -np.imag(self.es) / (2 * np.pi)
@@ -158,7 +189,7 @@ class MAEGreen(ExchangeNCL):
158
189
  for key, value in self.es_atom_orb.items():
159
190
  self.es_atom_orb[key] = -np.imag(value) / (2 * np.pi)
160
191
 
161
- def output(self, output_path="TB2J_anisotropy", with_eigen=False):
192
+ def output(self, output_path="TB2J_anisotropy", with_eigen=True):
162
193
  Path(output_path).mkdir(exist_ok=True)
163
194
  fname = f"{output_path}/MAE.dat"
164
195
  fname_orb = f"{output_path}/MAE_orb.dat"
@@ -242,6 +273,7 @@ def abacus_get_MAE(
242
273
  magnetic_elements=None,
243
274
  nel=None,
244
275
  width=0.1,
276
+ with_eigen=False,
245
277
  **kwargs,
246
278
  ):
247
279
  """Get MAE from Abacus with magnetic force theorem. Two calculations are needed. First we do an calculation with SOC but the soc_lambda is set to 0. Save the density. The next calculatin we start with the density from the first calculation and set the SOC prefactor to 1. With the information from the two calcualtions, we can get the band energy with magnetic moments in the direction, specified in two list, thetas, and phis."""
@@ -262,4 +294,4 @@ def abacus_get_MAE(
262
294
  magnetic_elements=magnetic_elements,
263
295
  **kwargs,
264
296
  )
265
- mae.run(output_path=output_path)
297
+ mae.run(output_path=output_path, with_eigen=with_eigen)
TB2J/contour.py CHANGED
@@ -1,5 +1,6 @@
1
1
  import numpy as np
2
2
  from scipy.special import roots_legendre
3
+
3
4
  from TB2J.utils import simpson_nonuniform_weight
4
5
 
5
6
 
@@ -15,6 +16,21 @@ class Contour:
15
16
  self._weights = simpson_nonuniform_weight(self.path)
16
17
  return self._weights
17
18
 
19
+ def integrate_func(self, func):
20
+ """
21
+ integrate f along the path
22
+ """
23
+ return np.dot(func(self.path), self.weights)
24
+
25
+ def integrate_values(self, values):
26
+ """
27
+ integrate f along the path
28
+ """
29
+ ret = 0
30
+ for i in range(len(values)):
31
+ ret += values[i] * self.weights[i]
32
+ return ret
33
+
18
34
  def build_path_semicircle(self, npoints, endpoint=True):
19
35
  R = (self.emax - self.emin) / 2.0
20
36
  R0 = (self.emin + self.emax) / 2.0
TB2J/exchange.py CHANGED
@@ -10,29 +10,24 @@ from TB2J.exchange_params import ExchangeParams
10
10
  from TB2J.external import p_map
11
11
  from TB2J.green import TBGreen
12
12
  from TB2J.io_exchange import SpinIO
13
+ from TB2J.mycfr import CFR
13
14
  from TB2J.orbmap import map_orbs_matrix
14
15
  from TB2J.pauli import pauli_block_all, pauli_block_sigma_norm
15
16
  from TB2J.utils import (
16
17
  kmesh_to_R,
17
- simpson_nonuniform,
18
18
  symbol_number,
19
- trapezoidal_nonuniform,
20
19
  )
21
20
 
22
21
 
23
22
  class Exchange(ExchangeParams):
24
- def __init__(
25
- self,
26
- tbmodels,
27
- atoms,
28
- **params: ExchangeParams,
29
- ):
23
+ def __init__(self, tbmodels, atoms, **params):
30
24
  self.atoms = atoms
31
25
  super().__init__(**params)
32
26
  self._prepare_kmesh(self._kmesh)
33
27
  self._prepare_Rlist()
34
28
  self.set_tbmodels(tbmodels)
35
29
  self._adjust_emin()
30
+ # self._prepare_elist(method="CFR")
36
31
  self._prepare_elist(method="legendre")
37
32
  self._prepare_basis()
38
33
  self._prepare_orb_dict()
@@ -50,8 +45,9 @@ class Exchange(ExchangeParams):
50
45
  os.makedirs(self.orbpath, exist_ok=True)
51
46
 
52
47
  def _adjust_emin(self):
53
- # self.emin = self.G.find_energy_ingap(rbound=self.efermi - 10.0) - self.efermi
54
- self.emin = -22.0
48
+ self.emin = self.G.find_energy_ingap(rbound=self.efermi - 15.0) - self.efermi
49
+ # self.emin = self.G.find_energy_ingap(rbound=self.efermi - 15.0) - self.efermi
50
+ # self.emin = -42.0
55
51
  print(f"A gap is found at {self.emin}, set emin to it.")
56
52
 
57
53
  def set_tbmodels(self, tbmodels):
@@ -62,25 +58,28 @@ class Exchange(ExchangeParams):
62
58
  # del self.G.tbmodel
63
59
  pass
64
60
 
65
- def _prepare_kmesh(self, kmesh):
61
+ def _prepare_kmesh(self, kmesh, ibz=False):
66
62
  for k in kmesh:
67
63
  self.kmesh = list(map(lambda x: x // 2 * 2 + 1, kmesh))
68
64
 
69
- def _prepare_elist(self, method="legendre"):
65
+ def _prepare_elist(self, method="CFR"):
70
66
  """
71
67
  prepare list of energy for integration.
72
68
  The path has three segments:
73
69
  emin --1-> emin + 1j*height --2-> emax+1j*height --3-> emax
74
70
  """
75
- self.contour = Contour(self.emin, self.emax)
76
71
  # if method.lower() == "rectangle":
77
72
  # self.contour.build_path_rectangle(
78
73
  # height=self.height, nz1=self.nz1, nz2=self.nz2, nz3=self.nz3
79
74
  # )
80
75
  if method.lower() == "semicircle":
76
+ self.contour = Contour(self.emin, self.emax)
81
77
  self.contour.build_path_semicircle(npoints=self.nz, endpoint=True)
82
78
  elif method.lower() == "legendre":
79
+ self.contour = Contour(self.emin, self.emax)
83
80
  self.contour.build_path_legendre(npoints=self.nz, endpoint=True)
81
+ elif method.lower() == "cfr":
82
+ self.contour = CFR(nz=self.nz, T=600)
84
83
  else:
85
84
  raise ValueError(f"The path cannot be of type {method}.")
86
85
 
@@ -119,6 +118,7 @@ class Exchange(ExchangeParams):
119
118
  else:
120
119
  try:
121
120
  atom_sym, orb_sym = base[:2]
121
+ iatom = sdict[atom_sym]
122
122
  except Exception:
123
123
  iatom = base.iatom
124
124
  atom_sym = base.iatom
@@ -150,7 +150,7 @@ class Exchange(ExchangeParams):
150
150
  )
151
151
  if not self._is_collinear:
152
152
  for iatom, orb in self.orb_dict.items():
153
- print(f"iatom: {iatom}, orb: {orb}")
153
+ # print(f"iatom: {iatom}, orb: {orb}")
154
154
  nsorb = len(self.orb_dict[iatom])
155
155
  if nsorb % 2 != 0 and False:
156
156
  raise ValueError(
@@ -173,10 +173,9 @@ or badly localized. Please check the Wannier centers in the Wannier90 output fil
173
173
  self.mmats = {}
174
174
  self.orbital_names = {}
175
175
  self.norb_reduced = {}
176
- print(f"self.backend_name: {self.backend_name}")
177
176
  if self.backend_name.upper() in ["SIESTA", "ABACUS", "LCAOHAMILTONIAN"]:
178
- print(f"magntic_elements: {self.magnetic_elements}")
179
- print(f"include_orbs: {self.include_orbs}")
177
+ # print(f"magntic_elements: {self.magnetic_elements}")
178
+ # print(f"include_orbs: {self.include_orbs}")
180
179
  syms = self.atoms.get_chemical_symbols()
181
180
  for iatom, orbs in self.labels.items():
182
181
  if (self.include_orbs is not None) and syms[iatom] in self.include_orbs:
@@ -186,7 +185,7 @@ or badly localized. Please check the Wannier centers in the Wannier90 output fil
186
185
  include_only=self.include_orbs[syms[iatom]],
187
186
  )
188
187
  else:
189
- print(f"orbs: {orbs}")
188
+ # print(f"orbs: {orbs}")
190
189
  mmat, reduced_orbs = map_orbs_matrix(
191
190
  orbs, spinor=not (self._is_collinear), include_only=None
192
191
  )
@@ -271,10 +270,10 @@ class ExchangeNCL(Exchange):
271
270
  """
272
271
  self.tbmodel = tbmodels
273
272
  self.backend_name = self.tbmodel.name
274
- print(self.kmesh)
275
273
  self.G = TBGreen(
276
274
  tbmodel=self.tbmodel,
277
275
  kmesh=self.kmesh,
276
+ ibz=self.ibz,
278
277
  gamma=True,
279
278
  efermi=self.efermi,
280
279
  use_cache=self._use_cache,
@@ -567,20 +566,24 @@ class ExchangeNCL(Exchange):
567
566
  AijRs: a list of AijR,
568
567
  wherer AijR: array of ((nR, n, n, 4,4), dtype=complex)
569
568
  """
570
- if method == "trapezoidal":
571
- integrate = trapezoidal_nonuniform
572
- elif method == "simpson":
573
- integrate = simpson_nonuniform
569
+ # if method == "trapezoidal":
570
+ # integrate = trapezoidal_nonuniform
571
+ # elif method == "simpson":
572
+ # integrate = simpson_nonuniform
573
+ #
574
574
 
575
575
  # self.rho = integrate(self.contour.path, rhoRs)
576
576
  for iR, R in enumerate(self.R_ijatom_dict):
577
577
  for iatom, jatom in self.R_ijatom_dict[R]:
578
578
  f = AijRs[(R, iatom, jatom)]
579
- self.A_ijR[(R, iatom, jatom)] = integrate(self.contour.path, f)
579
+ # self.A_ijR[(R, iatom, jatom)] = integrate(self.contour.path, f)
580
+ self.A_ijR[(R, iatom, jatom)] = self.contour.integrate_values(f)
581
+
580
582
  if self.orb_decomposition:
581
- self.A_ijR_orb[(R, iatom, jatom)] = integrate(
582
- self.contour.path, AijRs_orb[(R, iatom, jatom)]
583
- )
583
+ # self.A_ijR_orb[(R, iatom, jatom)] = integrate(
584
+ # self.contour.path, AijRs_orb[(R, iatom, jatom)]
585
+ # )
586
+ self.contour.integrate_values(AijRs_orb[(R, iatom, jatom)])
584
587
 
585
588
  def get_quantities_per_e(self, e):
586
589
  Gk_all = self.G.get_Gk_all(e)
TB2J/exchangeCL2.py CHANGED
@@ -1,15 +1,18 @@
1
1
  """
2
2
  Exchange from Green's function
3
3
  """
4
+
4
5
  import os
5
6
  from collections import defaultdict
7
+
6
8
  import numpy as np
7
- from TB2J.green import TBGreen
8
- from TB2J.io_exchange import SpinIO
9
9
  from tqdm import tqdm
10
+
10
11
  from TB2J.external import p_map
12
+ from TB2J.green import TBGreen
13
+ from TB2J.io_exchange import SpinIO
14
+
11
15
  from .exchange import ExchangeCL
12
- from .utils import simpson_nonuniform, trapezoidal_nonuniform
13
16
 
14
17
 
15
18
  class ExchangeCL2(ExchangeCL):
@@ -221,17 +224,23 @@ class ExchangeCL2(ExchangeCL):
221
224
  # shutil.rmtree(path)
222
225
 
223
226
  def integrate(self, method="simpson"):
224
- if method == "trapezoidal":
225
- integrate = trapezoidal_nonuniform
226
- elif method == "simpson":
227
- integrate = simpson_nonuniform
227
+ # if method == "trapezoidal":
228
+ # integrate = trapezoidal_nonuniform
229
+ # elif method == "simpson":
230
+ # integrate = simpson_nonuniform
228
231
  for R, ijpairs in self.R_ijatom_dict.items():
229
232
  for iatom, jatom in ijpairs:
230
- self.Jorb[(R, iatom, jatom)] = integrate(
231
- self.contour.path, self.Jorb_list[(R, iatom, jatom)]
233
+ # self.Jorb[(R, iatom, jatom)] = integrate(
234
+ # self.contour.path, self.Jorb_list[(R, iatom, jatom)]
235
+ # )
236
+ # self.JJ[(R, iatom, jatom)] = integrate(
237
+ # self.contour.path, self.JJ_list[(R, iatom, jatom)]
238
+ # )
239
+ self.Jorb[(R, iatom, jatom)] = self.contour.integrate_values(
240
+ self.Jorb_list[(R, iatom, jatom)]
232
241
  )
233
- self.JJ[(R, iatom, jatom)] = integrate(
234
- self.contour.path, self.JJ_list[(R, iatom, jatom)]
242
+ self.JJ[(R, iatom, jatom)] = self.contour.integrate_values(
243
+ self.JJ_list[(R, iatom, jatom)]
235
244
  )
236
245
 
237
246
  def get_quantities_per_e(self, e):
TB2J/exchange_params.py CHANGED
@@ -31,6 +31,7 @@ class ExchangeParams:
31
31
  output_path: str = "TB2J_results"
32
32
  mae_angles = None
33
33
  orth = False
34
+ ibz = False
34
35
 
35
36
  def __init__(
36
37
  self,
@@ -53,6 +54,7 @@ class ExchangeParams:
53
54
  exclude_orbs=[],
54
55
  mae_angles=None,
55
56
  orth=False,
57
+ ibz=False,
56
58
  ):
57
59
  self.efermi = efermi
58
60
  self.basis = basis
@@ -76,6 +78,7 @@ class ExchangeParams:
76
78
  self.output_path = output_path
77
79
  self.mae_angles = mae_angles
78
80
  self.orth = orth
81
+ self.ibz = ibz
79
82
 
80
83
  def set_params(self, **kwargs):
81
84
  for key, val in kwargs.items():
@@ -92,8 +95,6 @@ class ExchangeParams:
92
95
  include_orbs = {}
93
96
  if isinstance(magnetic_elements, str):
94
97
  magnetic_elements = [magnetic_elements]
95
- print(f"magnetic_elements: {magnetic_elements}")
96
- print(f"include_orbs: {include_orbs}")
97
98
  for element in magnetic_elements:
98
99
  if "_" in element:
99
100
  elem = element.split("_")[0]
@@ -102,8 +103,6 @@ class ExchangeParams:
102
103
  else:
103
104
  include_orbs[element] = None
104
105
 
105
- print(f"magnetic_elements: {magnetic_elements}")
106
- print(f"include_orbs: {include_orbs}")
107
106
  magnetic_elements = list(include_orbs.keys())
108
107
  return magnetic_elements, include_orbs
109
108
 
@@ -116,6 +115,14 @@ def add_exchange_args_to_parser(parser: argparse.ArgumentParser):
116
115
  type=str,
117
116
  nargs="*",
118
117
  )
118
+
119
+ parser.add_argument(
120
+ "--spinor",
121
+ help="whether the Wannier functions are spinor. Default: False",
122
+ action="store_true",
123
+ default=False,
124
+ )
125
+
119
126
  parser.add_argument(
120
127
  "--rcut",
121
128
  help="cutoff of spin pair distance. The default is to calculate all commensurate R point to the k mesh.",
@@ -214,6 +221,14 @@ def add_exchange_args_to_parser(parser: argparse.ArgumentParser):
214
221
  action="store_true",
215
222
  default=False,
216
223
  )
224
+
225
+ parser.add_argument(
226
+ "--ibz",
227
+ help=" use irreducible k-points in the Brillouin zone. (Note: only for computing total MAE).",
228
+ action="store_true",
229
+ default=False,
230
+ )
231
+
217
232
  return parser
218
233
 
219
234
 
TB2J/green.py CHANGED
@@ -7,17 +7,28 @@ from collections import defaultdict
7
7
  from shutil import rmtree
8
8
 
9
9
  import numpy as np
10
- from HamiltonIO.model.occupations import Occupations
10
+ from HamiltonIO.model.occupations import GaussOccupations
11
11
  from HamiltonIO.model.occupations import myfermi as fermi
12
12
  from pathos.multiprocessing import ProcessPool
13
13
 
14
- from TB2J.kpoints import monkhorst_pack
14
+ from TB2J.kpoints import ir_kpts, monkhorst_pack
15
15
 
16
16
  # from TB2J.mathutils.fermi import fermi
17
17
 
18
18
  MAX_EXP_ARGUMENT = np.log(sys.float_info.max)
19
19
 
20
20
 
21
+ def eigen_to_G2(H, S, efermi, energy):
22
+ """calculate green's function from eigenvalue/eigenvector for energy(e-ef): G(e-ef).
23
+ :param H: Hamiltonian matrix in eigenbasis
24
+ :param S: Overlap matrix in eigenbasis
25
+ :param efermi: fermi energy
26
+ :param energy: energy level e - efermi
27
+ """
28
+ # G = ((E+Ef) S - H)^-1
29
+ return np.linalg.inv((energy + efermi) * S - H)
30
+
31
+
21
32
  def eigen_to_G(evals, evecs, efermi, energy):
22
33
  """calculate green's function from eigenvalue/eigenvector for energy(e-ef): G(e-ef).
23
34
  :param evals: eigen values
@@ -40,7 +51,7 @@ def eigen_to_G(evals, evecs, efermi, energy):
40
51
  )
41
52
 
42
53
 
43
- def find_energy_ingap(evals, rbound, gap=4.0):
54
+ def find_energy_ingap(evals, rbound, gap=2.0):
44
55
  """
45
56
  find a energy inside a gap below rbound (right bound),
46
57
  return the energy gap top - 0.5.
@@ -59,9 +70,11 @@ class TBGreen:
59
70
  self,
60
71
  tbmodel,
61
72
  kmesh=None, # [ikpt, 3]
73
+ ibz=False, # if True, will interpolate the Green's function at Ir-kpoints
62
74
  efermi=None, # efermi
63
75
  gamma=False,
64
76
  kpts=None,
77
+ kweights=None,
65
78
  k_sym=False,
66
79
  use_cache=False,
67
80
  cache_path=None,
@@ -81,20 +94,64 @@ class TBGreen:
81
94
  self.cache_path = cache_path
82
95
  if use_cache:
83
96
  self._prepare_cache()
84
- if kpts is not None:
85
- self.kpts = kpts
86
- elif kmesh is not None:
87
- self.kpts = monkhorst_pack(kmesh, gamma_center=gamma)
88
- else:
89
- self.kpts = tbmodel.get_kpts()
90
- self.nkpts = len(self.kpts)
91
- self.kweights = np.array([1.0 / self.nkpts] * self.nkpts)
97
+ self.prepare_kpts(
98
+ kmesh=kmesh,
99
+ ibz=ibz,
100
+ gamma=gamma,
101
+ kpts=kpts,
102
+ kweights=kweights,
103
+ tbmodel=tbmodel,
104
+ )
105
+
92
106
  self.norb = tbmodel.norb
93
107
  self.nbasis = tbmodel.nbasis
94
108
  self.k_sym = k_sym
95
109
  self.nproc = nproc
96
110
  self._prepare_eigen()
97
111
 
112
+ def prepare_kpts(
113
+ self, kmesh=None, gamma=True, ibz=False, kpts=None, kweights=None, tbmodel=None
114
+ ):
115
+ """
116
+ Prepare the k-points for the calculation.
117
+
118
+ Parameters:
119
+ - kmesh (tuple): The k-mesh used to generate k-points.
120
+ - gamma (bool): Whether to include the gamma point in the k-points.
121
+ - ibz (bool): Whether to use the irreducible Brillouin zone.
122
+ - kpts (list): List of user-defined k-points.
123
+ - kweights (list): List of weights for each k-point.
124
+
125
+ Returns:
126
+ None
127
+ """
128
+ if kpts is not None:
129
+ self.kpts = kpts
130
+ self.nkpts = len(self.kpts)
131
+ self.kweights = kweights
132
+ elif kmesh is not None:
133
+ if ibz:
134
+ self.kpts, self.kweights = ir_kpts(
135
+ atoms=tbmodel.atoms,
136
+ mp_grid=kmesh,
137
+ ir=True,
138
+ is_time_reversal=False,
139
+ )
140
+ self.nkpts = len(self.kpts)
141
+ print(f"Using IBZ of kmesh of {kmesh}")
142
+ print(f"Number of kpts: {self.nkpts}")
143
+ for kpt, weight in zip(self.kpts, self.kweights):
144
+ # format the kpt and weight, use 5 digits
145
+ print(f"{kpt[0]:8.5f} {kpt[1]:8.5f} {kpt[2]:8.5f} {weight:8.5f}")
146
+ else:
147
+ self.kpts = monkhorst_pack(kmesh, gamma_center=gamma)
148
+ self.nkpts = len(self.kpts)
149
+ self.kweights = np.array([1.0 / self.nkpts] * self.nkpts)
150
+ else:
151
+ self.kpts = tbmodel.get_kpts()
152
+ self.nkpts = len(self.kpts)
153
+ self.kweights = np.array([1.0 / self.nkpts] * self.nkpts)
154
+
98
155
  def _reduce_eigens(self, evals, evecs, emin, emax):
99
156
  ts = np.logical_and(evals >= emin, evals < emax)
100
157
  ts = np.any(ts, axis=0)
@@ -106,7 +163,7 @@ class TBGreen:
106
163
  istart, iend = ts[0], ts[-1] + 1
107
164
  return evals[:, istart:iend], evecs[:, :, istart:iend]
108
165
 
109
- def find_energy_ingap(self, rbound, gap=4.0):
166
+ def find_energy_ingap(self, rbound, gap=2.0):
110
167
  return find_energy_ingap(self.evals, rbound, gap)
111
168
 
112
169
  def _prepare_cache(self):
@@ -165,7 +222,14 @@ class TBGreen:
165
222
  if self.efermi is None:
166
223
  print("Calculating Fermi energy from eigenvalues")
167
224
  print(f"Number of electrons: {self.tbmodel.nel} ")
168
- occ = Occupations(
225
+
226
+ # occ = Occupations(
227
+ # nel=self.tbmodel.nel, width=0.1, wk=self.kweights, nspin=2
228
+ # )
229
+ # self.efermi = occ.efermi(copy.deepcopy(self.evals))
230
+ # print(f"Fermi energy found: {self.efermi}")
231
+
232
+ occ = GaussOccupations(
169
233
  nel=self.tbmodel.nel, width=0.1, wk=self.kweights, nspin=2
170
234
  )
171
235
  self.efermi = occ.efermi(copy.deepcopy(self.evals))
@@ -360,7 +424,6 @@ class TBGreen:
360
424
  for iR, R in enumerate(Rpts):
361
425
  phase = np.exp(self.k2Rfactor * np.dot(R, kpt))
362
426
  GR[R] += Gkw * (phase * self.kweights[ik])
363
-
364
427
  dHRdx = dHdx.get_hamR(R)
365
428
  dGRdx[R] += Gkw @ dHRdx @ Gk
366
429
  # dGRdx[R] += Gk.dot(dHRdx).dot(Gkp)
@@ -74,6 +74,7 @@ def gen_exchange_siesta(fdf_fname, read_H_soc=False, **kwargs):
74
74
  output_path="TB2J_results",
75
75
  orb_decomposition=False,
76
76
  orth=False,
77
+ ibz=False,
77
78
  description="",
78
79
  )
79
80
  exargs.update(kwargs)
@@ -162,7 +163,7 @@ Warning: The DMI component parallel to the spin orientation, the Jani which has
162
163
  # thetas = [0, np.pi / 2, np.pi, 3 * np.pi / 2]
163
164
  # phis = [0, 0, 0, 0]
164
165
  # MAE.set_angles(thetas=thetas, phis=phis)
165
- MAE.run(output_path=f"{output_path}_anisotropy")
166
+ MAE.run(output_path=f"{output_path}_anisotropy", with_eigen=True)
166
167
  print(
167
168
  f"MAE calculation finished. The results are in {output_path} directory."
168
169
  )
TB2J/kpoints.py CHANGED
@@ -1,4 +1,7 @@
1
+ from collections import Counter
2
+
1
3
  import numpy as np
4
+ import spglib
2
5
 
3
6
 
4
7
  def monkhorst_pack(size, gamma_center=False):
@@ -12,5 +15,87 @@ def monkhorst_pack(size, gamma_center=False):
12
15
  mkpts = (kpts + 0.5) / size - 0.5
13
16
  if gamma_center:
14
17
  mkpts += shift
15
-
16
18
  return mkpts
19
+
20
+
21
+ def get_ir_kpts(atoms, mesh):
22
+ """
23
+ Gamma-centered IR kpoints. mesh : [nk1,nk2,nk3].
24
+ """
25
+ lattice = atoms.get_cell()
26
+ positions = atoms.get_scaled_positions()
27
+ numbers = atoms.get_atomic_numbers()
28
+
29
+ cell = (lattice, positions, numbers)
30
+ mapping, grid = spglib.get_ir_reciprocal_mesh(mesh, cell, is_shift=[0, 0, 0])
31
+ return grid[np.unique(mapping)] / np.array(mesh, dtype=float)
32
+
33
+
34
+ def ir_kpts(
35
+ atoms, mp_grid, is_shift=[0, 0, 0], verbose=True, ir=True, is_time_reversal=False
36
+ ):
37
+ """
38
+ generate kpoints for structure
39
+ Parameters:
40
+ ------------------
41
+ atoms: ase.Atoms
42
+ structure
43
+ mp_grid: [nk1,nk2,nk3]
44
+ is_shift: shift of k points. default is Gamma centered.
45
+ ir: bool
46
+ Irreducible or not.
47
+ """
48
+ cell = (atoms.get_cell(), atoms.get_scaled_positions(), atoms.get_atomic_numbers())
49
+ # print(spglib.get_spacegroup(cell, symprec=1e-5))
50
+ mesh = mp_grid
51
+ # Gamma centre mesh
52
+ mapping, grid = spglib.get_ir_reciprocal_mesh(
53
+ mesh, cell, is_shift=is_shift, is_time_reversal=is_time_reversal, symprec=1e-4
54
+ )
55
+ if not ir:
56
+ return (np.array(grid).astype(float) + np.asarray(is_shift) / 2.0) / mesh, [
57
+ 1.0 / len(mapping)
58
+ ] * len(mapping)
59
+ # All k-points and mapping to ir-grid points
60
+ # for i, (ir_gp_id, gp) in enumerate(zip(mapping, grid)):
61
+ # print("%3d ->%3d %s" % (i, ir_gp_id, gp.astype(float) / mesh))
62
+ cnt = Counter(mapping)
63
+ ids = list(cnt.keys())
64
+ weight = list(cnt.values())
65
+ weight = np.array(weight) * 1.0 / sum(weight)
66
+ ird_kpts = [
67
+ (grid[id].astype(float) + np.asarray(is_shift) / 2.0) / mesh for id in ids
68
+ ]
69
+
70
+ # Irreducible k-points
71
+ # print("Number of ir-kpoints: %d" % len(np.unique(mapping)))
72
+ # print(grid[np.unique(mapping)] / np.array(mesh, dtype=float))
73
+
74
+ new_ir_kpts = []
75
+ new_weight = []
76
+ for ik, k in enumerate(ird_kpts):
77
+ # add k and -k to ird_kpts if -k is not in ird_kpts
78
+ if not any([np.allclose(-1.0 * k, kpt) for kpt in new_ir_kpts]):
79
+ new_ir_kpts.append(k)
80
+ new_ir_kpts.append(-1.0 * k)
81
+ new_weight.append(weight[ik] / 2)
82
+ new_weight.append(weight[ik] / 2)
83
+ else:
84
+ new_ir_kpts.append(k)
85
+ new_weight.append(weight[ik])
86
+ # return ird_kpts, weight
87
+ return np.array(new_ir_kpts), np.array(new_weight)
88
+
89
+
90
+ def test_ir_kpts():
91
+ from ase.build import bulk
92
+
93
+ atoms = bulk("Si")
94
+ mesh = [14, 14, 14]
95
+ kpts = get_ir_kpts(atoms, mesh)
96
+ print(kpts)
97
+ print(len(kpts))
98
+
99
+
100
+ if __name__ == "__main__":
101
+ test_ir_kpts()
TB2J/mycfr.py ADDED
@@ -0,0 +1,114 @@
1
+ # -*- coding: utf-8 -*-
2
+ # File: mycfr.py
3
+ # Time: 2017/12/10 19:29:43
4
+ """
5
+ Continued fraction representation.
6
+ """
7
+
8
+ import numpy as np
9
+ from scipy.linalg import eig
10
+
11
+ kb = 8.61733e-5 # Boltzmann constant in eV
12
+
13
+
14
+ class CFR:
15
+ """
16
+ Integration with the continued fraction representation.
17
+ """
18
+
19
+ def __init__(self, nz=50, T=60):
20
+ self.nz = nz
21
+ self.T = 600
22
+ self.beta = 1 / (kb * self.T)
23
+ self.Rinf = 1e10
24
+ if nz <= 0:
25
+ raise ValueError("nz should be larger than 0.")
26
+ else:
27
+ self.prepare_poles()
28
+
29
+ def prepare_poles(self):
30
+ ##b_mat = [1 / (2.0 * np.sqrt((2 * (j + 1) - 1) * (2 * (j + 1) + 1)) / (kb * self.#T)) for j in range(0, self.nz- 1)]
31
+ jmat = np.arange(0, self.nz - 1)
32
+ b_mat = 1 / (2.0 * np.sqrt((2 * (jmat + 1) - 1) * (2 * (jmat + 1) + 1)))
33
+ b_mat = np.diag(b_mat, -1) + np.diag(b_mat, 1)
34
+ self.poles, residules = eig(b_mat)
35
+
36
+ residules = 0.25 * np.abs(residules[0, :]) ** 2 / self.poles**2
37
+ # residules = 0.25 * np.diag(residules) ** 2 / self.poles**2
38
+
39
+ # self.weights = np.where(
40
+ # #np.real(self.poles) > 0, 4.0j / self.beta * residules, 0.0
41
+ # #np.real(self.poles) > 0, 2.0j / self.beta * residules, 2.0j / self.beta * residules
42
+ # np.real(self.poles) > 0, 2.0j / self.beta * residules, 0.0
43
+ # )
44
+
45
+ # self.path = 1j / self.poles * kb * self.T
46
+
47
+ self.path = []
48
+ self.weights = []
49
+ for p, r in zip(self.poles, residules):
50
+ if p > 0:
51
+ self.path.append(1j / p * kb * self.T)
52
+ w = 2.0j / self.beta * r
53
+ self.weights.append(w)
54
+ self.path.append(-1j / p * kb * self.T)
55
+ self.weights.append(w)
56
+
57
+ self.path = np.array(self.path)
58
+ self.weights = np.array(self.weights)
59
+
60
+ # from J. Phys. Soc. Jpn. 88, 114706 (2019)
61
+ # A_mat = -1/2 *np.diag(1, -1) + np.diag(1, 1)
62
+ # B_mat = np.diag([2*i-1 for i in range(1, self.nz)])
63
+ # eigp, eigv = eig(A_mat, B_mat)
64
+ # zp = 1j / eigp * kb * self.T
65
+ # Rp = 0.25 * np.diag(eigv)**2 * zp **2
66
+
67
+ # add a point to the poles: 1e10j
68
+ self.path = np.concatenate((self.path, [self.Rinf * 1j]))
69
+ # self.path = np.concatenate((self.path, [0.0]))
70
+ self.npoles = len(self.poles)
71
+
72
+ # add weights for the point 1e10j
73
+ # self.weights = np.concatenate((self.weights, [-self.Rinf]))
74
+ self.weights = np.concatenate((self.weights, [00.0]))
75
+ # zeros moment is 1j * R * test_gf(1j * R), but the real part of it will be taken. In contrast to the other part, where the imaginary part is taken.
76
+
77
+ def integrate_values(self, gf_vals, imag=False):
78
+ ret = 0
79
+ for i in range(self.npoles + 1):
80
+ ret += self.weights[i] * gf_vals[i]
81
+ ret *= (
82
+ -np.pi / 2
83
+ ) # This is to be compatible with the integration of contour, where /-np.pi is used after the integration. And the factor of 2 is because the Fermi function here is 2-fold degenerate.
84
+ if imag:
85
+ return np.imag(ret)
86
+ return ret
87
+
88
+ def integrate_func(self, gf, ef=0):
89
+ """
90
+ Integration with the continued fraction representation.
91
+
92
+ :param gf: Green's function
93
+ :param ef: Fermi energy
94
+ :return: integration result
95
+ """
96
+ path = self.path
97
+ gf_vals = gf(path, ef=ef)
98
+ return self.integrate_values(gf_vals)
99
+
100
+
101
+ def test_cfr():
102
+ cfr = CFR(nz=100)
103
+
104
+ def test_gf(z, ef=0.1):
105
+ return 1 / (z - 3 + ef)
106
+
107
+ r = cfr.integrate_func(test_gf, ef=2)
108
+ r = -np.imag(r) / np.pi * 2
109
+ print(r)
110
+ return r
111
+
112
+
113
+ if __name__ == "__main__":
114
+ test_cfr()
TB2J/orbmap.py CHANGED
@@ -28,14 +28,14 @@ def map_orbs_matrix(orblist, spinor=False, include_only=None):
28
28
 
29
29
  norb = len(orblist)
30
30
 
31
- print("orblist: ", orblist)
31
+ # print("orblist: ", orblist)
32
32
  ss = [split_orb_name(orb) for orb in orblist]
33
33
  orbdict = dict(zip(ss, range(norb)))
34
34
 
35
35
  reduced_orbdict = defaultdict(lambda: [])
36
36
 
37
- print(f"Orbital dictionary: {orbdict}")
38
- print("include_only: ", include_only)
37
+ # print(f"Orbital dictionary: {orbdict}")
38
+ # print("include_only: ", include_only)
39
39
 
40
40
  if include_only is None:
41
41
  for key, val in orbdict.items():
@@ -46,7 +46,7 @@ def map_orbs_matrix(orblist, spinor=False, include_only=None):
46
46
  # [:2] for 3d, 4d, 5d, etc. and [:1] for s, p, d, etc
47
47
  reduced_orbdict[key[0]].append(val)
48
48
 
49
- print(f"reduced_orbdict: {reduced_orbdict}")
49
+ # print(f"reduced_orbdict: {reduced_orbdict}")
50
50
  reduced_orbs = tuple(reduced_orbdict.keys())
51
51
  ngroup = len(reduced_orbdict)
52
52
  mmat = np.zeros((norb, ngroup), dtype=int)
TB2J/symmetrize_J.py CHANGED
@@ -4,6 +4,7 @@ from pathlib import Path
4
4
  import numpy as np
5
5
  from sympair import SymmetryPairFinder
6
6
 
7
+ from TB2J.io_exchange import SpinIO
7
8
  from TB2J.versioninfo import print_license
8
9
 
9
10
 
@@ -35,6 +36,7 @@ class TB2JSymmetrizer:
35
36
  self.pgdict = finder.get_symmetry_pair_group_dict()
36
37
  self.exc = exc
37
38
  self.new_exc = copy.deepcopy(exc)
39
+ self.Jonly = Jonly
38
40
 
39
41
  def print_license(self):
40
42
  print_license()
@@ -44,8 +46,8 @@ class TB2JSymmetrizer:
44
46
  Symmetrize the exchange parameters J.
45
47
  """
46
48
  symJdict = {}
47
- Jdict = self.exc.exchange_Jdict
48
- ngroup = self.pgdict
49
+ # Jdict = self.exc.exchange_Jdict
50
+ # ngroup = self.pgdict
49
51
  for pairgroup in self.pgdict.groups:
50
52
  ijRs = pairgroup.get_all_ijR()
51
53
  ijRs_spin = [self.exc.ijR_index_atom_to_spin(*ijR) for ijR in ijRs]
@@ -56,9 +58,12 @@ class TB2JSymmetrizer:
56
58
  self.new_exc.exchange_Jdict = symJdict
57
59
  if self.Jonly:
58
60
  self.new_exc.has_dmi = False
59
- self.new_exc.dmi_dict = {}
60
- self.new_exc.has_uniaxial_anistropy = False
61
- self.new_exc.k1_dict = {}
61
+ self.new_exc.dmi_ddict = None
62
+ self.new_exc.has_bilinear = False
63
+ self.new_exc.Jani_dict = None
64
+ self.has_uniaxial_anisotropy = False
65
+ self.k1 = None
66
+ self.k1dir = None
62
67
 
63
68
  def output(self, path="TB2J_symmetrized"):
64
69
  if path is None:
@@ -89,7 +94,7 @@ def symmetrize_J(
89
94
  """
90
95
  if exc is None:
91
96
  exc = SpinIO.load_pickle(path=path, fname=fname)
92
- symmetrizer = TB2JSymmetrizer(exc, symprec=symprec)
97
+ symmetrizer = TB2JSymmetrizer(exc, symprec=symprec, Jonly=Jonly)
93
98
  symmetrizer.run(path=output_path)
94
99
 
95
100
 
@@ -130,7 +135,12 @@ def symmetrize_J_cli():
130
135
  if args.inpath is None:
131
136
  parser.print_help()
132
137
  raise ValueError("Please provide the input path to the exchange.")
133
- symmetrize_J(path=args.inpath, output_path=args.outpath, symprec=args.symprec)
138
+ symmetrize_J(
139
+ path=args.inpath,
140
+ output_path=args.outpath,
141
+ symprec=args.symprec,
142
+ Jonly=args.Jonly,
143
+ )
134
144
 
135
145
 
136
146
  if __name__ == "__main__":
TB2J/versioninfo.py CHANGED
@@ -1,6 +1,7 @@
1
- import TB2J
2
1
  from datetime import datetime
3
2
 
3
+ import TB2J
4
+
4
5
 
5
6
  def print_license():
6
7
  print(
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: TB2J
3
- Version: 0.9.9rc4
3
+ Version: 0.9.9rc6
4
4
  Summary: TB2J: First principle to Heisenberg exchange J using tight-binding Green function method
5
5
  Author: Xu He
6
6
  Author-email: mailhexu@gmail.com
@@ -1,46 +1,47 @@
1
1
  TB2J/Jdownfolder.py,sha256=Rmg6KfQ-Lkhei5daTJ2POzr0XL-R1WM-rzUnDcfoDhc,9595
2
2
  TB2J/Jtensor.py,sha256=t6OsqrSlYW6Im4H7ykVAW8Al_pFXN4C5yj2UEsV6r7g,3181
3
- TB2J/MAE.py,sha256=9VwwLpUALaaVwn4LTnhSISJMT7MDym247sSKT5Rum0o,10989
4
- TB2J/MAEGreen.py,sha256=eXzQDue54YJOHpL5OgoOutlqN69PQjoVz-Oqy2-TWOA,10731
3
+ TB2J/MAE.py,sha256=fM8U-Dgp9HcQOEeC_kyZV1oVrygBvcux9BraUXVouvY,10994
4
+ TB2J/MAEGreen.py,sha256=MoLoE5fLpbp1knAP_oU-egHr0jnpTQpqD9FgoVtDkgk,12322
5
5
  TB2J/Oiju.py,sha256=cNGv8N5uH_swGq7cnAt2OyiDfqtjLlLrwseGu0E4iaM,3383
6
6
  TB2J/Oiju_epc.py,sha256=oytM3NYW7nWmklrGgNlqwIpI_JYv_hb7ZnR4o9nYNog,6809
7
7
  TB2J/__init__.py,sha256=hcEWkag_UvLm1ZSbjsgcTWkGVlR3Bwmzg1QYAwsvf-g,24
8
8
  TB2J/anisotropy.py,sha256=zz4ID6_Yjf5gxPJt1psc6liNKhTG8X5AtHdpq0dCEzM,22616
9
9
  TB2J/basis.py,sha256=DFo6_QUwjBwisP6zGxvoO0lpGTMDPAOkiL9giNCjOjA,1558
10
10
  TB2J/citation.py,sha256=gcQeyJZaT1Qrtsl8Y3s4neOH3-vvgmIcCvXeV2o3vj0,2891
11
- TB2J/contour.py,sha256=4wFZSPV81WwuUrvn1MENMnP-cW5ICDy8azOdTO8HJdw,2877
11
+ TB2J/contour.py,sha256=zLHQZZ3hhgLkLFPATCraLOJyLJKLC0fba_L_5sRz23o,3246
12
12
  TB2J/density_matrix.py,sha256=D5k8Oe21OCiLVORNYbo4TZOFG0slrQSbj91kJ3TMFjs,1514
13
13
  TB2J/epc.py,sha256=zLbtqZJhDr8DnnGN6YENcXwrMb3Qxu6KB08mLy9Pw20,3474
14
- TB2J/exchange.py,sha256=TEX8xagcn2DIbygC7C39LD7nvpYp996GcOcLFBBun4U,25830
15
- TB2J/exchangeCL2.py,sha256=vJgVBpvtTE2K7Xf7hGQNc3C87VvVXTa689Qd5827ItE,11165
16
- TB2J/exchange_params.py,sha256=hKz78yxU1RTXntmGArY94jfNrYJn-C4irHn0RfBXu0k,6908
14
+ TB2J/exchange.py,sha256=1kkrrQvmoOaPgT_rKG7wgLy31rWpbFGNYXai1ysd58M,26221
15
+ TB2J/exchangeCL2.py,sha256=P7bklMXVYX_tn9DbjEPqeTir1SeZyfPBIP1fhWUzLmY,11419
16
+ TB2J/exchange_params.py,sha256=AcGYYky27DXSF3yDZWVjksr_3rt6im6qeIzpOwvqssk,7141
17
17
  TB2J/exchange_pert.py,sha256=jmFMtQbYa_uczM4VAeS6TijkIHRFIqEzZJswzE9Wfuo,8523
18
18
  TB2J/exchange_qspace.py,sha256=ZL68qBGFUaQ9BsSPsJaaoWOr9RssPiqX34R_9I3nk_8,8436
19
19
  TB2J/gpaw_wrapper.py,sha256=aJ--9Dtyq7jOP1Hkh-Sh1nWcfXm6zKcljOCO0DNCAr0,6890
20
- TB2J/green.py,sha256=Dz189KtGsHlANBU4TiSTZpxGEpETFZaphwyIaNp3a5E,14721
20
+ TB2J/green.py,sha256=ySXjoV3Cj_E2C41dRfc3TkS7M4vmM6qcHXkt-_-jxsY,17071
21
21
  TB2J/greentest.py,sha256=2ISSfhor9ecSEOi_E6b4Cv26wEIQlwlzca0ru8z44_E,1603
22
22
  TB2J/io_merge.py,sha256=E1_GfAB2HGpW-ipaO2lqU9SvaslwkiLxssn4DqJpMT8,6899
23
- TB2J/kpoints.py,sha256=6XK2KqTncidEq3o9GuO6VEZRPNTRtWeXg9QfcV-9smI,532
23
+ TB2J/kpoints.py,sha256=9L7tBarFBHoIhpuc9zuwA6HdnlgH834SQrPek4yRoWk,3191
24
24
  TB2J/myTB.py,sha256=ok_B4my29bOIghMSZfx0Es6G8FaXaIiLP4gPxTdSj00,17659
25
- TB2J/orbmap.py,sha256=g5Lhp6UkDZ7-1T9k0oO43gb2O7j2aGVKMdUeM3QdNAY,7186
25
+ TB2J/mycfr.py,sha256=Wgj6PpA-oVuxm8Hh32FVw_vthozVBrDJhRV1hA1ku44,3752
26
+ TB2J/orbmap.py,sha256=XLQjKMxCy2eADaM5eb2F_zG08V7lzpXJxp5uEtTeVYI,7194
26
27
  TB2J/pauli.py,sha256=ESpAhk6LG5ugzuW1YFUTqiDxcg-pQ7wNnzR2FtUnvKM,5295
27
28
  TB2J/pert.py,sha256=RaCJfewl0doht4cjAnzzGKe-uj2le4aqe0iPKFrq9fo,1192
28
29
  TB2J/plot.py,sha256=AnFIFWE2vlmj7Z6f_7-dX_O1stJN-qbuiurPj43dUCM,4104
29
30
  TB2J/rotate_atoms.py,sha256=Dwptn-wdDW4zYzjYb95yxTzuZOe9WPuLjh3d3-YcSs0,3277
30
31
  TB2J/rotate_siestaDM.py,sha256=eR97rspdrRaK9YTwQwUKfobI0S9UnEcbEZ2f5IgR7Tk,1070
31
32
  TB2J/sisl_wrapper.py,sha256=A5x1-tt8efUSPeGY5wM5m6-pJYQFXTCzQHVqD6RBa2g,14792
32
- TB2J/symmetrize_J.py,sha256=6ahB65d9UwbmQDvGR_4V7Cx-1Au1ElBOheYFQRlGRvk,4247
33
+ TB2J/symmetrize_J.py,sha256=IypvLL0JxExq-cmqc4o0nLL8psE7OC9ijj9YMcsqJeA,4487
33
34
  TB2J/tensor_rotate.py,sha256=4-DfT_Mg5e40fbd74M5W0D5DqmUq-kVOOLDkkkI834A,8083
34
35
  TB2J/utest.py,sha256=z_ahi7tpHQF9WlHNQihcQ7qzfezRJQXQt28eB1X_z64,3897
35
36
  TB2J/utils.py,sha256=DHkc7BK0KUGesfoAv1OxMgIw_iZzcFXh--3ybsFSd_c,12535
36
- TB2J/versioninfo.py,sha256=wZwS9QDFRVDe7rf8JyPDDI8UGdTQiO6Pb_sWv8GAegA,337
37
+ TB2J/versioninfo.py,sha256=atoCpy6lEcGTCC3xahrxEJjoHgoYVtL41Q_3Ryvp76I,338
37
38
  TB2J/external/__init__.py,sha256=yD_ZIMi76H49rj6GAQpiB7UlKa3TgSaMkkLHT6M-8w8,137
38
39
  TB2J/external/p_tqdm.py,sha256=ug1jy3-43r8iW7bC37xzPSIe0EjYKH_GUluGzMiQiDw,5831
39
40
  TB2J/interfaces/__init__.py,sha256=4tiLoXQ73Nlyi9L4j8jJXOYzXluVNPxQZkwfkQZEGHg,307
40
41
  TB2J/interfaces/gpaw_interface.py,sha256=GCDlJ-hRWfChvWwsgBDYSmVqO4sH9HAuGZTV9GqgN6c,1504
41
42
  TB2J/interfaces/lawaf_interface.py,sha256=PieLnmppdafOYsgeHznqOou1g9L1sam5jOm3KaObdqo,4408
42
43
  TB2J/interfaces/manager.py,sha256=PQMLEfMCT5GnDWSl2nI4JOgRPm_fysyR-6Y6l97xWcw,860
43
- TB2J/interfaces/siesta_interface.py,sha256=rpDDePtL4zFaS8FGHrIruPawxy78JbIZ4TUQoInIu5g,7296
44
+ TB2J/interfaces/siesta_interface.py,sha256=C9dMmFAc8HlCGFJeHLn0nUvOJA1rhVYIFIz8udMdJjE,7332
44
45
  TB2J/interfaces/wannier90_interface.py,sha256=qzRgXUBb7t1Aiegrl_RV51BB8csdtVM0EP0Z4pjmTcs,4467
45
46
  TB2J/interfaces/abacus/__init__.py,sha256=leas71oCvM_HxrF4gnO5A_VKcJmDAgsI1BUctLU3OBw,177
46
47
  TB2J/interfaces/abacus/abacus_api.py,sha256=lNV4LNkLcKw7Zux4MQYM9wnh3eFTlcSqbf4Pb7pqhrk,7243
@@ -76,19 +77,19 @@ TB2J/spinham/supercell.py,sha256=y17uUC6r3gQb278FhxIW4CABihfLTvKFj6flyXrCPR8,122
76
77
  TB2J/wannier/__init__.py,sha256=7ojCbM84PYv1X1Tbo4NHI-d3gWmQsZB_xiYqbfxVV1E,80
77
78
  TB2J/wannier/w90_parser.py,sha256=dbd63LuKyv2DVUzqRINGsbDzEsOxsQyE8_Ear_LQIRg,4620
78
79
  TB2J/wannier/w90_tb_parser.py,sha256=qt8pnuprmPp9iIAYwPkPbmEzk6ZPgMq2xognoQp7vwc,4610
79
- TB2J-0.9.9rc4.data/scripts/TB2J_downfold.py,sha256=i4BVqnpDdgrX_amookVWeLGefGBn-qeAutWiwuY9SfQ,2099
80
- TB2J-0.9.9rc4.data/scripts/TB2J_eigen.py,sha256=Qs9v2hnMm2Tpfoa4h53muUKty2dZjwx8948MBoQooNg,1128
81
- TB2J-0.9.9rc4.data/scripts/TB2J_magnon.py,sha256=q7UwAmorRcFNk4tfE7gl_ny05l6p7pbD9Wm_LkIpKEw,3101
82
- TB2J-0.9.9rc4.data/scripts/TB2J_magnon_dos.py,sha256=TMXQvD2dIbO5FZ4tUMmxJgCgH2O2hDAPUNfEKO4z-x4,110
83
- TB2J-0.9.9rc4.data/scripts/TB2J_merge.py,sha256=y834SF4rIRn1L1ptkhczvavQpC-8Px6DTmDOOSaq_DE,1854
84
- TB2J-0.9.9rc4.data/scripts/TB2J_rotate.py,sha256=zgiDFuYZNmzKK0rwDmTaYD2OpRlmKA_VGeBx83w2Xwc,873
85
- TB2J-0.9.9rc4.data/scripts/TB2J_rotateDM.py,sha256=kCvF7gotuqAX1VnJ06cwfVm7RrhrdtiV5v7d9P2Pn_E,567
86
- TB2J-0.9.9rc4.data/scripts/abacus2J.py,sha256=0HLXoJhAkiZ-ZM1cs26lncccxE8-TzC8JiDTba1h1uM,4163
87
- TB2J-0.9.9rc4.data/scripts/siesta2J.py,sha256=gp31LioqpPkDmMY0y_5gXIjOBPNnf080P37pRo0yjw8,4886
88
- TB2J-0.9.9rc4.data/scripts/wann2J.py,sha256=pTFDf6h72I_LN_NX5UivyCoJPgwvyAyHW175nSAJvLo,2987
89
- TB2J-0.9.9rc4.dist-info/LICENSE,sha256=CbZI-jyRTjiqIcWa244cRSHJdjjtUNqGR4HeJkgEwJw,1332
90
- TB2J-0.9.9rc4.dist-info/METADATA,sha256=PHff7nqo8ab-J2HQ8BSg5QuHXgV4c2CsPceDxa6f5Qk,1482
91
- TB2J-0.9.9rc4.dist-info/WHEEL,sha256=cVxcB9AmuTcXqmwrtPhNK88dr7IR_b6qagTj0UvIEbY,91
92
- TB2J-0.9.9rc4.dist-info/entry_points.txt,sha256=Hdz1WC9waUzyFVmowKnbbZ6j-J4adHh_Ko6JpxGYAtE,131
93
- TB2J-0.9.9rc4.dist-info/top_level.txt,sha256=whYa5ByLYhl5XnTPBHSWr-IGD6VWmr5Ql2bye2qwV_s,5
94
- TB2J-0.9.9rc4.dist-info/RECORD,,
80
+ TB2J-0.9.9rc6.data/scripts/TB2J_downfold.py,sha256=i4BVqnpDdgrX_amookVWeLGefGBn-qeAutWiwuY9SfQ,2099
81
+ TB2J-0.9.9rc6.data/scripts/TB2J_eigen.py,sha256=Qs9v2hnMm2Tpfoa4h53muUKty2dZjwx8948MBoQooNg,1128
82
+ TB2J-0.9.9rc6.data/scripts/TB2J_magnon.py,sha256=q7UwAmorRcFNk4tfE7gl_ny05l6p7pbD9Wm_LkIpKEw,3101
83
+ TB2J-0.9.9rc6.data/scripts/TB2J_magnon_dos.py,sha256=TMXQvD2dIbO5FZ4tUMmxJgCgH2O2hDAPUNfEKO4z-x4,110
84
+ TB2J-0.9.9rc6.data/scripts/TB2J_merge.py,sha256=y834SF4rIRn1L1ptkhczvavQpC-8Px6DTmDOOSaq_DE,1854
85
+ TB2J-0.9.9rc6.data/scripts/TB2J_rotate.py,sha256=zgiDFuYZNmzKK0rwDmTaYD2OpRlmKA_VGeBx83w2Xwc,873
86
+ TB2J-0.9.9rc6.data/scripts/TB2J_rotateDM.py,sha256=kCvF7gotuqAX1VnJ06cwfVm7RrhrdtiV5v7d9P2Pn_E,567
87
+ TB2J-0.9.9rc6.data/scripts/abacus2J.py,sha256=0HLXoJhAkiZ-ZM1cs26lncccxE8-TzC8JiDTba1h1uM,4163
88
+ TB2J-0.9.9rc6.data/scripts/siesta2J.py,sha256=gp31LioqpPkDmMY0y_5gXIjOBPNnf080P37pRo0yjw8,4886
89
+ TB2J-0.9.9rc6.data/scripts/wann2J.py,sha256=pTFDf6h72I_LN_NX5UivyCoJPgwvyAyHW175nSAJvLo,2987
90
+ TB2J-0.9.9rc6.dist-info/LICENSE,sha256=CbZI-jyRTjiqIcWa244cRSHJdjjtUNqGR4HeJkgEwJw,1332
91
+ TB2J-0.9.9rc6.dist-info/METADATA,sha256=liNOEG_iKPUW6hOrcu08SqCBqzeEd3RxGRt3_YxBh2M,1482
92
+ TB2J-0.9.9rc6.dist-info/WHEEL,sha256=GV9aMThwP_4oNCtvEC2ec3qUYutgWeAzklro_0m4WJQ,91
93
+ TB2J-0.9.9rc6.dist-info/entry_points.txt,sha256=Hdz1WC9waUzyFVmowKnbbZ6j-J4adHh_Ko6JpxGYAtE,131
94
+ TB2J-0.9.9rc6.dist-info/top_level.txt,sha256=whYa5ByLYhl5XnTPBHSWr-IGD6VWmr5Ql2bye2qwV_s,5
95
+ TB2J-0.9.9rc6.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (74.1.2)
2
+ Generator: setuptools (75.1.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5