43 namespace NormShellQuarkSinkSmearingEnv
50 const multi1d<LatticeColorMatrix>&
u)
58 const multi1d<LatticeColorMatrix>&
u)
66 const multi1d<LatticeColorMatrix>&
u)
110 XMLReader paramtop(xml, path);
113 read(paramtop,
"version", version);
126 XMLBufferWriter xml_tmp;
127 push(xml_tmp,
"Displacement");
130 if (paramtop.count(
"disp_length") != 0)
131 read(paramtop,
"disp_length", disp_length);
133 if (paramtop.count(
"disp_dir") != 0)
134 read(paramtop,
"disp_dir", disp_dir);
136 write(xml_tmp,
"disp_length", disp_length);
137 write(xml_tmp,
"disp_dir", disp_dir);
147 if (paramtop.count(
"Displacement") != 0)
158 if (paramtop.count(
"Displacement") != 0)
166 QDPIO::cerr << __func__ <<
": parameter version " << version
167 <<
" unsupported." << std::endl;
173 if (paramtop.count(
"LinkSmearing") != 0)
181 if (paramtop.count(
"SiteNormalize") != 0){
194 write(xml,
"version", version);
215 QDPIO::cout <<
"NormShell sink" << std::endl;
223 XMLReader smeartop(xml_s);
235 XMLReader displacetop(xml_d);
249 (*quarkSmearing)(quark_sink, u_smr);
251 for(
int src_s(0);src_s<Ns;src_s++){
252 for(
int snk_s(0);snk_s<Ns;snk_s++){
253 LatticeColorMatrix cm = peekSpin(quark_sink,snk_s,src_s);
254 multi1d<LatticeColorVector> v(Nc) ;
255 for(
int c(0);
c<Nc;
c++){
256 for(
int i = 0;
i < Nc; ++
i)
257 pokeColor(v[
c], peekColor(cm,
i,
c),
i) ;
260 for(
int k(0);
k<
c;
k++){
264 Double nn = sqrt(norm2(v[
c])) ;
266 for(
int i = 0;
i < Nc; ++
i)
267 pokeColor(cm,peekColor(v[
c],
i),
i,
c);
269 pokeSpin(quark_sink,cm,snk_s,src_s);
276 (*quarkDisplacement)(quark_sink, u_smr,
PLUS);
280 QDPIO::cout<<__func__<<
": WARNING! smearing last not implemented...\n" ;
284 (*quarkDisplacement)(quark_sink, u_smr,
PLUS);
289 (*quarkSmearing)(quark_sink, u_smr);
295 QDPIO::cerr <<
name <<
": Caught Exception smearing: " << e << std::endl;
308 QDPIO::cout <<
"NormShell sink" << std::endl;
316 XMLReader smeartop(xml_s);
328 XMLReader displacetop(xml_d);
341 (*quarkSmearing)(quark_sink, u_smr);
346 (*quarkDisplacement)(quark_sink, u_smr,
PLUS);
353 (*quarkDisplacement)(quark_sink, u_smr,
PLUS);
358 (*quarkSmearing)(quark_sink, u_smr);
364 QDPIO::cerr <<
name <<
": Caught Exception smearing: " << e << std::endl;
384 XMLReader smeartop(xml_s);
395 XMLReader displacetop(xml_d);
405 (*quarkSmearing)(quark_sink, u_smr);
411 (*quarkDisplacement)(quark_sink, u_smr,
PLUS);
416 QDPIO::cerr <<
name <<
": Caught Exception smearing: " << e << std::endl;
Primary include file for CHROMA library code.
Class for counted reference semantics.
void operator()(T &obj) const
Smear the sink.
Base class for quark source and sink smearing.
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.
GroupXML_t readXMLGroup(XMLReader &xml_in, const std::string &path, const std::string &type_name)
Read group and return as a std::string.
Class for counted reference semantics.
All link smearing constructors.
Factory for producing link smearing objects.
static bool registered
Local registration flag.
const std::string name
Name to be used.
CreateFermState< LatticeFermion, multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > > * createFerm(XMLReader &xml, const std::string &path)
BinaryReturn< C1, C2, FnInnerProduct >::Type_t innerProduct(const QDPSubType< T1, C1 > &s1, const QDPType< T2, C2 > &s2)
GroupXML_t nullXMLGroup()
Returns a no-linksmearing group.
bool registerAll()
Register all the factories.
bool registerAll()
Register all the factories.
std::string getName()
Return the name.
bool registerAll()
Register all the factories.
GroupXML_t nullXMLGroup()
Returns a no-displacement group.
bool registerAll()
Register all the factories.
std::string getName()
Return the name.
Asqtad Staggered-Dirac operator.
static multi1d< LatticeColorMatrix > u
push(xml_out,"Condensates")
FloatingPoint< double > Double
All quark displacement constructors.
Factory for producing quark displacement objects.
All quark smearing constructors.
Factory for producing quark smearing objects.
Simple quark displacement.
Factory for producing quark prop sinks.
GroupXML_t quark_displacement
void writeXML(XMLWriter &in, const std::string &path) const
GroupXML_t quark_smearing