CHROMA
wilson_coarse_fine_1loop_gaugeact.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 /*! \file
3  * \brief Wilson gauge action supporting 2+2 anisotropy.
4  *
5  * Wilson gauge action on a 2+2 lattice.
6  * Follows the conventions of hep-lat/0303005 (TrinLat).
7  * Here, coefficients are for 1-loop.
8  */
9 
10 #ifndef __wilson_coarse_fine_1loop_gaugeact_h__
11 #define __wilson_coarse_fine_1loop_gaugeact_h__
12 
13 #include "gaugeact.h"
14 #include "gaugebc.h"
16 
17 namespace Chroma
18 {
19 
20  /*! @ingroup gaugeacts */
21  namespace WilsonCoarseFine1LoopGaugeActEnv
22  {
23  extern const std::string name;
24  bool registerAll();
25  }
26 
27  //! Parameter structure
28  /*! @ingroup gaugeacts */
30  {
31  //! Base Constructor
33 
34  //! Read params from some root path
35  WilsonCoarseFine1LoopGaugeActParams(XMLReader& xml_in, const std::string& path);
36 
37  Real beta; /*!< Yep, it's beta - the coefficient in front of the action */
38 
39  multi1d<int> coarse_dirs; /*!< Directions for coarse lattice */
40  Real xi; /*!< Coefficient of fine-fine plaquette */
41  Real coeff_ff; /*!< 1-loop coefficient of fine-fine plaquette = eta_ff-eta_cf */
42  Real coeff_cc; /*!< 1-loop coefficient of coarse-coare plaquette = eta_cc-eta_cf */
43  };
44 
45  /*! @ingroup gaugeacts */
46  void read(XMLReader& xml, const std::string& path, WilsonCoarseFine1LoopGaugeActParams& param);
47 
48 
49  //! WilsonCoarseFine gauge action
50  /*! \ingroup gaugeacts
51  *
52  * Wilson gauge action on a 2+2 lattice.
53  * Follows the conventions of hep-lat/0303005 (TrinLat)
54  */
55 
57  {
58  public:
59  //! Read beta from a param struct
62 
63  //! Return the set on which the gauge action is defined
64  /*! Defined on the even-off (red/black) set */
65  const Set& getSet() const {return rb;}
66 
67  //! Compute staple
68  /*! Default version. Derived class should override this if needed. */
69  void staple(LatticeColorMatrix& result,
70  const Handle< GaugeState<P,Q> >& state,
71  int mu, int cb) const
72  {
73  plaq->staple(result,state,mu,cb);
74  }
75 
76  //! Compute dS/dU
77  void deriv(multi1d<LatticeColorMatrix>& result,
78  const Handle< GaugeState<P,Q> >& state) const
79  {
80  plaq->deriv(result,state);
81  }
82 
83  //! Compute the actions
84  Double S(const Handle< GaugeState<P,Q> >& state) const
85  {
86  return plaq->S(state);
87  }
88 
89  //! Destructor is automatic
91 
92  //! Produce a gauge create state object
93  const CreateGaugeState<P,Q>& getCreateState() const {return plaq->getCreateState();}
94 
95  protected:
96  //! Private initializer
97  void init(Handle< CreateGaugeState<P,Q> > cgs);
98 
99  //! Partial constructor
101  //! Hide assignment
103 
104  private:
105  Handle<PlaqGaugeAct> plaq; /*!< Hold a plaquette gaugeact */
107  };
108 
109 } // end namespace Chroma
110 
111 
112 #endif
Create a gauge connection state.
Definition: create_state.h:47
Support class for fermion actions and linear operators.
Definition: state.h:74
Class for counted reference semantics.
Definition: handle.h:33
Base class for gauge actions with links appearing linearly in the action.
Definition: gaugeact.h:80
void operator=(const WilsonCoarseFine1LoopGaugeAct &a)
Hide assignment.
void deriv(multi1d< LatticeColorMatrix > &result, const Handle< GaugeState< P, Q > > &state) const
Compute dS/dU.
const CreateGaugeState< P, Q > & getCreateState() const
Produce a gauge create state object.
Double S(const Handle< GaugeState< P, Q > > &state) const
Compute the actions.
void init(Handle< CreateGaugeState< P, Q > > cgs)
Private initializer.
void staple(LatticeColorMatrix &result, const Handle< GaugeState< P, Q > > &state, int mu, int cb) const
Compute staple.
const Set & getSet() const
Return the set on which the gauge action is defined.
int mu
Definition: cool.cc:24
Class structure for gauge actions.
Gauge boundary conditions.
void read(XMLReader &xml, const std::string &path, AsqtadFermActParams &param)
Read parameters.
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
Complex a
Definition: invbicg.cc:95
int cb
Definition: invbicg.cc:120
const WilsonTypeFermAct< multi1d< LatticeFermion > > Handle< const ConnectState > state
Definition: pbg5p_w.cc:28
FloatingPoint< double > Double
Definition: gtest.h:7351
::std::string string
Definition: gtest.h:1979
Plaquette gauge action.