Bridge++  Version 1.4.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
forceSmear_HYP_SF.h
Go to the documentation of this file.
1 
14 #ifndef FORCESMEAR_HYP_SF_INCLUDED
15 #define FORCESMEAR_HYP_SF_INCLUDED
16 
17 #include "forceSmear.h"
18 
19 #include "Field/field_G_SF.h"
20 
21 #include "Field/shiftField_lex.h"
22 #include "bridge_complex.h"
23 
24 #include "Smear/projection.h"
25 
26 #include "IO/bridgeIO.h"
27 using Bridge::vout;
28 
30 
41 {
42  public:
43  static const std::string class_name;
44 
45  private:
46  int m_Ndim, m_Nvol;
47  double m_alpha1, m_alpha2, m_alpha3; // HYP smearing parameters
49  std::vector<Field_G> m_U;
50  std::vector<Field_G> m_v1, m_v2;
51  std::vector<Field_G> m_Sigma3, m_Sigma2;
52  std::vector<Field_G> m_iTheta3, m_iTheta2, m_iTheta1;
54 
56  double m_phi[3];
58  double m_phipr[3];
59 
61 
62  public:
64  : ForceSmear(), m_proj(proj)
65  {
66  init();
67  }
68 
70  : ForceSmear(), m_proj(proj.get())
71  {
72  init();
73  }
74 
75  // ~ForceSmear_HYP_SF(){ };
76 
77  void set_parameters(const Parameters& params);
78  void set_parameters(double alpha1, double alpha2, double alpha3, double *phi, double *phipr);
79 
80  void force_udiv(Field_G& Sigma, const Field_G& Sigma_p, const Field_G& U);
81 
82  // old interface
83  //Field force_udiv(const Field_G& Sigma, const Field_G& U);
84 
85  private:
86  void init();
87 
88  void force_step3(Field_G&, const Field_G&);
89  void force_step2(Field_G&);
90  void force_step1(Field_G&);
91 
92  void force_each(Field_G&, const Field_G&, const Field_G&,
93  const Field_G&, const Field_G&, int mu, int nu);
94 
95  void smear_step1();
96  void smear_step2();
97 
98  void staple(Field_G&, const Field_G&, const Field_G&,
99  int mu, int nu);
100 
101  int idx1(int mu, int nu, int rho)
102  {
103  int sig = 6 - mu - nu - rho;
104 
105  if (sig > mu) --sig;
106  return mu + m_Ndim * sig;
107  }
108 
109  int idx1b(int mu, int nu, int rho)
110  {
111  if (nu > mu) --nu;
112  if (rho > mu) --rho;
113  if (rho > nu) --rho;
114  return mu + m_Ndim * (nu + (m_Ndim - 1) * rho);
115  }
116 
117  int idx2(int mu, int nu)
118  {
119  if (nu > mu) --nu;
120  return mu + m_Ndim * nu;
121  }
122 
123  int size1()
124  {
125  return m_Ndim * (m_Ndim - 1);
126  }
127 
128  int size1b()
129  {
130  return m_Ndim * (m_Ndim - 1) * (m_Ndim - 2);
131  }
132 
133  int size2()
134  {
135  return m_Ndim * (m_Ndim - 1);
136  }
137 };
138 #endif
SU(N) gauge field class in which a few functions are added for the SF.
Definition: field_G_SF.h:33
static const std::string class_name
BridgeIO vout
Definition: bridgeIO.cpp:495
ForceSmear_HYP_SF(unique_ptr< Projection > &proj)
void force_udiv(Field_G &Sigma, const Field_G &Sigma_p, const Field_G &U)
double m_phi[3]
SF boundary condition at t=0.
std::vector< Field_G > m_iTheta2
std::vector< Field_G > m_Sigma2
Class for parameters.
Definition: parameters.h:46
void force_step2(Field_G &)
void set_parameters(const Parameters &params)
Base class for force calculation of smeared operators.
Definition: forceSmear.h:34
SU(N) gauge field.
Definition: field_G.h:38
std::vector< Field_G > m_iTheta3
std::vector< Field_G > m_v1
int idx2(int mu, int nu)
ShiftField_lex m_shift
std::vector< Field_G > m_Sigma3
Recursive calculation of HYP smeared fermion force with SF BC.
std::vector< Field_G > m_v2
base class for projection operator into gauge group.
Definition: projection.h:31
void staple(Field_G &, const Field_G &, const Field_G &, int mu, int nu)
void force_each(Field_G &, const Field_G &, const Field_G &, const Field_G &, const Field_G &, int mu, int nu)
std::vector< Field_G > m_U
int idx1b(int mu, int nu, int rho)
void force_step3(Field_G &, const Field_G &)
Methods to shift a field in the lexical site index.
int idx1(int mu, int nu, int rho)
double m_phipr[3]
SF boundary condition at t=Nt.
void force_step1(Field_G &)
ForceSmear_HYP_SF(Projection *proj)
std::vector< Field_G > m_iTheta1