CHROMA
unprec_hamberwu_fermact_w.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 /*! \file
3  * \brief Unpreconditioned Hamber-Wu fermion action
4  */
5 
6 #ifndef __unprec_hamberwu_fermact_w_h__
7 #define __unprec_hamberwu_fermact_w_h__
8 
11 #include "io/aniso_io.h"
12 
13 
14 namespace Chroma
15 {
16  //! Name and registration
17  namespace UnprecHamberWuFermActEnv
18  {
19  extern const std::string name;
20  bool registerAll();
21  }
22 
23 
24  //! Params for wilson ferm acts
26  {
28  UnprecHamberWuFermActParams(XMLReader& in, const std::string& path);
29 
30  Real Mass;
31  Real u0;
33  };
34 
35 
36  // Reader/writers
37  void read(XMLReader& xml, const std::string& path, UnprecHamberWuFermActParams& param);
38  void write(XMLWriter& xml, const std::string& path, const UnprecHamberWuFermActParams& param);
39 
40 
41  //! Unpreconditioned HamberWu fermion action
42  /*! \ingroup fermacts
43  *
44  * Supports creation and application for fermion actions
45  */
46  class UnprecHamberWuFermAct : public UnprecWilsonTypeFermAct<LatticeFermion,
47  multi1d<LatticeColorMatrix>, multi1d<LatticeColorMatrix> >
48  {
49  public:
50  // Typedefs to save typing
51  typedef LatticeFermion T;
52  typedef multi1d<LatticeColorMatrix> P;
53  typedef multi1d<LatticeColorMatrix> Q;
54 
55  //! General FermBC
57  const UnprecHamberWuFermActParams& param_) :
58  cfs(cfs_), param(param_) {}
59 
60  //! Copy constructor
62  cfs(a.cfs), param(a.param) {}
63 
64  //! Produce a linear operator for this action
66 
67  //! Produce the gamma_5 hermitian operator H_w
69  {
70  return new lgherm<T>(linOp(state));
71  }
72 
73  //! Destructor is automatic
75 
76  protected:
77  //! Return the fermion BC object for this action
78  const CreateFermState<T,P,Q>& getCreateState() const {return *cfs;}
79 
80  private:
81  UnprecHamberWuFermAct() {} //hide default constructor
82  void operator=(const UnprecHamberWuFermAct& a) {} // Hide =
83 
84  private:
87  };
88 
89 }
90 
91 #endif
Anisotropy parameters.
Create a fermion connection state.
Definition: create_state.h:69
Support class for fermion actions and linear operators.
Definition: state.h:94
Class for counted reference semantics.
Definition: handle.h:33
Linear Operator.
Definition: linearop.h:27
Unpreconditioned HamberWu fermion action.
~UnprecHamberWuFermAct()
Destructor is automatic.
void operator=(const UnprecHamberWuFermAct &a)
UnprecHamberWuFermAct(Handle< CreateFermState< T, P, Q > > cfs_, const UnprecHamberWuFermActParams &param_)
General FermBC.
Handle< CreateFermState< T, P, Q > > cfs
multi1d< LatticeColorMatrix > P
UnprecLinearOperator< T, P, Q > * linOp(Handle< FermState< T, P, Q > > state) const
Produce a linear operator for this action.
LinearOperator< T > * hermitianLinOp(Handle< FermState< T, P, Q > > state) const
Produce the gamma_5 hermitian operator H_w.
UnprecHamberWuFermActParams param
multi1d< LatticeColorMatrix > Q
UnprecHamberWuFermAct(const UnprecHamberWuFermAct &a)
Copy constructor.
const CreateFermState< T, P, Q > & getCreateState() const
Return the fermion BC object for this action.
Unpreconditioned linear operator including derivatives.
Definition: linearop.h:185
Unpreconditioned Wilson-like fermion actions with derivatives.
Definition: fermact.orig.h:491
Gamma(5) hermitian linear operator.
Definition: lgherm_w.h:22
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.
bool registerAll()
Register all the factories.
const std::string name
Name to be used.
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
Complex a
Definition: invbicg.cc:95
const WilsonTypeFermAct< multi1d< LatticeFermion > > Handle< const ConnectState > state
Definition: pbg5p_w.cc:28
static QDP_ColorVector * in
::std::string string
Definition: gtest.h:1979
Parameters for anisotropy.
Definition: aniso_io.h:24
Wilson-like fermion actions.