1
0
mirror of https://github.com/paboyle/Grid.git synced 2025-04-07 04:35:56 +01:00

Fix phase convention adjustment error (and make no assumptions about node layout)

This commit is contained in:
Michael Marshall 2019-12-04 09:59:58 +00:00
parent 188e12ffbb
commit 15119eaf03

@ -90,7 +90,6 @@ inline void MakeLowerDimGrid( std::unique_ptr<GridCartesian> &up, GridCartesian
/*************************************************************************************
Rotate eigenvectors into our phase convention
First component of first eigenvector is real and positive
TODO: Should this be in Distil.hpp?
*************************************************************************************/
inline void RotateEigen(std::vector<LatticeColourVector> & evec)
@ -113,12 +112,9 @@ inline void RotateEigen(std::vector<LatticeColourVector> & evec)
for( int k = 0 ; k < evec.size() ; k++ )
evec[k] *= phase;
// Get rid of the rounding error in imaginary phase on the very first site
if(grid->IsBoss())
{
peekSite(cv0, evec[0], siteFirst);
cv0()()(0).imag(0); // this should be zero after the phase multiply - force it to be so
pokeLocalSite(cv0, evec[0], siteFirst);
}
peekSite(cv0, evec[0], siteFirst);
cv0()()(0).imag(0); // this should be zero after the phase multiply - force it to be so
pokeSite(cv0, evec[0], siteFirst);
}
}
}