mirror of
https://github.com/paboyle/Grid.git
synced 2024-11-09 23:45:36 +00:00
Saving Lanczos testing program
This commit is contained in:
parent
9f0d9ade68
commit
1e72bd8b8c
@ -31,6 +31,8 @@ using namespace std;
|
||||
using namespace Grid;
|
||||
using namespace Grid::QCD;
|
||||
|
||||
typedef typename GparityDomainWallFermionR::FermionField FermionField;
|
||||
|
||||
RealD AllZero(RealD x){ return 0.;}
|
||||
|
||||
int main (int argc, char ** argv)
|
||||
@ -52,7 +54,7 @@ int main (int argc, char ** argv)
|
||||
GridParallelRNG RNG5rb(FrbGrid); RNG5.SeedFixedIntegers(seeds5);
|
||||
|
||||
LatticeGaugeField Umu(UGrid);
|
||||
SU3::HotConfiguration(RNG4, Umu);
|
||||
SU3::TepidConfiguration(RNG4, Umu);
|
||||
|
||||
std::vector<LatticeColourMatrix> U(4,UGrid);
|
||||
for(int mu=0;mu<Nd;mu++){
|
||||
@ -61,11 +63,17 @@ int main (int argc, char ** argv)
|
||||
|
||||
RealD mass=0.01;
|
||||
RealD M5=1.8;
|
||||
DomainWallFermionR Ddwf(Umu,*FGrid,*FrbGrid,*UGrid,*UrbGrid,mass,M5);
|
||||
RealD mob_b=1.5;
|
||||
// DomainWallFermionR Ddwf(Umu,*FGrid,*FrbGrid,*UGrid,*UrbGrid,mass,M5);
|
||||
GparityMobiusFermionD ::ImplParams params;
|
||||
std::vector<int> twists({1,1,1,0});
|
||||
params.twists = twists;
|
||||
GparityMobiusFermionR Ddwf(Umu,*FGrid,*FrbGrid,*UGrid,*UrbGrid,mass,M5,mob_b,mob_b-1.,params);
|
||||
|
||||
// MdagMLinearOperator<DomainWallFermionR,LatticeFermion> HermOp(Ddwf);
|
||||
// SchurDiagTwoOperator<DomainWallFermionR,LatticeFermion> HermOp(Ddwf);
|
||||
SchurDiagMooeeOperator<DomainWallFermionR,LatticeFermion> HermOp(Ddwf);
|
||||
SchurDiagTwoOperator<GparityMobiusFermionR,FermionField> HermOp(Ddwf);
|
||||
// SchurDiagMooeeOperator<DomainWallFermionR,LatticeFermion> HermOp(Ddwf);
|
||||
|
||||
const int Nstop = 30;
|
||||
const int Nk = 40;
|
||||
@ -75,17 +83,17 @@ int main (int argc, char ** argv)
|
||||
RealD resid = 1.0e-8;
|
||||
|
||||
std::vector<double> Coeffs { 0.,-1.};
|
||||
Polynomial<LatticeFermion> PolyX(Coeffs);
|
||||
Chebyshev<LatticeFermion> Cheb(1,80.,21);
|
||||
Polynomial<FermionField> PolyX(Coeffs);
|
||||
Chebyshev<FermionField> Cheb(0.2,5.,11);
|
||||
// ChebyshevLanczos<LatticeFermion> Cheb(9.,1.,0.,20);
|
||||
// Cheb.csv(std::cout);
|
||||
// exit(-24);
|
||||
ImplicitlyRestartedLanczos<LatticeFermion> IRL(HermOp,Cheb,Nstop,Nk,Nm,resid,MaxIt);
|
||||
ImplicitlyRestartedLanczos<FermionField> IRL(HermOp,Cheb,Nstop,Nk,Nm,resid,MaxIt);
|
||||
|
||||
|
||||
std::vector<RealD> eval(Nm);
|
||||
LatticeFermion src(FrbGrid); gaussian(RNG5rb,src);
|
||||
std::vector<LatticeFermion> evec(Nm,FrbGrid);
|
||||
FermionField src(FrbGrid); gaussian(RNG5rb,src);
|
||||
std::vector<FermionField> evec(Nm,FrbGrid);
|
||||
for(int i=0;i<1;i++){
|
||||
std::cout << i<<" / "<< Nm<< " grid pointer "<<evec[i]._grid<<std::endl;
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user