From e7cddf3e7e320ab855c2c1d946ab7393ed289391 Mon Sep 17 00:00:00 2001 From: Hermann Schnait Date: Thu, 18 Jul 2019 11:59:50 +0200 Subject: [PATCH] Bugfix in calculate_diagonalization_matrix for more than one deg shell --- python/block_structure.py | 1 - python/sumk_dft.py | 6 ++++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/python/block_structure.py b/python/block_structure.py index fca33d5d..5739482c 100644 --- a/python/block_structure.py +++ b/python/block_structure.py @@ -726,7 +726,6 @@ class BlockStructure(object): return self._check_gf_or_matrix(G, ish, space) def _check_gf_or_matrix(self, G, ish=None, space='solver'): - if space == 'solver': gf_struct = self.gf_struct_solver elif space == 'sumk': diff --git a/python/sumk_dft.py b/python/sumk_dft.py index 69d95640..7408cce2 100644 --- a/python/sumk_dft.py +++ b/python/sumk_dft.py @@ -1401,8 +1401,10 @@ class SumkDFT(object): if write_to_blockstructure: if self.block_structure.transformation == None: self.block_structure.transformation = [{} for icrsh in range(self.n_corr_shells)] - for sp in self.spin_block_names[self.corr_shells[icrsh]['SO']]: - self.block_structure.transformation[icrsh][sp] = numpy.eye(self.corr_shells[icrsh]['dim'], self.corr_shells[icrsh]['dim'], numpy.complex_) + for icrsh in range(self. n_corr_shells): + for sp in self.spin_block_names[self.corr_shells[icrsh]['SO']]: + self.block_structure.transformation[icrsh][sp] = numpy.eye(self.corr_shells[icrsh]['dim'], dtype=numpy.complex_) + self.block_structure.transformation[ish] = trafo