CHROMA
unprec_parwilson_linop_w.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 /*! \file
3  * \brief Unpreconditioned Wilson fermion linear operator with parity breaking term
4  */
5 
6 #ifndef __unprec_parwilson_linop_w_h__
7 #define __unprec_parwilson_linop_w_h__
8 
9 #include "linearop.h"
11 
12 
13 namespace Chroma
14 {
15  //! Unpreconditioned Wilson-Dirac operator with parity breaking term
16  /*!
17  * \ingroup linop
18  *
19  * This routine is specific to Wilson fermions!
20  *
21  * ~ ~+
22  * This subroutine applies the unpreconditioned matrix M or M the std::vector
23  * Psi,
24  *
25  * { ~
26  * { M(U) . Psi if ISign = PLUS
27  * Chi = {
28  * { ~ +
29  * { M(U) . Psi if ISign = MINUS
30 
31  * Algorithm:
32  *
33  *
34  * The kernel for Wilson fermions with a parity breaking term is
35  *
36  * M = (d+M) + i*H*gamma_5 - (1/2) D'
37  */
38 
39  class UnprecParWilsonLinOp : public UnprecLinearOperator<LatticeFermion,
40  multi1d<LatticeColorMatrix>, multi1d<LatticeColorMatrix> >
41  {
42  public:
43  // Typedefs to save typing
44  typedef LatticeFermion T;
45  typedef multi1d<LatticeColorMatrix> P;
46  typedef multi1d<LatticeColorMatrix> Q;
47 
48  //! Partial constructor
50 
51  //! Full constructor
53  const Real& Mass_, const Real& H_)
54  {create(fs,Mass_,H_);}
55 
56  //! Destructor is automatic
58 
59  //! Only defined on the odd subset
60  const Subset& subset() const {return all;}
61 
62  //! Return the fermion BC object for this linear operator
63  const FermBC<T,P,Q>& getFermBC() const {return D.getFermBC();}
64 
65  //! Creation routine
66  void create(Handle< FermState<T,P,Q> > fs,
67  const Real& Mass_, const Real& H_);
68 
69  //! Apply the operator onto a source std::vector
70  void operator() (LatticeFermion& chi, const LatticeFermion& psi, enum PlusMinus isign) const;
71 
72  //! Derivative of unpreconditioned ParWilson dM/dU
73  void deriv(multi1d<LatticeColorMatrix>& ds_u,
74  const LatticeFermion& chi, const LatticeFermion& psi,
75  enum PlusMinus isign) const;
76 
77  private:
78  Real Mass;
79  Real H;
80 // multi1d<LatticeColorMatrix> u;
82  };
83 
84 } // End Namespace Chroma
85 
86 
87 #endif
Base class for all fermion action boundary conditions.
Definition: fermbc.h:20
Support class for fermion actions and linear operators.
Definition: state.h:94
Class for counted reference semantics.
Definition: handle.h:33
General Wilson-Dirac dslash.
Definition: lwldslash_w.h:48
const FermBC< T, P, Q > & getFermBC() const
Return the fermion BC object for this linear operator.
Definition: lwldslash_w.h:92
Unpreconditioned linear operator including derivatives.
Definition: linearop.h:185
Unpreconditioned Wilson-Dirac operator with parity breaking term.
multi1d< LatticeColorMatrix > P
const Subset & subset() const
Only defined on the odd subset.
UnprecParWilsonLinOp(Handle< FermState< T, P, Q > > fs, const Real &Mass_, const Real &H_)
Full constructor.
multi1d< LatticeColorMatrix > Q
~UnprecParWilsonLinOp()
Destructor is automatic.
void deriv(multi1d< LatticeColorMatrix > &ds_u, const LatticeFermion &chi, const LatticeFermion &psi, enum PlusMinus isign) const
Derivative of unpreconditioned ParWilson dM/dU.
const FermBC< T, P, Q > & getFermBC() const
Return the fermion BC object for this linear operator.
UnprecParWilsonLinOp()
Partial constructor.
Include possibly optimized Wilson dslash.
void create(Handle< FermState< T, P, Q > > fs, const Real &Mass_, const Real &H_)
Creation routine.
void operator()(LatticeFermion &chi, const LatticeFermion &psi, enum PlusMinus isign) const
Apply the operator onto a source std::vector.
Linear Operators.
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
multi1d< LatticeFermion > chi(Ncb)
LatticeFermion psi
Definition: mespbg5p_w.cc:35