3
0
mirror of https://github.com/triqs/dft_tools synced 2024-12-23 04:43:42 +01:00

Reworked Diagonalization function to ignore 'picked out' obitals (e.g. egs)

This commit is contained in:
Hermann Schnait 2019-06-18 16:35:25 +02:00
parent 6623a39739
commit a44f3d36f4

View File

@ -78,10 +78,15 @@ class TransBasis:
if calc_in_solver_blocks:
trafo = self.SK.block_structure.transformation
self.SK.block_structre.transform = None
prop_solver = self.SK.block_structre.convert_matrix(prop, space_from='sumk', space_to='solver')
prop = self.SK.block_structre.convert_matrix(prop_solver, space_from='solver', space_to='sumk')
self.SK.block_structre.transform = trafo
self.SK.block_structure.transform = None
prop_solver = self.SK.block_structure.convert_matrix(prop, space_from='sumk', space_to='solver')
v= []
for name in prop_solver:
v[name] = numpy.linalg.eigh(prop_solver[name])[1]
self.w = self.SK.block_structure.convert_matrix(v, space_from='solver', space_to='sumk')['ud' if self.SK.SO else 'up']
self.T = numpy.dot(self.T.transpose().conjugate(),
self.w).conjugate().transpose()
self.SK.block_structure.transform = trafo
if self.SK.SO == 0:
self.eig, self.w = numpy.linalg.eigh(prop['up'])