CHROMA
inline_hadspec_w.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 /*! \file
3  * \brief Inline hadron spectrum calculations
4  *
5  * Hadron spectrum calculations
6  */
7 
8 #ifndef __inline_hadspec_h__
9 #define __inline_hadspec_h__
10 
11 #include "chromabase.h"
13 
14 namespace Chroma
15 {
16  /*! \ingroup inlinehadron */
17  namespace InlineHadSpecEnv
18  {
19  extern const std::string name;
20  bool registerAll();
21  }
22 
23  //! Parameter structure
24  /*! \ingroup inlinehadron */
26  {
28  InlineHadSpecParams(XMLReader& xml_in, const std::string& path);
29  void write(XMLWriter& xml_out, const std::string& path);
30 
31  unsigned long frequency;
32 
33  struct Param_t
34  {
35  bool MesonP; // Meson spectroscopy
36  bool CurrentP; // Meson currents
37  bool BaryonP; // Baryons spectroscopy
38 
39  bool time_rev; // Use time reversal in baryon spectroscopy
40 
41  int mom2_max; // (mom)^2 <= mom2_max. mom2_max=7 in szin.
42  bool avg_equiv_mom; // average over equivalent momenta
43  } param;
44 
46  {
47  std::string gauge_id; /*!< Input gauge field */
48 
49  struct Props_t
50  {
53  };
54 
55  multi1d<Props_t> sink_pairs;
57 
58  std::string xml_file; // Alternate XML file pattern
59  };
60 
61 
62  //! Inline measurement of hadron spectrum
63  /*! \ingroup inlinehadron */
65  {
66  public:
70 
71  unsigned long getFrequency(void) const {return params.frequency;}
72 
73  //! Do the measurement
74  void operator()(const unsigned long update_no,
75  XMLWriter& xml_out);
76 
77  protected:
78  //! Do the measurement
79  void func(const unsigned long update_no,
80  XMLWriter& xml_out);
81 
82  private:
84  };
85 
86 }
87 
88 #endif
Abstract inline measurements.
Primary include file for CHROMA library code.
Inline measurement of hadron spectrum.
InlineHadSpecParams params
void operator()(const unsigned long update_no, XMLWriter &xml_out)
Do the measurement.
InlineHadSpec(const InlineHadSpec &p)
unsigned long getFrequency(void) const
Tell me how often I should measure this beastie.
void func(const unsigned long update_no, XMLWriter &xml_out)
Do the measurement.
InlineHadSpec(const InlineHadSpecParams &p)
bool registerAll()
Register all the factories.
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
::std::string string
Definition: gtest.h:1979
Parameter structure.
void write(XMLWriter &xml_out, const std::string &path)
struct Chroma::InlineHadSpecParams::Param_t param
struct Chroma::InlineHadSpecParams::NamedObject_t named_obj