mirror of
https://github.com/fjosw/pyerrors.git
synced 2025-03-15 14:50:25 +01:00
Corr.roll method implemented
This commit is contained in:
parent
f24529eb0a
commit
f2b8a9580b
1 changed files with 5 additions and 1 deletions
|
@ -151,7 +151,6 @@ class Corr:
|
|||
return Corr(newcontent)
|
||||
|
||||
|
||||
|
||||
#This method will symmetrice the matrices and therefore make them positive definit.
|
||||
def smearing_symmetric(self):
|
||||
if self.N > 1:
|
||||
|
@ -176,6 +175,11 @@ class Corr:
|
|||
sp_vec = sp_vec/np.sqrt(sp_vec@sp_vec)
|
||||
return sp_vec
|
||||
|
||||
|
||||
def roll(self, dt):
|
||||
return Corr(list(np.roll(np.array(self.content, dtype=object), dt)))
|
||||
|
||||
|
||||
def deriv(self, symmetric=True): #Defaults to symmetric derivative
|
||||
if not symmetric:
|
||||
newcontent = []
|
||||
|
|
Loading…
Add table
Reference in a new issue