1
0
mirror of https://github.com/paboyle/Grid.git synced 2024-11-13 01:05:36 +00:00

Compiles now

This commit is contained in:
Azusa Yamaguchi 2016-11-03 16:58:23 +00:00
parent 1c5b7a6be5
commit ee686a7d85
5 changed files with 17 additions and 16 deletions

View File

@ -111,7 +111,8 @@ int main (int argc, char ** argv)
RealD mass=0.1; RealD mass=0.1;
RealD c1=9.0/8.0; RealD c1=9.0/8.0;
RealD c2=-1.0/24.0; RealD c2=-1.0/24.0;
ImprovedStaggeredFermionR Ds(Umu,Grid,RBGrid,mass,c1,c2,params); RealD u0=1.0;
ImprovedStaggeredFermionR Ds(Umu,Grid,RBGrid,mass,c1,c2,u0,params);
std::cout<<GridLogMessage << "Calling Ds"<<std::endl; std::cout<<GridLogMessage << "Calling Ds"<<std::endl;
int ncall=1000; int ncall=1000;

View File

@ -103,7 +103,7 @@ void CartesianCommunicator::Barrier(void){}
void CartesianCommunicator::Broadcast(int root,void* data, int bytes) {} void CartesianCommunicator::Broadcast(int root,void* data, int bytes) {}
void CartesianCommunicator::BroadcastWorld(int root,void* data, int bytes) { } void CartesianCommunicator::BroadcastWorld(int root,void* data, int bytes) { }
int CartesianCommunicator::RankFromProcessorCoor(std::vector<int> &coor) { return 0;} int CartesianCommunicator::RankFromProcessorCoor(std::vector<int> &coor) { return 0;}
void CartesianCommunicator::ProcessorCoorFromRank(int rank, std::vector<int> &coor){ assert(0);} void CartesianCommunicator::ProcessorCoorFromRank(int rank, std::vector<int> &coor){ coor = _processor_coor; }
void CartesianCommunicator::ShiftedRanks(int dim,int shift,int &source,int &dest) void CartesianCommunicator::ShiftedRanks(int dim,int shift,int &source,int &dest)
{ {
source =0; source =0;

View File

@ -574,20 +574,20 @@ PARALLEL_FOR_LOOP
for (int mu = 0; mu < Nd; mu++) { for (int mu = 0; mu < Nd; mu++) {
// Staggered Phase. // Staggered Phase.
ComplexField coor(GaugeGrid); Lattice<iScalar<vInteger> > coor(GaugeGrid);
ComplexField phases(GaugeGrid); Lattice<iScalar<vInteger> > x(GaugeGrid); LatticeCoordinate(x,0);
ComplexField x(GaugeGrid); LatticeCoordinate(x,0); Lattice<iScalar<vInteger> > y(GaugeGrid); LatticeCoordinate(y,1);
ComplexField y(GaugeGrid); LatticeCoordinate(y,1); Lattice<iScalar<vInteger> > z(GaugeGrid); LatticeCoordinate(z,2);
ComplexField z(GaugeGrid); LatticeCoordinate(z,2); Lattice<iScalar<vInteger> > t(GaugeGrid); LatticeCoordinate(t,3);
ComplexField t(GaugeGrid); LatticeCoordinate(t,3);
SiteComplex zz(0.0,0.0); Lattice<iScalar<vInteger> > lin_z(GaugeGrid); lin_z=x+y;
SiteComplex one(1.0,0.0); Lattice<iScalar<vInteger> > lin_t(GaugeGrid); lin_t=x+y+z;
phases = one; ComplexField phases(GaugeGrid); phases=1.0;
if ( mu == 1 ) phases = where( mod(x ,2)== zz, phases,-phases);
if ( mu == 2 ) phases = where( mod(x+y ,2)== zz, phases,-phases); if ( mu == 1 ) phases = where( mod(x ,2)==(Integer)0, phases,-phases);
if ( mu == 3 ) phases = where( mod(x+y+z,2)== zz, phases,-phases); if ( mu == 2 ) phases = where( mod(lin_z,2)==(Integer)0, phases,-phases);
if ( mu == 3 ) phases = where( mod(lin_t,2)==(Integer)0, phases,-phases);
U = PeekIndex<LorentzIndex>(Umu, mu); U = PeekIndex<LorentzIndex>(Umu, mu);
UU = Gimpl::CovShiftForward(U,mu,U); UU = Gimpl::CovShiftForward(U,mu,U);

View File

@ -81,7 +81,7 @@ ImprovedStaggeredFermion<Impl>::ImprovedStaggeredFermion(GaugeField &_Umu, GridC
template <class Impl> template <class Impl>
void ImprovedStaggeredFermion<Impl>::ImportGauge(const GaugeField &_Umu) { void ImprovedStaggeredFermion<Impl>::ImportGauge(const GaugeField &_Umu) {
GaugeLinkField U(GaugeGrid); GaugeLinkField U(GaugeGrid());
//////////////////////////////////////////////////////// ////////////////////////////////////////////////////////
// Double Store should take two fields for Naik and one hop separately. // Double Store should take two fields for Naik and one hop separately.

View File

@ -108,7 +108,7 @@ class ImprovedStaggeredFermion : public StaggeredKernels<Impl>, public ImprovedS
// Constructor // Constructor
ImprovedStaggeredFermion(GaugeField &_Umu, GridCartesian &Fgrid, ImprovedStaggeredFermion(GaugeField &_Umu, GridCartesian &Fgrid,
GridRedBlackCartesian &Hgrid, RealD _mass, GridRedBlackCartesian &Hgrid, RealD _mass,
RealD _c1=9.0/8.0, RealD _c2=-1.0/24.0,RealD _u0, RealD _c1=9.0/8.0, RealD _c2=-1.0/24.0,RealD _u0=1.0,
const ImplParams &p = ImplParams()); const ImplParams &p = ImplParams());
// DoubleStore impl dependent // DoubleStore impl dependent