PEXSI DOS energy range error
Summary:
When using PEXSI to calculate the DOS, the energy range can't be set by using PEXSI.DOS.Emin and PEXSI.DOS.Emax.
Code version:
siesta-4.1-b3 PEXSI: 0.9.2
System information:
Ubuntu 19.10 gcc 9.2.1 (Ubuntu 9.2.1-9ubuntu2)
Steps to reproduce:
I just use the example input file in the ~/Obj/Tests/sih-pexsi.fdf. It works fine if I just type make, and it will produce correct INTDOS file. However, if I add PEXSI.DOS.Emin -1 Ry, or PEXSI.DOS.Emax 1 Ry, or both to the fdf file, the output INTDOS will only show the total states at energy=fermi energy + 1Ry. Therefore, I think there might be some bugs in PEXSI.DOS.Emin(max)
By the way, the second column of INTDOS is *.00 type, but the ~/Util/PEXSI/intdos2eig.f90 requires it to be integer type.
Expected behavior
Relevant logs and/or screenshots
Correct output:
-3.552821 257.000000 200 1# (Ef, qtot, npoints, nspin) / npoints lines: E(eV), IntDos(E)
-17.158621 2.00
-17.021879 2.00
-16.885138 2.00
-16.748396 2.00
-16.611654 2.00
-16.474913 2.00
-16.338171 2.00
-16.201429 2.00
-16.064687 2.00
-15.927946 4.00
-15.791204 4.00
-15.654462 4.00
-15.517721 4.00
-15.380979 4.00
-15.244237 4.00
-15.107495 14.00
Incorrect output after adding PEXSI.DOS.Emin -1 Ry or PEXSI.DOS.Emax 1 Ry or both
-3.552821 257.000000 200 1# (Ef, qtot, npoints, nspin) / npoints lines: E(eV), IntDos(E)
10.052979 716.00
10.052979 716.00
10.052979 716.00
10.052979 716.00
10.052979 716.00
10.052979 716.00
10.052979 716.00
10.052979 716.00
10.052979 716.00 ......
Possible fixes