30 void boxfil(LatticeFermion&
a,
int color_index,
int spin_index)
34 if (color_index >= Nc || color_index < 0)
37 if (spin_index >= Ns || spin_index < 0)
42 Complex sitecomp = cmplx(
one,0);
43 ColorVector sitecolor =
zero;
44 Fermion sitefield =
zero;
47 pokeColor(sitecolor,sitecomp,color_index),
58 namespace MomWallQuarkSourceConstEnv
103 XMLReader paramtop(xml, path);
106 read(paramtop,
"version", version);
114 QDPIO::cerr << __func__ <<
": parameter version " << version
115 <<
" unsupported." << std::endl;
124 if (
mom.size() !=
Nd)
126 QDPIO::cerr <<
name <<
": wrong size of mom array: expected length=" <<
Nd << std::endl;
138 write(xml,
"version", version);
154 QDPIO::cout <<
"Volume Momentum Source" << std::endl;
156 LatticeComplex phase ;
159 multi1d<int> mom3(
Nd-1);
168 phase = cos( fact * QDP::Layout::latticeCoordinate(
params.
j_decay) );
177 QDPIO::cout<<
"Source momentum (averaged over equivalent momenta): " ;
178 QDPIO::cout<<mom[0]<<mom[1]<<mom[2]<<std::endl;
183 multi1d<int> mom = phases.
numToMom(0) ;
184 QDPIO::cout<<
"Source momentum: " ;
185 QDPIO::cout<<mom[0]<<mom[1]<<mom[2]<<mom[3]<<std::endl;
189 LatticePropagator quark_source;
190 for(
int color_source = 0; color_source < Nc; ++color_source)
192 for(
int spin_source = 0; spin_source < Ns; ++spin_source)
Primary include file for CHROMA library code.
MomWall source construction.
T operator()(const multi1d< LatticeColorMatrix > &u) const
Construct the source.
Base class for quark source construction.
Fourier transform phase factor support.
multi1d< int > canonicalOrder(const multi1d< int > &mom) const
Canonically order an array of momenta.
multi1d< int > numToMom(int mom_num) const
Convert momenta id to actual array of momenta.
void FermToProp(const LatticeFermionF &a, LatticePropagatorF &b, int color_index, int spin_index)
Insert a LatticeFermion into a LatticePropagator.
void read(XMLReader &xml, const std::string &path, AsqtadFermActParams ¶m)
Read parameters.
void write(XMLWriter &xml, const std::string &path, const AsqtadFermActParams ¶m)
Writer parameters.
void boxfil(LatticeFermion &a, int color_index, int spin_index)
Fill a specific color and spin index with 1.0 within a volume.
Fixed momentum (wall) source construction.
static bool registered
Local registration flag.
const std::string name
Name to be used.
std::string getName()
Return the name.
bool registerAll()
Register all the factories.
Asqtad Staggered-Dirac operator.
QDP_error_exit("too many BiCG iterations", n_count, rsd_sq, cp, c, re_rvr, im_rvr, re_a, im_a, re_b, im_b)
static multi1d< LatticeColorMatrix > u
push(xml_out,"Condensates")
multi1d< LatticeFermion > chi(Ncb)
Fourier transform phase factor support.
Factory for producing quark prop sources.
MomWall source parameters.
void writeXML(XMLWriter &in, const std::string &path) const