CHROMA
aniso_spectrum_gaugeact.cc
Go to the documentation of this file.
1 /*! \file
2  * \brief Anisotropic gaugeact useful for spectrum from hep-lat/9911003
3  *
4  * Tree-level LW with tapole improvement, missing 1x2 in time, also including
5  * 2-plaq term. Taken from Morningstar-Peardon, hep-lat/9911003
6  */
7 
8 #include "chromabase.h"
12 
13 namespace Chroma
14 {
15 
16  namespace AnisoSpectrumGaugeActEnv
17  {
19  multi1d<LatticeColorMatrix> >* createGaugeAct(XMLReader& xml,
20  const std::string& path)
21  {
23  AnisoSpectrumGaugeActParams(xml, path));
24  }
25 
26  const std::string name = "ANISO_SPECTRUM_GAUGEACT";
27 
28  //! Local registration flag
29  static bool registered = false;
30 
31  //! Register all the factories
32  bool registerAll()
33  {
34  bool success = true;
35  if (! registered)
36  {
37  success &= TheGaugeActFactory::Instance().registerObject(name, createGaugeAct);
38  registered = true;
39  }
40  return success;
41  }
42 
43  }
44 
45 
47  {
48  XMLReader paramtop(xml_in, path);
49 
50  try
51  {
52  read(paramtop, "beta", beta);
53  read(paramtop, "u_s", u_s);
54  read(paramtop, "u_t", u_t);
55  read(paramtop, "omega", omega);
56  read(paramtop, "AnisoParam", aniso);
57  }
58  catch( const std::string& e ) {
59  QDPIO::cerr << "Error reading XML: " << e << std::endl;
60  QDP_abort(1);
61  }
62  }
63 
64 
65  void read(XMLReader& xml, const std::string& path, AnisoSpectrumGaugeActParams& p)
66  {
68  p=tmp;
69  }
70 
71  void write(XMLWriter& xml, const std::string& path, const AnisoSpectrumGaugeActParams& param)
72  {
73  push(xml, path);
74 
75  write(xml, "beta", param.beta);
76  write(xml, "u_s", param.u_s);
77  write(xml, "u_t", param.u_t);
78  write(xml, "omega", param.omega);
79  write(xml, "AnisoParam", param.aniso);
80 
81  pop(xml);
82  }
83 
84 
85  // Private initializer
86  void
88  {
89  START_CODE();
90 
91  // Do the plaquette first. Spatial and temporal coeffs
92  // anisotropy multiplied in in the terms constructor
93 
94  // Various tadpole things
95  // spatial powers
96  Real u_s_2 = param.u_s * param.u_s;
97  Real u_s_4 = u_s_2 * u_s_2;
98  Real u_s_6 = u_s_4 * u_s_2;
99  Real u_s_8 = u_s_4 * u_s_4;
100 
101  // temporal powers
102  Real u_t_2 = param.u_t * param.u_t;
103  Real u_t_4 = u_t_2 * u_t_2;
104 
105  // Coefficients for the plaquette term (eq 4 in hep-lat/9911003)
106  Real plaq_c_s = param.beta * Real(5) * ( Real(1) + param.omega ) / ( Real(3) * u_s_4 );
107  Real plaq_c_t = param.beta * Real(4) / ( Real(3) * u_s_2 * u_t_2 );
108 
109  // plaq = new PlaqGaugeAct(cgs, plaq_c_s, plaq_c_t, param.aniso);
110 
111  // Coefficient of 2 plaquette spatial adjoint like thingie
112  Real coeff_2plaq = Real(-5)*param.beta*param.omega/(Real(3)*u_s_8);
114  plaq_c_s,
115  plaq_c_t,
116  coeff_2plaq,
117  param.aniso);
118  // Coefficients for the rectangle
119  Real rect_c_s = - param.beta / ( Real(12)*u_s_6 );
120 
121  // Loops that are short in the time direction
122  Real rect_c_t_2 = - param.beta / ( Real(12)*u_s_4*u_t_2);
123 
124  // Loops that are long int the time direction ought to be ommitted
125  bool no_temporal_2link = true;
126  Real rect_c_t_1 = 0; // Specify a zero coefficient (skipped anyway)
127 
128  rect = new RectGaugeAct(cgs, rect_c_s, rect_c_t_1, rect_c_t_2, no_temporal_2link, param.aniso);
129 
130  END_CODE();
131  }
132 
133 }
134 
Anisotropic gaugeact useful for spectrum from hep-lat/9911003.
Primary include file for CHROMA library code.
Handle< PlaqPlusSpatialTwoPlaqGaugeAct > plaq_plus_two_plaq
void init(Handle< CreateGaugeState< P, Q > > cgs)
Private initializer.
AnisoSpectrumGaugeActParams param
Create a gauge connection state.
Definition: create_state.h:47
Abstract base class for gauge actions.
Definition: gaugeact.h:25
Class for counted reference semantics.
Definition: handle.h:33
Rect gauge action.
Definition: rect_gaugeact.h:54
static T & Instance()
Definition: singleton.h:432
All gauge create-state method.
Fermion action factories.
void read(XMLReader &xml, const std::string &path, AsqtadFermActParams &param)
Read parameters.
void write(XMLWriter &xml, const std::string &path, const AsqtadFermActParams &param)
Writer parameters.
static bool registered
Local registration flag.
bool registerAll()
Register all the factories.
GaugeAction< multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > > * createGaugeAct(XMLReader &xml, const std::string &path)
Handle< CreateGaugeState< multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > > > reader(XMLReader &xml_in, const std::string &path)
Helper function for the CreateGaugeState readers.
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
LatticeFermion tmp
Definition: mespbg5p_w.cc:36
push(xml_out,"Condensates")
pop(xml_out)
START_CODE()
::std::string string
Definition: gtest.h:1979