diff --git a/pyerrors/correlators.py b/pyerrors/correlators.py index d4d6206e..54da64f8 100644 --- a/pyerrors/correlators.py +++ b/pyerrors/correlators.py @@ -602,7 +602,7 @@ class Corr: if variant == 'log': newcontent = [] for t in range(self.T - 1): - if (self.content[t] is None) or (self.content[t + 1] is None): + if ((self.content[t] is None) or (self.content[t + 1] is None)) or (self.content[t + 1][0].value == 0): newcontent.append(None) else: newcontent.append(self.content[t] / self.content[t + 1]) @@ -622,7 +622,7 @@ class Corr: newcontent = [] for t in range(self.T - 1): - if (self.content[t] is None) or (self.content[t + 1] is None): + if (self.content[t] is None) or (self.content[t + 1] is None) or (self.content[t + 1][0].value == 0): newcontent.append(None) # Fill the two timeslices in the middle of the lattice with their predecessors elif variant == 'sinh' and t in [self.T / 2, self.T / 2 - 1]: @@ -637,7 +637,7 @@ class Corr: elif variant == 'arccosh': newcontent = [] for t in range(1, self.T - 1): - if (self.content[t] is None) or (self.content[t + 1] is None) or (self.content[t - 1] is None): + if (self.content[t] is None) or (self.content[t + 1] is None) or (self.content[t - 1] is None) or (self.content[t + 1][0].value == 0) or (self.content[t - 1][0].value == 0): newcontent.append(None) else: newcontent.append((self.content[t + 1] + self.content[t - 1]) / (2 * self.content[t]))