3
0
mirror of https://github.com/triqs/dft_tools synced 2024-12-21 11:53:41 +01:00

Fixed a bug in 'debug_density_matrix()'

The on-site blocks of the large (for all orbitals) desnity matrix
were incorrectly copied for the output.
This commit is contained in:
Oleg E. Peil 2015-11-10 12:07:13 +01:00
parent cb745fff9f
commit fa420924af

View File

@ -109,8 +109,9 @@ class ElectronicStructure:
dm = np.zeros((norb, norb))
ov = np.zeros((norb, norb))
for ind, iorb in iorb_inds:
dm[iorb, :] = den_mat[ispin, ind, :]
ov[iorb, :] = overlap[ispin, ind, :]
for ind2, iorb2 in iorb_inds:
dm[iorb, iorb2] = den_mat[ispin, ind, ind2]
ov[iorb, iorb2] = overlap[ispin, ind, ind2]
print " Density matrix" + (12*norb - 12)*" " + "Overlap"
for drow, dov in zip(dm, ov):