30 namespace StochCondContEnv
55 XMLReader paramtop(xml, path);
58 read(paramtop,
"version", version);
69 QDPIO::cerr <<
"StochCond: Input parameter version " << version <<
" unsupported." << std::endl;
87 write(xml,
"version", version);
119 std::list< Handle<HadronContractResult_t> >
126 QDPIO::cout <<
"Stochastic Condensates" << std::endl;
147 QDPIO::cout <<
"Attempt to read solutions" << std::endl;
150 QDPIO::cout <<
"dilutions.size= " << quark.
dilutions.size() << std::endl;
153 XMLReader file_xml, record_xml;
160 read(record_xml,
"/Propagator/PropSource", quark.
dilutions[
i].source_header);
161 read(record_xml,
"/Propagator/ForwardProp", quark.
dilutions[
i].prop_header);
166 QDPIO::cerr <<
"Error extracting headers: " << e << std::endl;
171 QDPIO::cout <<
"Sources and solutions successfully read: time= "
172 << swatch.getTimeInSeconds()
173 <<
" secs" << std::endl;
188 LatticeFermion quark_noise;
192 std::istringstream xml_s(quark.
dilutions[
i].source_header.source.xml);
193 XMLReader sourcetop(xml_s);
202 QDPIO::cout <<
"Dilution num= " <<
i << std::endl;
206 quark.
dilutions[
i].source_header.source.path);
229 QDPIO::cerr <<
"dilution=" <<
i <<
" seed does not match" << std::endl;
234 if ( toBool(srcParams.
N != N) )
236 QDPIO::cerr <<
"dilution=" <<
i <<
" N does not match" << std::endl;
252 multi1d<Double> source_corr = sumMulti(localNorm2(quark.
dilutions[
i].source),
255 multi1d<Double> soln_corr = sumMulti(localNorm2(quark.
dilutions[
i].soln),
262 Double dcnt = norm2(quark_noise);
263 if (toDouble(dcnt) != 0.0)
265 QDPIO::cerr <<
"Noise not saturated by all potential solutions: dcnt=" << dcnt << std::endl;
271 QDPIO::cerr <<
": Caught Exception creating source: " << e << std::endl;
277 QDPIO::cout <<
"Sources saturated: time= "
278 << swatch.getTimeInSeconds()
279 <<
" secs" << std::endl;
298 std::list< Handle<Hadron2PtContract_t> > hadron;
300 for(
int gamma_value=0; gamma_value < Ns*Ns; ++gamma_value)
304 push(had->xml, xml_group);
305 write(had->xml, id_tag,
"stoch_diagonal_gamma_condensates");
306 write(had->xml,
"gamma_value", gamma_value);
319 hadron.push_back(had);
324 return this->
project(hadron, sft_params);
Random complex Z(N) sources using dilution.
virtual std::list< Handle< HadronContractResult_t > > project(const std::list< Handle< Hadron2PtContract_t > > &had_list, const SftMomParams_t &p) const
Convenience function to project onto fixed momenta.
Construct hadron correlators.
Class for counted reference semantics.
Fourier transform phase factor support.
const Set & getSet() const
The set to be used in sumMulti.
Stochastic quark condensates.
std::list< Handle< HadronContractResult_t > > operator()(const multi1d< LatticeColorMatrix > &u, const std::string &xml_group, const std::string &id_tag)
Construct the correlators.
Random Z(N) source construction using dilution.
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 zN_src(LatticeFermion &a, int N)
Volume source of Z(N) noise.
Factory for producing hadron correlator objects.
void savern(int iseed[4])
Named object function std::map.
static bool registered
Local registration flag.
std::string getName()
Return the name.
QDPSubTypeTrait< typename BinaryReturn< C1, C2, FnLocalInnerProduct >::Type_t >::Type_t localInnerProduct(const QDPSubType< T1, C1 > &l, const QDPType< T2, C2 > &r)
bool registerAll()
Register all the factories.
Asqtad Staggered-Dirac operator.
static multi1d< LatticeColorMatrix > u
push(xml_out,"Condensates")
FloatingPoint< double > Double
Random complex Z(N) sources using dilution.
The result of hadron 2pt correlators.
Propagator source construction parameters.
multi1d< int > mom_offset
multi1d< int > origin_offset
multi1d< std::string > soln_files
multi1d< int > mom_origin
void writeXML(XMLWriter &xml_out, const std::string &path) const
Structure holding solutions.
PropSourceConst_t source_header
Structure holding a source and its solutions.
multi1d< QuarkSolution_t > dilutions
Volume source of Z(N) noise.