3
0
mirror of https://github.com/triqs/dft_tools synced 2024-08-28 23:12:02 +02:00

Fixed the output of band indices to vasp.pgX

The band indices should be converted to Fortran convention,
i.e. starting from 1, in the output files because the are
used in the density matrix file which is read by a Fortran code.
This commit is contained in:
Oleg E. Peil 2015-12-04 19:55:37 +01:00
parent 85a83db1cb
commit b02d13ebd8

View File

@ -310,7 +310,8 @@ def plo_output(conf_pars, el_struct, pshells, pgroups):
f.write("# is = %i\n"%(isp + 1))
for ik in xrange(nk):
ib1, ib2 = pgroup.ib_win[ik, isp, 0], pgroup.ib_win[ik, isp, 1]
f.write(" %i %i\n"%(ib1, ib2))
# Output band indices in Fortran convention!
f.write(" %i %i\n"%(ib1 + 1, ib2 + 1))
for ib in xrange(ib1, ib2 + 1):
eigv_ef = el_struct.eigvals[ik, ib, isp] - el_struct.efermi
f_weight = el_struct.ferw[isp, ik, ib]