CHROMA
stagtype_fermact_s.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 
3 /*! @file
4  * @brief Staggered-like fermion actions
5  */
6 
7 #ifndef __stagtype_fermact_s_h__
8 #define __stagtype_fermact_s_h__
9 
10 #include "fermact.h"
11 #include "eo_linop.h"
12 
13 namespace Chroma
14 {
15 
16  //-------------------------------------------------------------------------------------------
17  //! Staggered-like fermion actions
18  /*! @ingroup actions
19  *
20  * Staggered-like fermion actions
21  */
22  template<typename T, typename P, typename Q>
23  class StaggeredTypeFermAct : public DiffFermAct4D<T,P,Q>
24  {
25  public:
26  //! Virtual destructor to help with cleanup;
27  virtual ~StaggeredTypeFermAct() {}
28 
29  //! Return the quark mass
30  virtual const Real getQuarkMass() const = 0;
31 
32  //! Return a linear operator solver for this action to solve M*psi=chi
33  /*! Default implementation provided */
35  const GroupXML_t& invParam) const;
36 
37  //! Return a linear operator solver for this action to solve MdagM*psi=chi
38  /*! Default implementation provided */
40  const GroupXML_t& invParam) const;
41 
42  //! Return a multi-shift linear operator solver for this action to solve (M+shift)*psi=chi
43  /*! Default implementation */
45  const GroupXML_t& invParam) const;
46 
47  //! Return a multi-shift linear operator solver for this action to solve (MdagM+shift)*psi=chi
48  /*! Default implementation */
50  const GroupXML_t& invParam) const;
51 
52  //! Return a multi-shift linear operator solver for this action to solve (MdagM+shift)*psi=chi
53  /*! Default implementation */
55  const GroupXML_t& invParam) const;
56 
57  //! Given a complete propagator as a source, this does all the inversions needed
58  /*!
59  * Provides a default version
60  *
61  * \param q_sol quark propagator ( Write )
62  * \param q_src source ( Read )
63  * \param xml_out diagnostic output ( Modify )
64  * \param state gauge connection state ( Read )
65  * \param invParam inverter parameters ( Read )
66  * \param quarkSpinType compute only a non-relativistic prop ( Read )
67  * \param ncg_had number of solver iterations ( Write )
68  */
69  virtual void quarkProp(typename PropTypeTraits<T>::Type_t& q_sol,
70  XMLWriter& xml_out,
71  const typename PropTypeTraits<T>::Type_t& q_src,
73  const GroupXML_t& invParam,
74  QuarkSpinType quarkSpinType,
75  int& ncg_had) const;
76  };
77 
78 
79  //-------------------------------------------------------------------------------------------
80  //! Staggered-like fermion actions with derivatives
81  /*! @ingroup actions
82  *
83  * Staggered-like fermion actions
84  */
85  template<typename T, typename P, typename Q>
87  {
88  public:
89  //! Virtual destructor to help with cleanup;
91 
92  //! Override to produce an even-odd prec. linear operator for this action
93  /*! Covariant return rule - override base class function */
95  };
96 
97 
98  //! Even-odd preconditioned Staggered-like fermion actions
99  /*! @ingroup actions
100  *
101  * Even-odd preconditioned like Staggered-like fermion actions
102  */
103  template<typename T, typename P, typename Q>
105  {
106  public:
107  //! Virtual destructor to help with cleanup;
109 
110  //! Override to produce an even-odd prec. linear operator for this action
111  /*! Covariant return rule - override base class function */
113 
114  //! Return quark prop solver, solution of unpreconditioned system
115  /*! Default implementation provided */
117  const GroupXML_t& invParam) const;
118  };
119 
120 }
121 
122 
123 #endif
Base class for quadratic matter actions (e.g., fermions)
Definition: fermact.h:224
Even odd Linear Operator (for staggered like things )
Definition: eo_linop.h:28
Even-odd preconditioned Staggered-like fermion actions.
Definition: fermact.orig.h:714
virtual SystemSolver< T > * qprop(Handle< FermState< T, P, Q > > state, const GroupXML_t &invParam) const
Return quark prop solver, solution of unpreconditioned system.
virtual EvenOddLinearOperator< T, P, Q > * linOp(Handle< FermState< T, P, Q > > state) const =0
Override to produce an even-odd prec. linear operator for this action.
virtual ~EvenOddStaggeredTypeFermAct()
Virtual destructor to help with cleanup;.
Support class for fermion actions and linear operators.
Definition: state.h:94
Class for counted reference semantics.
Definition: handle.h:33
SystemSolver disambiguator.
SystemSolver disambiguator.
Staggered-like fermion actions.
Definition: fermact.orig.h:644
virtual LinOpSystemSolver< T > * invLinOp(Handle< FermState< T, P, Q > > state, const GroupXML_t &invParam) const
Return a linear operator solver for this action to solve M*psi=chi.
virtual MdagMMultiSystemSolverAccumulate< T > * mInvMdagMAcc(Handle< FermState< T, P, Q > > state, const GroupXML_t &invParam) const
Return a multi-shift linear operator solver for this action to solve (MdagM+shift)*psi=chi.
virtual MdagMMultiSystemSolver< T > * mInvMdagM(Handle< FermState< T, P, Q > > state, const GroupXML_t &invParam) const
Return a multi-shift linear operator solver for this action to solve (MdagM+shift)*psi=chi.
virtual LinOpMultiSystemSolver< T > * mInvLinOp(Handle< FermState< T, P, Q > > state, const GroupXML_t &invParam) const
Return a multi-shift linear operator solver for this action to solve (M+shift)*psi=chi.
virtual MdagMSystemSolver< T > * invMdagM(Handle< FermState< T, P, Q > > state, const GroupXML_t &invParam) const
Return a linear operator solver for this action to solve MdagM*psi=chi.
virtual void quarkProp(typename PropTypeTraits< T >::Type_t &q_sol, XMLWriter &xml_out, const typename PropTypeTraits< T >::Type_t &q_src, Handle< FermState< T, P, Q > > state, const GroupXML_t &invParam, QuarkSpinType quarkSpinType, int &ncg_had) const
Given a complete propagator as a source, this does all the inversions needed.
virtual const Real getQuarkMass() const =0
Return the quark mass.
virtual ~StaggeredTypeFermAct()
Virtual destructor to help with cleanup;.
Linear system solvers.
Definition: syssolver.h:34
Unpreconditioned linear operator including derivatives.
Definition: linearop.h:185
Staggered-like fermion actions with derivatives.
Definition: fermact.orig.h:696
virtual UnprecLinearOperator< T, P, Q > * linOp(Handle< FermState< T, P, Q > > state) const =0
Override to produce an even-odd prec. linear operator for this action.
virtual ~UnprecStaggeredTypeFermAct()
Virtual destructor to help with cleanup;.
Linear Operators.
Class structure for fermion actions.
QuarkSpinType
Quark spin type.
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
const WilsonTypeFermAct< multi1d< LatticeFermion > > Handle< const ConnectState > state
Definition: pbg5p_w.cc:28
Hold group xml and type id.
SystemSolver disambiguator.
SystemSolver disambiguator.