TB2J 0.9.9rc12__tar.gz → 0.9.9rc14__tar.gz

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 (221) hide show
  1. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/PKG-INFO +2 -3
  2. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/exchange.py +65 -83
  3. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/exchange_params.py +0 -19
  4. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/io_exchange/io_exchange.py +2 -5
  5. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/rotate_atoms.py +3 -3
  6. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/rotate_siestaDM.py +9 -11
  7. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J.egg-info/PKG-INFO +2 -3
  8. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J.egg-info/SOURCES.txt +0 -2
  9. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J.egg-info/requires.txt +1 -2
  10. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/conf.py +0 -6
  11. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/Contributors.rst +1 -1
  12. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/ReleaseNotes.md +1 -3
  13. tb2j-0.9.9rc14/docs/src/parameters.rst +28 -0
  14. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/requirements.txt +0 -1
  15. tb2j-0.9.9rc14/scripts/abacus2J.py +146 -0
  16. tb2j-0.9.9rc14/scripts/siesta2J.py +163 -0
  17. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/scripts/wann2J.py +0 -1
  18. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/setup.py +2 -3
  19. tb2j-0.9.9rc12/docs/_static/Logo-ULG.png +0 -0
  20. tb2j-0.9.9rc12/docs/_static/logo_TB2J_horizon.png +0 -0
  21. tb2j-0.9.9rc12/docs/src/parameters.rst +0 -89
  22. tb2j-0.9.9rc12/scripts/abacus2J.py +0 -58
  23. tb2j-0.9.9rc12/scripts/siesta2J.py +0 -74
  24. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/.github/workflows/pylint.yml.bak +0 -0
  25. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/.github/workflows/python-app.yml +0 -0
  26. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/.gitignore +0 -0
  27. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/.pre-commit-config.yaml +0 -0
  28. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/.readthedocs.yml +0 -0
  29. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/.ruff.toml +0 -0
  30. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/.travis.yml +0 -0
  31. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/LICENSE +0 -0
  32. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/README.md +0 -0
  33. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/.gitignore +0 -0
  34. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/Jdownfolder.py +0 -0
  35. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/Jtensor.py +0 -0
  36. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/MAE.py +0 -0
  37. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/MAEGreen.py +0 -0
  38. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/Oiju.py +0 -0
  39. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/Oiju_epc.py +0 -0
  40. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/__init__.py +0 -0
  41. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/anisotropy.py +0 -0
  42. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/basis.py +0 -0
  43. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/citation.py +0 -0
  44. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/contour.py +0 -0
  45. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/density_matrix.py +0 -0
  46. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/epc.py +0 -0
  47. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/exchangeCL2.py +0 -0
  48. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/exchange_pert.py +0 -0
  49. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/exchange_qspace.py +0 -0
  50. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/external/__init__.py +0 -0
  51. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/external/p_tqdm.py +0 -0
  52. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/gpaw_wrapper.py +0 -0
  53. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/green.py +0 -0
  54. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/greentest.py +0 -0
  55. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/__init__.py +0 -0
  56. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/abacus/.gitignore +0 -0
  57. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/abacus/__init__.py +0 -0
  58. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/abacus/abacus_api.py +0 -0
  59. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/abacus/abacus_wrapper.py +0 -0
  60. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/abacus/gen_exchange_abacus.py +0 -0
  61. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/abacus/orbital_api.py +0 -0
  62. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/abacus/stru_api.py +0 -0
  63. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/abacus/test_density_matrix.py +0 -0
  64. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/abacus/test_read_HRSR.py +0 -0
  65. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/abacus/test_read_stru.py +0 -0
  66. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/gpaw_interface.py +0 -0
  67. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/lawaf_interface.py +0 -0
  68. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/manager.py +0 -0
  69. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/siesta_interface.py +0 -0
  70. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/interfaces/wannier90_interface.py +0 -0
  71. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/io_exchange/__init__.py +0 -0
  72. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/io_exchange/io_multibinit.py +0 -0
  73. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/io_exchange/io_tomsasd.py +0 -0
  74. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/io_exchange/io_txt.py +0 -0
  75. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/io_exchange/io_uppasd.py +0 -0
  76. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/io_exchange/io_vampire.py +0 -0
  77. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/io_merge.py +0 -0
  78. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/kpoints.py +0 -0
  79. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/mathutils/__init__.py +0 -0
  80. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/mathutils/fermi.py +0 -0
  81. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/mathutils/fibonacci_sphere.py +0 -0
  82. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/mathutils/kR_convert.py +0 -0
  83. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/mathutils/lowdin.py +0 -0
  84. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/mathutils/rotate_spin.py +0 -0
  85. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/myTB.py +0 -0
  86. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/mycfr.py +0 -0
  87. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/orbital_magmom.py +0 -0
  88. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/orbmap.py +0 -0
  89. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/pauli.py +0 -0
  90. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/pert.py +0 -0
  91. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/plot.py +0 -0
  92. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/sisl_wrapper.py +0 -0
  93. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/spinham/__init__.py +0 -0
  94. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/spinham/base_parser.py +0 -0
  95. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/spinham/constants.py +0 -0
  96. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/spinham/hamiltonian.py +0 -0
  97. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/spinham/hamiltonian_terms.py +0 -0
  98. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/spinham/plot.py +0 -0
  99. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/spinham/qsolver.py +0 -0
  100. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/spinham/spin_api.py +0 -0
  101. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/spinham/spin_xml.py +0 -0
  102. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/spinham/supercell.py +0 -0
  103. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/symmetrize_J.py +0 -0
  104. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/tensor_rotate.py +0 -0
  105. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/thetaphi.py +0 -0
  106. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/utest.py +0 -0
  107. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/utils.py +0 -0
  108. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/versioninfo.py +0 -0
  109. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/wannier/__init__.py +0 -0
  110. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/wannier/w90_parser.py +0 -0
  111. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J/wannier/w90_tb_parser.py +0 -0
  112. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J.egg-info/dependency_links.txt +0 -0
  113. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J.egg-info/entry_points.txt +0 -0
  114. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/TB2J.egg-info/top_level.txt +0 -0
  115. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/buildimage.sh +0 -0
  116. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/Makefile +0 -0
  117. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/index.rst +0 -0
  118. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/make.bat +0 -0
  119. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/requirements.txt +0 -0
  120. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/BFOvarT.png +0 -0
  121. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/SrMnO3_DOS.png +0 -0
  122. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/abacus.md +0 -0
  123. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/applications.rst +0 -0
  124. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/convention.rst +0 -0
  125. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/development.md +0 -0
  126. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/downfold.md +0 -0
  127. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/ecosystem.md +0 -0
  128. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/eigen.rst +0 -0
  129. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/extend.rst +0 -0
  130. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/faq.rst +0 -0
  131. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/install.rst +0 -0
  132. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/mae.md +0 -0
  133. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/magnon_band.assets/exchange_magnon-1593690872101.png +0 -0
  134. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/magnon_band.assets/exchange_magnon.png +0 -0
  135. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/magnon_band.assets/magnon_dos.png +0 -0
  136. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/magnon_band.rst +0 -0
  137. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/multibinit.rst +0 -0
  138. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/openmx.rst +0 -0
  139. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/orbital_contribution.md +0 -0
  140. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/output.rst +0 -0
  141. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/references.rst +0 -0
  142. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/roadmap.md +0 -0
  143. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/rotate_and_merge.rst +0 -0
  144. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/siesta.rst +0 -0
  145. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/spin_model_assets/canting_DMI.png +0 -0
  146. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/spin_model_assets/tmulti5_2.png +0 -0
  147. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/symmetry.md +0 -0
  148. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/tutorial.rst +0 -0
  149. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/docs/src/wannier.rst +0 -0
  150. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/Fe.1.psml +0 -0
  151. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/EigenJq.txt +0 -0
  152. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/Multibinit/exchange.xml +0 -0
  153. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/Multibinit/exchange_kpth.txt +0 -0
  154. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/Multibinit/exchange_magnon.png +0 -0
  155. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/Multibinit/magnon.py +0 -0
  156. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/Multibinit/magnon_band.json +0 -0
  157. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/Multibinit/magnon_band.pdf +0 -0
  158. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/Multibinit/magnon_dos.png +0 -0
  159. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/Multibinit/magnon_dos.txt +0 -0
  160. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/Multibinit/mb.files +0 -0
  161. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/Multibinit/mb.in +0 -0
  162. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/Multibinit/plot.sh +0 -0
  163. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/Multibinit/plot_magnon_dos.sh +0 -0
  164. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/Multibinit/plot_magnon_from_json_file.py +0 -0
  165. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/TB2J.pickle +0 -0
  166. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/TomASD/exchange.exch +0 -0
  167. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/TomASD/exchange.ucf +0 -0
  168. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/TB2J_results/exchange.out +0 -0
  169. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/getJ.sh +0 -0
  170. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/run.sh +0 -0
  171. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/BccFe/siesta.fdf +0 -0
  172. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/Co.1.psml +0 -0
  173. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/TB2J_results/Multibinit/exchange.xml +0 -0
  174. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/TB2J_results/Multibinit/mb.files +0 -0
  175. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/TB2J_results/Multibinit/mb.in +0 -0
  176. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/TB2J_results/TB2J.pickle +0 -0
  177. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/TB2J_results/TomASD/exchange.exch +0 -0
  178. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/TB2J_results/TomASD/exchange.ucf +0 -0
  179. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/TB2J_results/Vampire/input +0 -0
  180. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/TB2J_results/Vampire/vampire.UCF +0 -0
  181. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/TB2J_results/Vampire/vampire.mat +0 -0
  182. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/TB2J_results/exchange.out +0 -0
  183. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/TB2J_results/summary.txt +0 -0
  184. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/getJ.sh +0 -0
  185. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/run.sh +0 -0
  186. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/Siesta/HcpCo/siesta.fdf +0 -0
  187. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/TB2J_results/JvsR.pdf +0 -0
  188. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/TB2J_results/Multibinit/exchange.xml +0 -0
  189. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/TB2J_results/Multibinit/mb.files +0 -0
  190. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/TB2J_results/Multibinit/mb.in +0 -0
  191. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/TB2J_results/TB2J.pickle +0 -0
  192. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/TB2J_results/TomASD/exchange.exch +0 -0
  193. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/TB2J_results/TomASD/exchange.ucf +0 -0
  194. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/TB2J_results/Vampire/input +0 -0
  195. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/TB2J_results/Vampire/vampire.UCF +0 -0
  196. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/TB2J_results/Vampire/vampire.mat +0 -0
  197. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/TB2J_results/assigned_basis.txt +0 -0
  198. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/TB2J_results/exchange.out +0 -0
  199. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/TB2J_results/exchange_orb_decomposition.out +0 -0
  200. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/abinit.files +0 -0
  201. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/abinit.in +0 -0
  202. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/abinito_w90_down.win +0 -0
  203. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/abinito_w90_down_centres.xyz +0 -0
  204. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/abinito_w90_down_hr.dat +0 -0
  205. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/abinito_w90_up.win +0 -0
  206. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/abinito_w90_up_centres.xyz +0 -0
  207. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/abinito_w90_up_hr.dat +0 -0
  208. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/get_J.sh +0 -0
  209. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/psp/Mn.GGA-PBESOL-JTH.xml +0 -0
  210. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/psp/O.GGA-PBESOL-JTH.xml +0 -0
  211. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/psp/Sr.GGA-PBESOL-JTH.xml +0 -0
  212. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/examples/abinit-w90/SrMnO3/run.sh +0 -0
  213. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/scripts/TB2J_downfold.py +0 -0
  214. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/scripts/TB2J_eigen.py +0 -0
  215. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/scripts/TB2J_magnon.py +0 -0
  216. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/scripts/TB2J_magnon_dos.py +0 -0
  217. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/scripts/TB2J_merge.py +0 -0
  218. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/scripts/TB2J_rotate.py +0 -0
  219. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/scripts/TB2J_rotateDM.py +0 -0
  220. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/setup.cfg +0 -0
  221. {tb2j-0.9.9rc12 → tb2j-0.9.9rc14}/upload_to_pip.sh +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: TB2J
