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

Normalise

This commit is contained in:
Peter Boyle 2025-04-24 11:37:14 -04:00
parent e652fc2825
commit 7af8c77a52

View File

@ -93,10 +93,13 @@ int main(int argc, char ** argv)
Real coeff = (width*width) / Real(4*Iterations); Real coeff = (width*width) / Real(4*Iterations);
chi=kronecker; chi=kronecker;
// chi = (1-p^2/2N)^N kronecker // chi = (1-p^2/2N)^N kronecker
for(int n = 0; n < Iterations; ++n) { for(int n = 0; n < Iterations; ++n) {
Laplacian.M(chi,psi); Laplacian.M(chi,psi);
chi = chi - coeff*psi; chi = chi - coeff*psi;
RealD n2 = norm2(chi);
chi = chi * (1.0/std::sqrt(n2));
} }
std::cout << " Wuppertal smeared operator is chi = \n" << chi <<std::endl; std::cout << " Wuppertal smeared operator is chi = \n" << chi <<std::endl;