quant-met 0.0.24__py3-none-any.whl → 0.0.26__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.
- quant_met/mean_field/hamiltonians/base_hamiltonian.py +9 -11
- quant_met/mean_field/hamiltonians/dressed_graphene.py +3 -7
- quant_met/mean_field/search_crit_temp.py +9 -7
- {quant_met-0.0.24.dist-info → quant_met-0.0.26.dist-info}/METADATA +1 -1
- {quant_met-0.0.24.dist-info → quant_met-0.0.26.dist-info}/RECORD +8 -8
- {quant_met-0.0.24.dist-info → quant_met-0.0.26.dist-info}/WHEEL +0 -0
- {quant_met-0.0.24.dist-info → quant_met-0.0.26.dist-info}/entry_points.txt +0 -0
- {quant_met-0.0.24.dist-info → quant_met-0.0.26.dist-info}/licenses/LICENSE.txt +0 -0
@@ -390,18 +390,16 @@ class BaseHamiltonian(Generic[GenericParameters], ABC):
|
|
390
390
|
New pairing gap in orbital basis, adjusted to remove global phase.
|
391
391
|
"""
|
392
392
|
number_of_bands = len(delta)
|
393
|
-
|
394
|
-
result_matrix = np.zeros((2 * number_of_bands, 2 * number_of_bands), dtype=np.complex128)
|
395
|
-
for k_index in range(len(k)):
|
396
|
-
nf = np.eye(2 * number_of_bands, 2 * number_of_bands, dtype=np.complex128) * (
|
397
|
-
fermi_dirac(bdg_energies[k_index], beta)
|
398
|
-
)
|
399
|
-
result_matrix += bdg_wavefunctions[k_index].conj().T @ nf @ bdg_wavefunctions[k_index]
|
400
|
-
|
401
393
|
for i in range(number_of_bands):
|
402
|
-
|
403
|
-
|
404
|
-
|
394
|
+
sum_tmp = 0
|
395
|
+
for j in range(2 * number_of_bands):
|
396
|
+
for k_index in range(len(k)):
|
397
|
+
sum_tmp += (
|
398
|
+
np.conjugate(bdg_wavefunctions[k_index, i, j])
|
399
|
+
* bdg_wavefunctions[k_index, i + number_of_bands, j]
|
400
|
+
* fermi_dirac(bdg_energies[k_index, j].item(), beta)
|
401
|
+
)
|
402
|
+
delta[i] = (-hubbard_int_orbital_basis[i] * sum_tmp / len(k)).conjugate()
|
405
403
|
|
406
404
|
delta_without_phase: npt.NDArray[np.complexfloating] = delta * np.exp(
|
407
405
|
-1j * np.angle(delta[np.argmax(np.abs(delta))])
|
@@ -48,13 +48,9 @@ class DressedGraphene(BaseHamiltonian[DressedGrapheneParameters]):
|
|
48
48
|
|
49
49
|
h = np.zeros((k.shape[0], self.number_of_bands, self.number_of_bands), dtype=np.complex128)
|
50
50
|
|
51
|
-
h[:, 0, 1] = (
|
52
|
-
|
53
|
-
* np.exp(
|
54
|
-
* (
|
55
|
-
np.exp(1j * k[:, 1] * a / np.sqrt(3))
|
56
|
-
+ 2 * np.exp(-0.5j * a / np.sqrt(3) * k[:, 1]) * (np.cos(0.5 * a * k[:, 0]))
|
57
|
-
)
|
51
|
+
h[:, 0, 1] = -t_gr * (
|
52
|
+
np.exp(1j * k[:, 1] * a / np.sqrt(3))
|
53
|
+
+ 2 * np.exp(-0.5j * a / np.sqrt(3) * k[:, 1]) * (np.cos(0.5 * a * k[:, 0]))
|
58
54
|
)
|
59
55
|
|
60
56
|
h[:, 1, 0] = h[:, 0, 1].conjugate()
|
@@ -40,27 +40,28 @@ def _get_bounds(
|
|
40
40
|
while (found_zero_gap and found_nonzero_gap) is False and iterations < 100:
|
41
41
|
logger.info("Trying temperature: %s", temp)
|
42
42
|
data_dict = gap_for_temp_partial(temp)
|
43
|
+
logger.info("Result: %s", data_dict)
|
43
44
|
if data_dict is not None:
|
44
45
|
delta_vs_temp_list.append(data_dict)
|
45
46
|
gap = np.array([data_dict[key] for key in data_dict if key.startswith("delta")])
|
46
|
-
if np.allclose(gap, 0):
|
47
|
+
if np.allclose(gap, 0, rtol=0, atol=0.10 * np.max(np.abs(zero_temperature_gap))):
|
47
48
|
logger.info("Found temperature with zero gap.")
|
48
49
|
zero_gap_temp = temp
|
49
50
|
found_zero_gap = True
|
50
51
|
temp = 0.5 * temp
|
51
|
-
elif np.allclose(
|
52
|
+
elif np.allclose(
|
53
|
+
gap, zero_temperature_gap, atol=0.10 * np.max(np.abs(zero_temperature_gap))
|
54
|
+
):
|
52
55
|
logger.info("Found temperature with nonzero gap.")
|
53
56
|
nonzero_gap_temp = temp
|
54
57
|
found_nonzero_gap = True
|
55
58
|
temp = 2 * temp
|
56
59
|
elif direction == "down":
|
57
|
-
logger.info(
|
58
|
-
"Gap is neither zero nor equal to the nonzero gap. Reducing temperature."
|
59
|
-
)
|
60
|
+
logger.info("Gap is neither zero nor equal to the zero gap. Reducing temperature.")
|
60
61
|
temp = 0.5 * temp
|
61
62
|
else:
|
62
63
|
logger.info(
|
63
|
-
"Gap is neither zero nor equal to the
|
64
|
+
"Gap is neither zero nor equal to the zero gap. Increasing temperature."
|
64
65
|
)
|
65
66
|
temp = 2 * temp
|
66
67
|
elif direction == "down":
|
@@ -164,7 +165,7 @@ def search_crit_temp(
|
|
164
165
|
) -> tuple[pd.DataFrame, list[float], matplotlib.figure.Figure]: # pragma: no cover
|
165
166
|
"""Search for critical temperature."""
|
166
167
|
logger.info("Start search for bounds for T_C")
|
167
|
-
temp = 1 / h.beta if not np.isinf(h.beta) else
|
168
|
+
temp = 1 / h.beta if not np.isinf(h.beta) else 10 * h.hubbard_int_orbital_basis[0]
|
168
169
|
|
169
170
|
delta_vs_temp_list = []
|
170
171
|
critical_temp_list = []
|
@@ -176,6 +177,7 @@ def search_crit_temp(
|
|
176
177
|
logger.info("Calculating zero temperature gap")
|
177
178
|
data_dict = gap_for_temp_partial(0)
|
178
179
|
assert data_dict is not None
|
180
|
+
logger.info("Result: %s", data_dict)
|
179
181
|
|
180
182
|
zero_temperature_gap = np.array(
|
181
183
|
[data_dict[key] for key in data_dict if key.startswith("delta")]
|
@@ -16,11 +16,11 @@ quant_met/geometry/graphene.py,sha256=ZLE55wV1E-jRCkGxW66pca2y5VWaNtMmXiXi-HB6bg
|
|
16
16
|
quant_met/geometry/square.py,sha256=17XZH79lK9TeeDtXiBBa8rd2d9kv5yt2S9F6te0YZPU,1565
|
17
17
|
quant_met/mean_field/__init__.py,sha256=Unweog9Tst1NxUMQ4X1OYiUQtyxI2ho-OQoCaekoMFk,597
|
18
18
|
quant_met/mean_field/_utils.py,sha256=7hr0DDSdIqjft5Jjluvbw_HGoNLWgYJTxyuPJJvhBnc,356
|
19
|
-
quant_met/mean_field/search_crit_temp.py,sha256
|
19
|
+
quant_met/mean_field/search_crit_temp.py,sha256=-A1ZegUOQXxh_SwmQeqMZCptnSLWuxDJsjdZK9XK-zE,8917
|
20
20
|
quant_met/mean_field/self_consistency.py,sha256=YY_zhCurxOK3RLkK-Hglfkx33uhsvqpoAKOP4FuPdfo,3371
|
21
21
|
quant_met/mean_field/hamiltonians/__init__.py,sha256=r-8TaLqRnRbAro-TMIyxzCCZHwVqyKrausODpQJb2tw,681
|
22
|
-
quant_met/mean_field/hamiltonians/base_hamiltonian.py,sha256=
|
23
|
-
quant_met/mean_field/hamiltonians/dressed_graphene.py,sha256=
|
22
|
+
quant_met/mean_field/hamiltonians/base_hamiltonian.py,sha256=0qRfSpiE5jybv4GmBGmuNKFl1fkE4fzXG15II1IyIu8,29374
|
23
|
+
quant_met/mean_field/hamiltonians/dressed_graphene.py,sha256=Q5LiA3rgK88ZZV1V7JflgjlkEpve7uNZFzFCIoQND-w,4048
|
24
24
|
quant_met/mean_field/hamiltonians/graphene.py,sha256=sa3H8jVq9Fkc_qcz5gJTCMgN8YD3N18JWLRBImhLyxo,3276
|
25
25
|
quant_met/mean_field/hamiltonians/one_band_tight_binding.py,sha256=DZXaD95yWv1VZSMqgxkqEZv3PGihNGy7PuqupnN75ew,2512
|
26
26
|
quant_met/mean_field/hamiltonians/three_band_tight_binding.py,sha256=g8XNImzCn_6CRYKDYI6sy3q6_TBYUDxDmQZ-AqenXTE,3295
|
@@ -30,8 +30,8 @@ quant_met/parameters/hamiltonians.py,sha256=PiWVV-miCdT4Z9GWloDVvIU_1QpRHHV-zVOg
|
|
30
30
|
quant_met/parameters/main.py,sha256=QP7Z24-QePMcy6txujqxbx5ztQTdC67m6elNsJtGtXQ,2325
|
31
31
|
quant_met/plotting/__init__.py,sha256=IDgV6juJ0VfcJHppD-vnPH6w8wVuAC35eSeLxKzqyBc,523
|
32
32
|
quant_met/plotting/plotting.py,sha256=4ZYclWJH3hlE8S7b7bL_JJlP3CKaCGcVzdIsqolCAaM,6592
|
33
|
-
quant_met-0.0.
|
34
|
-
quant_met-0.0.
|
35
|
-
quant_met-0.0.
|
36
|
-
quant_met-0.0.
|
37
|
-
quant_met-0.0.
|
33
|
+
quant_met-0.0.26.dist-info/METADATA,sha256=rYIEO8Po6rucwi13B3pfOyZJgP4mso81gOfjYJYuosk,1978
|
34
|
+
quant_met-0.0.26.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
35
|
+
quant_met-0.0.26.dist-info/entry_points.txt,sha256=1Al3Kt-cMeQxwMp84ZSNL0qFwlbOVBu1o8A19MH8lEU,48
|
36
|
+
quant_met-0.0.26.dist-info/licenses/LICENSE.txt,sha256=QO_duPQihSJlaxSLxPAXo52X3esROP5wBkhxqBd1Z4E,1104
|
37
|
+
quant_met-0.0.26.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|