3
- Version: 0.9.9rc12
3
+ Version: 0.9.9rc14
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
@@ -21,10 +21,9 @@ Requires-Dist: ase>=3.19
21
21
  Requires-Dist: tqdm
22
22
  Requires-Dist: pathos
23
23
  Requires-Dist: packaging>=20.0
24
- Requires-Dist: HamiltonIO>=0.1.10
24
+ Requires-Dist: HamiltonIO>=0.2.1
25
25
  Requires-Dist: pre-commit
26
26
  Requires-Dist: sympair>0.1.0
27
- Requires-Dist: sisl>=0.9.0
28
27
  Dynamic: author
29
28
  Dynamic: author-email
30
29
  Dynamic: classifier
@@ -1,6 +1,6 @@
1
1
  import os
2
2
  import pickle
3
- from collections import defaultdict
3
+ from collections import OrderedDict, defaultdict
4
4
 
5
5
  import numpy as np
6
6
  from tqdm import tqdm
@@ -96,96 +96,78 @@ class Exchange(ExchangeParams):
96
96
 
97
97
  def _prepare_orb_dict(self):
98
98
  """
99
- Generate orbital and magnetic atom mappings needed for exchange calculations.
100
-
101
- Creates:
102
- - self.orb_dict: Maps atom indices to their orbital indices
103
- - self.labels: Maps atom indices to their orbital labels
104
- - self.ind_mag_atoms: List of indices of magnetic atoms
105
- - self._spin_dict: Maps atom indices to spin indices
106
- - self._atom_dict: Maps spin indices back to atom indices
107
- """
108
- self._create_orbital_mappings()
109
- self._identify_magnetic_atoms()
110
- self._validate_orbital_assignments()
111
- self._create_spin_mappings()
112
- self._prepare_orb_mmat()
113
-
114
- def _create_orbital_mappings(self):
115
- """Create mappings between atoms and their orbitals."""
116
- self.orb_dict = {} # {atom_index: [orbital_indices]}
117
- self.labels = {} # {atom_index: [orbital_labels]}
118
- atom_symbols = symbol_number(self.atoms)
119
-
120
- for orb_idx, base in enumerate(self.basis):
121
- if orb_idx in self.exclude_orbs:
122
- continue
99
+ generate self.ind_mag_atoms and self.orb_dict
100
+ """
101
+ # adict: dictionary of {'Fe': ['dxy', 'dyz', ...], ...}
102
+ adict = OrderedDict()
103
+ # orb_dict: {ind_atom:[ind_orb,1,2], ...}
104
+ self.orb_dict = {}
105
+ # labels: {0:{dxy, ...}}
106
+ self.labels = {}
107
+ # magnetic atoms index
108
+ self.ind_mag_atoms = []
109
+
110
+ sdict = symbol_number(self.atoms)
111
+
112
+ for i, base in enumerate(self.basis):
113
+ if i not in self.exclude_orbs:
114
+ # e.g. Fe2, dxy, _, _
115
+ if isinstance(base, str):
116
+ atom_sym, orb_sym = base.split("|")[:2]
117
+ iatom = sdict[atom_sym]
118
+ else:
119
+ try:
120
+ atom_sym, orb_sym = base[:2]
121
+ iatom = sdict[atom_sym]
122
+ except Exception:
123
+ iatom = base.iatom
124
+ atom_sym = base.iatom
125
+ orb_sym = base.sym
126
+
127
+ if atom_sym in adict:
128
+ adict[atom_sym].append(orb_sym)
129
+ else:
130
+ adict[atom_sym] = [orb_sym]
131
+ if iatom not in self.orb_dict:
132
+ self.orb_dict[iatom] = [i]
133
+ self.labels[iatom] = [orb_sym]
134
+ else:
135
+ self.orb_dict[iatom] += [i]
136
+ self.labels[iatom] += [orb_sym]
123
137
 
124
- # Extract atom and orbital info
125
- if isinstance(base, str):
126
- atom_sym, orb_sym = base.split("|")[:2]
127
- atom_idx = atom_symbols[atom_sym]
128
- else:
129
- try:
130
- atom_sym, orb_sym = base[:2]
131
- atom_idx = atom_symbols[atom_sym]
132
- except Exception:
133
- atom_idx = base.iatom
134
- atom_sym = base.iatom
135
- orb_sym = base.sym
136
-
137
- # Update orbital mappings
138
- if atom_idx not in self.orb_dict:
139
- self.orb_dict[atom_idx] = [orb_idx]
140
- self.labels[atom_idx] = [orb_sym]
141
- else:
142
- self.orb_dict[atom_idx].append(orb_idx)
143
- self.labels[atom_idx].append(orb_sym)
138
+ # index of magnetic atoms
139
+ symbols = self.atoms.get_chemical_symbols()
140
+ tags = self.atoms.get_tags()
141
+ for i, (sym, tag) in enumerate(zip(symbols, tags)):
142
+ if sym in self.magnetic_elements or f"{sym}{tag}" in self.magnetic_elements:
143
+ self.ind_mag_atoms.append(i)
144
144
 
145
- def _identify_magnetic_atoms(self):
146
- """Identify which atoms are magnetic based on elements/tags."""
147
- if self.index_magnetic_atoms is not None:
148
- self.ind_mag_atoms = self.index_magnetic_atoms
149
- else:
150
- self.ind_mag_atoms = []
151
- symbols = self.atoms.get_chemical_symbols()
152
- tags = self.atoms.get_tags()
153
-
154
- for atom_idx, (sym, tag) in enumerate(zip(symbols, tags)):
155
- if (
156
- sym in self.magnetic_elements
157
- or f"{sym}{tag}" in self.magnetic_elements
158
- ):
159
- self.ind_mag_atoms.append(atom_idx)
160
- print(f"Magnetic atoms: {self.ind_mag_atoms}")
161
-
162
- def _validate_orbital_assignments(self):
163
- """Validate that magnetic atoms have proper orbital assignments."""
164
- # Check all magnetic atoms have orbitals
165
- for atom_idx in self.ind_mag_atoms:
166
- if atom_idx not in self.orb_dict:
145
+ # sanity check to see if some magnetic atom has no orbital.
146
+ for iatom in self.ind_mag_atoms:
147
+ if iatom not in self.orb_dict:
167
148
  raise ValueError(
168
- f"Atom {atom_idx} is magnetic but has no orbitals assigned. "
169
- "Check Wannier function definitions."
149
+ f"""Cannot find any orbital for atom {iatom}, which is supposed to be magnetic. Please check the Wannier functions."""
170
150
  )
171
-
172
- # For non-collinear case, check spin-orbital pairing
173
151
  if not self._is_collinear:
174
- for atom_idx, orbitals in self.orb_dict.items():
175
- if len(orbitals) % 2 != 0:
152
+ for iatom, orb in self.orb_dict.items():
153
+ # print(f"iatom: {iatom}, orb: {orb}")
154
+ nsorb = len(self.orb_dict[iatom])
155
+ if nsorb % 2 != 0 and False:
176
156
  raise ValueError(
177
- f"Atom {atom_idx} has {len(orbitals)} spin-orbitals "
178
- "(should be even). Check Wannier function localization."
157
+ f"""The number of spin-orbitals for atom {iatom} is not even,
158
+ {nsorb} spin-orbitals are found near this atom.
159
+ which means the spin up/down does not have same number of orbitals.
160
+ This is often because the Wannier functions are wrongly defined,
161
+ or badly localized. Please check the Wannier centers in the Wannier90 output file.
162
+ """
179
163
  )
164
+ self._spin_dict = {}
165
+ self._atom_dict = {}
166
+ for ispin, iatom in enumerate(self.ind_mag_atoms):
167
+ self._spin_dict[iatom] = ispin
168
+ self._atom_dict[ispin] = iatom
180
169
 
181
- def _create_spin_mappings(self):
182
- """Create mappings between atom indices and spin indices."""
183
- self._spin_dict = {} # {atom_index: spin_index}
184
- self._atom_dict = {} # {spin_index: atom_index}
185
-
186
- for spin_idx, atom_idx in enumerate(self.ind_mag_atoms):
187
- self._spin_dict[atom_idx] = spin_idx
188
- self._atom_dict[spin_idx] = atom_idx
170
+ self._prepare_orb_mmat()
189
171
 
190
172
  def _prepare_orb_mmat(self):
191
173
  self.mmats = {}
@@ -15,7 +15,6 @@ class ExchangeParams:
15
15
  efermi: float
16
16
  basis = []
17
17
  magnetic_elements = []
18
- index_magnetic_atoms = None
19
18
  include_orbs = {}
20
19
  _kmesh = [4, 4, 4]
21
20
  emin: float = -15
@@ -56,7 +55,6 @@ class ExchangeParams:
56
55
  mae_angles=None,
57
56
  orth=False,
58
57
  ibz=False,
59
- index_magnetic_atoms=None,
60
58
  ):
61
59
  self.efermi = efermi
62
60
  self.basis = basis
@@ -81,7 +79,6 @@ class ExchangeParams:
81
79
  self.mae_angles = mae_angles
82
80
  self.orth = orth
83
81
  self.ibz = ibz
84
- self.index_magnetic_atoms = index_magnetic_atoms
85
82
 
86
83
  def set_params(self, **kwargs):
87
84
  for key, val in kwargs.items():
@@ -232,21 +229,6 @@ def add_exchange_args_to_parser(parser: argparse.ArgumentParser):
232
229
  default=False,
233
230
  )
234
231
 
235
- parser.add_argument(
236
- "--mae_angles",
237
- help="angles for computing MAE, default is 0 0 0",
238
- type=float,
239
- nargs="*",
240
- default=[0.0, 0.0, 0.0],
241
- )
242
- parser.add_argument(
243
- "--index_magnetic_atoms",
244
- help="index of magnetic atoms in the unit cell, default is None. If specified, this will be used to determine the atoms to be considered as magnetic atoms, instead of determined from magnetic elements. Note that the index starts from 1 ",
245
- type=int,
246
- nargs="*",
247
- default=None,
248
- )
249
-
250
232
  return parser
251
233
 
252
234
 
@@ -268,5 +250,4 @@ def parser_argument_to_dict(args) -> dict:
268
250
  "orb_decomposition": args.orb_decomposition,
269
251
  "output_path": args.output_path,
270
252
  "orth": args.orth,
271
- "index_magnetic_atoms": args.index_magnetic_atoms,
272
253
  }
@@ -8,16 +8,13 @@ write not only xml output.
8
8
  - tom's asd inputs.
9
9
  """
