CHROMA
unprec_dwf_fermact_base_array_w.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 /*! \file
3  * \brief Base class for unpreconditioned domain-wall-like fermion actions
4  */
5 
6 #ifndef __unprec_dwf_fermact_base_array_w_h__
7 #define __unprec_dwf_fermact_base_array_w_h__
8 
15 
16 
17 namespace Chroma
18 {
19  //! Base class for unpreconditioned domain-wall-like fermion actions
20  /*! \ingroup fermacts
21  *
22  * Unprecondition domain-wall fermion action. The conventions used here
23  * are specified in Phys.Rev.D63:094505,2001 (hep-lat/0005002).
24  */
25  template<typename T, typename P, typename Q>
27  {
28  public:
29  //! Return the quark mass
30  virtual Real getQuarkMass() const = 0;
31 
32  //! Produce an unpreconditioned linear operator for this action with arbitrary quark mass
34  const Real& m_q) const = 0;
35 
36  //! Override to produce a DWF-link unprec. linear operator for this action
37  /*! Covariant return rule - override base class function */
39  {
40  return unprecLinOp(state,getQuarkMass());
41  }
42 
43  //! Override to produce a DWF-link unprec. Pauli-Villars linear operator for this action
44  /*! Covariant return rule - override base class function */
46  {
47  return unprecLinOp(state,Real(1));
48  }
49 
50  //! Produce a hermitian version of the linear operator
51  /*! This code is generic */
53  {
54  // Have not implemented this yet, but it is generic
55  QDPIO::cerr << "UnprecDWFermActBaseArray::gamma5HermLinOp not implemented" << std::endl;
56  QDP_abort(1);
57  return 0;
58  }
59 
60  //! Produce an unpreconditioned linear operator projecting 5D to 4D (the inverse of qprop below)
61  /*! Use the fact that linOp4D(m_q) = [P^{-1} (D^{(5)}(1))^{-1} D^{(5)}(m_q) P]_{11} */
63  const Real& m_q,
64  const GroupXML_t& invParam) const
65  {
66  std::istringstream is(invParam.xml);
67  XMLReader paramtop(is);
68 
69  return new UnprecDWF4DLinOp<T>(unprecLinOp(state,m_q),
70  unprecLinOp(state,Real(1)),
71  SysSolverCGParams(paramtop,invParam.path));
72  }
73 
74  //! Produce a DeltaLs = 1-epsilon^2(H) operator
76  const GroupXML_t& invParam) const
77  {
78  Handle< LinearOperator<T> > lin(linOp4D(state,Real(0),invParam));
79  return new lDeltaLs(lin);
80  }
81 
82  //! Define quark propagator routine for 4D fermions
83  /*! Default implementation provided */
85  const GroupXML_t& invParam) const;
86 
87  //! Apply the Dminus operator on a fermion.
88  /*!
89  * Slightly more than a convenience function,
90  * it avoids specifying the type of the linOp.
91  * Used in the dwf_quarkProp routine.
92  */
93  void Dminus(T& chi,
94  const T& psi,
96  enum PlusMinus isign,
97  int s5) const
98  {
100  A->Dminus(chi,psi,isign,s5);
101  }
102 
103  };
104 
105 }
106 
107 
108 #endif
Support class for fermion actions and linear operators.
Definition: state.h:94
Class for counted reference semantics.
Definition: handle.h:33
Linear Operator to arrays.
Definition: linearop.h:61
Linear Operator.
Definition: linearop.h:27
Linear system solvers.
Definition: syssolver.h:34
Unpreconditioned projected DWF operator to 4D.
Base class for unpreconditioned domain-wall-like fermion actions.
virtual LinearOperatorArray< T > * hermitianLinOp(Handle< FermState< T, P, Q > > state) const
Produce a hermitian version of the linear operator.
virtual Real getQuarkMass() const =0
Return the quark mass.
SystemSolver< T > * qprop(Handle< FermState< T, P, Q > > state, const GroupXML_t &invParam) const
Define quark propagator routine for 4D fermions.
virtual UnprecDWLikeLinOpBaseArray< T, P, Q > * unprecLinOp(Handle< FermState< T, P, Q > > state, const Real &m_q) const =0
Produce an unpreconditioned linear operator for this action with arbitrary quark mass.
virtual UnprecDWLikeLinOpBaseArray< T, P, Q > * linOp(Handle< FermState< T, P, Q > > state) const
Override to produce a DWF-link unprec. linear operator for this action.
virtual UnprecDWLikeLinOpBaseArray< T, P, Q > * linOpPV(Handle< FermState< T, P, Q > > state) const
Override to produce a DWF-link unprec. Pauli-Villars linear operator for this action.
void Dminus(T &chi, const T &psi, Handle< FermState< T, P, Q > > state, enum PlusMinus isign, int s5) const
Apply the Dminus operator on a fermion.
virtual LinearOperator< T > * DeltaLs(Handle< FermState< T, P, Q > > state, const GroupXML_t &invParam) const
Produce a DeltaLs = 1-epsilon^2(H) operator.
virtual LinearOperator< T > * linOp4D(Handle< FermState< T, P, Q > > state, const Real &m_q, const GroupXML_t &invParam) const
Produce an unpreconditioned linear operator projecting 5D to 4D (the inverse of qprop below)
Unpreconditioned domain-wall Dirac operator.
Unpreconditioned Wilson-like fermion actions in extra dims with derivatives.
Definition: fermact.orig.h:571
GW Defect operator.
Definition: lDeltaLs_w.h:19
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
LinOpSysSolverMGProtoClover::T T
multi1d< LatticeFermion > chi(Ncb)
LatticeFermion psi
Definition: mespbg5p_w.cc:35
A(A, psi, r, Ncb, PLUS)
const WilsonTypeFermAct< multi1d< LatticeFermion > > Handle< const ConnectState > state
Definition: pbg5p_w.cc:28
Hold group xml and type id.
Params for CG inverter.
Solve a CG1 system.
Unpreconditioned projected DWF operator to 4D.
Base class for unpreconditioned domain-wall-like fermion linear operator.
Wilson-like fermion actions.