10
10
 
11
+ # matplotlib.use("Agg")
12
+ import gc
11
13
  import os
12
14
  import pickle
13
15
  from collections.abc import Iterable
14
16
  from datetime import datetime
15
17
 
16
- import matplotlib
17
-
18
- matplotlib.use("Agg")
19
- import gc
20
-
21
18
  import matplotlib.pyplot as plt
22
19
  import numpy as np
23
20
 
@@ -15,7 +15,6 @@ def rotate_atom_xyz(atoms, noncollinear=False):
15
15
  will be generated.
16
16
  """
17
17
 
18
- yield atoms
19
18
  rotation_axes = [(1, 0, 0), (0, 1, 0)]
20
19
  if noncollinear:
21
20
  rotation_axes += [(1, 1, 0), (1, 0, 1), (0, 1, 1)]
@@ -24,7 +23,6 @@ def rotate_atom_xyz(atoms, noncollinear=False):
24
23
  rotated_atoms = copy.deepcopy(atoms)
25
24
  rotated_atoms.rotate(90, axis, rotate_cell=True)
26
25
  yield rotated_atoms
27
- yield atoms
28
26
 
29
27
 
30
28
  def rotate_atom_spin_one_rotation(atoms, Rotation):
@@ -111,5 +109,7 @@ def rotate_xyz(fname, ftype="xyz", noncollinear=False):
111
109
  rotated = rotate_atom_xyz(atoms, noncollinear=noncollinear)
112
110
 
113
111
  for i, rotated_atoms in enumerate(rotated):
114
- write(f"atoms_{i}.{ftype}", rotated_atoms)
112
+ write(f"atoms_{i+1}.{ftype}", rotated_atoms)
113
+ write(f"atoms_0.{ftype}", atoms)
114
+
115
115
  print(f"The output has been written to the atoms_i.{ftype} files. atoms_0.{ftype} contains the reference structure.")
@@ -1,28 +1,28 @@
1
1
  import sisl
2
2
 
3
-
4
3
  def rotate_siesta_DM(DM, noncollinear=False):
5
- angles_list = [[0.0, 90.0, 0.0], [0.0, 90.0, 90.0]]
4
+
5
+ angles_list = [ [0.0, 90.0, 0.0], [0.0, 90.0, 90.0] ]
6
6
  if noncollinear:
7
7
  angles_list += [[0.0, 45.0, 0.0], [0.0, 90.0, 45.0], [0.0, 45.0, 90.0]]
8
8
 
9
9
  for angles in angles_list:
10
10
  yield DM.spin_rotate(angles)
11
11
 
12
-
13
12
  def read_label(fdf_fname):
14
- label = "siesta"
15
- with open(fdf_fname, "r") as File:
13
+
14
+ label = 'siesta'
15
+ with open(fdf_fname, 'r') as File:
16
16
  for line in File:
17
- corrected_line = line.lower().replace(".", "").replace("-", "")
18
- if "systemlabel" in corrected_line:
17
+ corrected_line = line.lower().replace('.', '').replace('-', '')
18
+ if 'systemlabel' in corrected_line:
19
19
  label = line.split()[1]
20
20
  break
21
21
 
22
22
  return label
23
23
 
24
-
25
24
  def rotate_DM(fdf_fname, noncollinear=False):
25
+
26
26
  fdf = sisl.get_sile(fdf_fname)
27
27
  DM = fdf.read_density_matrix()
28
28
  label = read_label(fdf_fname)
@@ -33,6 +33,4 @@ def rotate_DM(fdf_fname, noncollinear=False):
33
33
  rotated_DM.write(f"{label}_{i+1}.DM")
34
34
  DM.write(f"{label}_0.DM")
35
35
 
36
- print(
37
- f"The output has been written to the {label}_i.DM files. {label}_0.DM contains the reference density matrix."
38
- )
36
+ print(f"The output has been written to the {label}_i.DM files. {label}_0.DM contains the reference density matrix.")
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: TB2J
3
- Version: 0.9.9rc12
3
+ Version: 0.9.9rc14
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
@@ -21,10 +21,9 @@ Requires-Dist: ase>=3.19
21
21
  Requires-Dist: tqdm
22
22
  Requires-Dist: pathos
23
23
  Requires-Dist: packaging>=20.0
24
- Requires-Dist: HamiltonIO>=0.1.10
24
+ Requires-Dist: HamiltonIO>=0.2.1
25
25
  Requires-Dist: pre-commit
26
26
  Requires-Dist: sympair>0.1.0
27
- Requires-Dist: sisl>=0.9.0
28
27
  Dynamic: author
29
28
  Dynamic: author-email
30
29
  Dynamic: classifier
@@ -106,8 +106,6 @@ docs/conf.py
106
106
  docs/index.rst
107
107
  docs/make.bat
108
108
  docs/requirements.txt
109
- docs/_static/Logo-ULG.png
110
- docs/_static/logo_TB2J_horizon.png
111
109
  docs/src/BFOvarT.png
112
110
  docs/src/Contributors.rst
113
111
  docs/src/ReleaseNotes.md
@@ -5,7 +5,6 @@ ase>=3.19
5
5
  tqdm
6
6
  pathos
7
7
  packaging>=20.0
8
- HamiltonIO>=0.1.10
8
+ HamiltonIO>=0.2.1
9
9
  pre-commit
10
10
  sympair>0.1.0
11
- sisl>=0.9.0
@@ -59,9 +59,3 @@ html_theme = "sphinx_rtd_theme"
59
59
  # relative to this directory. They are copied after the builtin static files,
60
60
  # so a file named "default.css" will overwrite the builtin "default.css".
61
61
  html_static_path = ["_static"]
62
-
63
- html_logo = "_static/TB2J_logo_horizon.png"
64
- html_theme_options = {
65
- "logo_only": True,
66
- "display_version": False,
67
- }
@@ -1,7 +1,7 @@
1
1
  Contributors
2
2
  ============
3
3
 
4
- The TB2J package is initially developed:
4
+ The TB2J package is initially developped:
5
5
 
6
6
  * Xu He (mailhexu@gmail.com)
7
7
 
@@ -11,9 +11,7 @@ This currently requires an non-official SIESTA branch which can seperate the spi
11
11
 
12
12
  - An improved method of the downfolding method which implements the ligand correction to the exchange based on the Wannier function method. This requires the updated version of LaWaF (https://github.com/mailhexu/lawaf) and the updated version of the TB2J\_downfold.py script.
13
13
 
14
- - Added a new parameter (--index_magnetic_atoms) to the wann2J.py, siesta2J.py, and abacus2J.py scripts, so that a more detailed selection of the magnetic atoms than the one in --element is possible. This is useful when we need to select a subset of a specific element in a system.
15
-
16
- - There is a major refactoring of the interface to the DFT codes. The parsing of the electron Hamiltonian from the DFT codes are now in a separate python package called HamiltonIO (github.com/mailhexu/HamiltonIO). This package is used by TB2J but is made general to be used with other packages too.
14
+ - There is a major refractoring of the interface to the DFT codes. The parsing of the electron Hamiltonian from the DFT codes are now in a separate python package called HamiltonIO (github.com/mailhexu/HamiltonIO). This package is used by TB2J but is made general to be used with other packages too.
17
15
 
18
16
 
19
17
  #### v0.11.0 October 10, 2024
@@ -0,0 +1,28 @@
1
+ Parameters in calculation of magnetic interaction parameters
2
+ =============================================================
3
+
4
+ List of parameters:
5
+ -------------------------------
6
+ The list of parameter can be found using:
7
+
8
+ ::
9
+
10
+ wann2J.py --help
11
+
12
+ or
13
+
14
+ ::
15
+
16
+ siesta2J.py --help
17
+
18
+ The parameter will be explained in the following text.
19
+
20
+ * kmesh: Three integers to specify the size of a Monkhorst-Pack mesh. This is the mesh of k-points used to calculate the Green's functions. The real space supercell in which the magnetic interactions are calculated, has the same size as the k-mesh. For example, a :math:`7 \times 7 \times` k-mesh is linked with a :math:`7 \times 7 \times` supercell, the atom :math:`i` resides in the center cell, whereas the :math:`j` atom can be in all the cells in the supercell.
21
+
22
+ * efermi: The Fermi energy in eV. For insulators, it can be inside the gap. For metals, it should be the same as in the DFT calculation. Due to the different algorithms in the integration of the density, the Fermi energy could be slightly shifted from the DFT value.
23
+
24
+ * emin, emax, and nz: During the calculation, there is a integration :math:`\int_{emin}^{emax} d\epsilon` calculation. The emin and emax are relative values to the Fermi energy. The emax should be 0. The emin should be low enough so that all the electronic states that affect the magnetic interactions are integrated. This can be checked with the local density of the states. Below the emin, the spin up and down density of states should be almost identical. The nz is the number of steps in this integration. The emax can be used to adjust the integration if we want to simulate the effect of the charge doping. This is with the approximation that there is only a rigid shift of the band structure. However, it is recommended to dope charge within the DFT then this approximation is not needed. The emax parameter will thus be deprecated soon.
25
+
26
+ * rcut: rcut is the cutoff distance between two ion pairs between which the magnetic interaction parameters are calculated. By default, all the pairs inside the supercell defined by the kmesh
27
+
28
+ * exclude_orbs: the indeces of orbitals, whose contribution will not be counted in the magnetic interaction. It is a list of integers. The indices are zero based.
@@ -7,5 +7,4 @@ tqdm>=4.42.0
7
7
  pathos
8
8
  packaging>=20.0
9
9
  sympair>=0.1.0
10
- sisl>=0.9.0
11
10
  pre-commit
@@ -0,0 +1,146 @@
1
+ #!/usr/bin/env python3
2
+ import argparse
3
+ import sys
4
+
5
+ from TB2J.interfaces import gen_exchange_abacus
6
+ from TB2J.versioninfo import print_license
7
+
8
+
9
+ def run_abacus2J():
10
+ print_license()
11
+ parser = argparse.ArgumentParser(
12
+ description="abacus2J: Using magnetic force theorem to calculate exchange parameter J from abacus Hamiltonian in the LCAO mode"
13
+ )
14
+
15
+ parser.add_argument(
16
+ "--path", help="the path of the abacus calculation", default="./", type=str
17
+ )
18
+
19
+ parser.add_argument(
20
+ "--suffix",
21
+ help="the label of the abacus calculation. There should be an output directory called OUT.suffix",
22
+ default="abacus",
23
+ type=str,
24
+ )
25
+
26
+ parser.add_argument(
27
+ "--elements",
28
+ help="list of elements to be considered in Heisenberg model.",
29
+ # , For each element, a postfixes can be used to specify the orbitals(Only with Siesta backend), eg. Fe_3d, or Fe_3d_4s ",
30
+ default=None,
31
+ type=str,
32
+ nargs="*",
33
+ )
34
+ parser.add_argument(
35
+ "--rcut",
36
+ help="range of R. The default is all the commesurate R to the kmesh",
37
+ default=None,
38
+ type=float,
39
+ )
40
+ parser.add_argument(
41
+ "--efermi", help="Fermi energy in eV. For test only. ", default=None, type=float
42
+ )
43
+ parser.add_argument(
44
+ "--kmesh",
45
+ help="kmesh in the format of kx ky kz. Monkhorst pack. If all the numbers are odd, it is Gamma cenetered. (strongly recommended), Default: 5 5 5",
46
+ type=int,
47
+ nargs="*",
48
+ default=[5, 5, 5],
49
+ )
50
+ parser.add_argument(
51
+ "--emin",
52
+ help="energy minimum below efermi, default -14 eV",
53
+ type=float,
54
+ default=-14.0,
55
+ )
56
+
57
+ parser.add_argument(
58
+ "--use_cache",
59
+ help="whether to use disk file for temporary storing wavefunctions and hamiltonian to reduce memory usage. Default: False",
60
+ action="store_true",
61
+ default=False,
62
+ )
63
+
64
+ parser.add_argument(
65
+ "--nz", help="number of integration steps. Default: 50", default=50, type=int
66
+ )
67
+
68
+ parser.add_argument(
69
+ "--cutoff",
70
+ help="The minimum of J amplitude to write, (in eV). Default: 1e-7 eV",
71
+ default=1e-7,
72
+ type=float,
73
+ )
74
+
75
+ parser.add_argument(
76
+ "--exclude_orbs",
77
+ help="the indices of wannier functions to be excluded from magnetic site. counting start from 0. Default is none.",
78
+ default=[],
79
+ type=int,
80
+ nargs="+",
81
+ )
82
+
83
+ parser.add_argument(
84
+ "--nproc",
85
+ "--np",
86
+ help="number of cpu cores to use in parallel, default: 1",
87
+ default=1,
88
+ type=int,
89
+ )
90
+
91
+ parser.add_argument(
92
+ "--description",
93
+ help="add description of the calculatiion to the xml file. Essential information, like the xc functional, U values, magnetic state should be given.",
94
+ type=str,
95
+ default="Calculated with TB2J.",
96
+ )
97
+
98
+ parser.add_argument(
99
+ "--orb_decomposition",
100
+ default=False,
101
+ action="store_true",
102
+ help="whether to do orbital decomposition in the non-collinear mode. Default: False.",
103
+ )
104
+
105
+ parser.add_argument(
106
+ "--fname",
107
+ default="exchange.xml",
108
+ type=str,
109
+ help="exchange xml file name. default: exchange.xml",
110
+ )
111
+
112
+ parser.add_argument(
113
+ "--output_path",
114
+ help="The path of the output directory, default is TB2J_results",
115
+ type=str,
116
+ default="TB2J_results",
117
+ )
118
+
119
+ args = parser.parse_args()
120
+
121
+ if args.elements is None:
122
+ print("Please input the magnetic elements, e.g. --elements Fe Ni")
123
+ sys.exit()
124
+
125
+ # include_orbs = {}
126
+
127
+ gen_exchange_abacus(
128
+ path=args.path,
129
+ suffix=args.suffix,
130
+ kmesh=args.kmesh,
131
+ magnetic_elements=args.elements,
132
+ include_orbs={},
133
+ Rcut=args.rcut,
134
+ emin=args.emin,
135
+ nz=args.nz,
136
+ description=args.description,
137
+ output_path=args.output_path,
138
+ use_cache=args.use_cache,
139
+ nproc=args.nproc,
140
+ exclude_orbs=args.exclude_orbs,
141
+ orb_decomposition=args.orb_decomposition,
142
+ )
143
+
144
+
145
+ if __name__ == "__main__":
146
+ run_abacus2J()