Bridge++  Version 1.5.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
forceSmear_APE_SF.h
Go to the documentation of this file.
1 
14 #ifndef FORCESMEAR_APE_ALT_INCLUDED
15 #define FORCESMEAR_APE_ALT_INCLUDED
16 
17 #include "forceSmear.h"
18 
19 #include "Field/field_G_SF.h"
20 #include "Field/shiftField_lex.h"
21 
22 #include "Smear/smear_APE_SF.h"
23 #include "Smear/projection.h"
24 
25 #include "IO/bridgeIO.h"
26 using Bridge::vout;
27 
29 
40 {
41  public:
42  static const std::string class_name;
43 
44  private:
45  int m_Ndim, m_Nvol;
46  std::vector<double> m_rho;
49  std::vector<Field_G> m_U;
50  std::vector<Field_G> m_iTheta;
51 
53  double m_phi[3];
55  double m_phipr[3];
56 
58 
59  public:
61  : ForceSmear(), m_proj(proj)
62  {
63  init();
64  }
65 
67  : ForceSmear(), m_proj(proj.get())
68  {
69  init();
70  }
71 
72  // ~ForceSmear_APE_SF(){
73  // };
74 
75  void set_parameters(const Parameters& params);
76 
77  void set_parameters(const double rho1, double *phi, double *phipr);
78  void set_parameters(const std::vector<double>& rho, 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  double rho(const int mu, const int nu)
89  {
90  return m_rho[mu + nu * m_Ndim];
91  }
92 
93  void force_each(Field_G&,
94  const Field_G&, const Field_G&,
95  const Field_G&, const Field_G&, const int mu, const int nu);
96 
97  void staple(Field_G&,
98  const Field_G&, const Field_G&,
99  const int mu, const int nu);
100 
101 #ifdef USE_FACTORY
102  private:
103  static ForceSmear *create_object(Projection *proj)
104  {
105  return new ForceSmear_APE_SF(proj);
106  }
107 
108  public:
109  static bool register_factory()
110  {
111  return ForceSmear::Factory::Register("APE_SF", create_object);
112  }
113 #endif
114 };
115 #endif
SU(N) gauge field class in which a few functions are added for the SF.
Definition: field_G_SF.h:33
BridgeIO vout
Definition: bridgeIO.cpp:503
void force_each(Field_G &, const Field_G &, const Field_G &, const Field_G &, const Field_G &, const int mu, const int nu)
void force_udiv(Field_G &Sigma, const Field_G &Sigma_p, const Field_G &U)
static const std::string class_name
void set_parameters(const Parameters &params)
double rho(const int mu, const int nu)
std::vector< Field_G > m_iTheta
Class for parameters.
Definition: parameters.h:46
ForceSmear_APE_SF(Projection *proj)
Base class for force calculation of smeared operators.
Definition: forceSmear.h:34
std::vector< double > m_rho
SU(N) gauge field.
Definition: field_G.h:38
double m_phi[3]
SF boundary condition at t=0.
ShiftField_lex m_shift
void staple(Field_G &, const Field_G &, const Field_G &, const int mu, const int nu)
base class for projection operator into gauge group.
Definition: projection.h:30
std::vector< Field_G > m_U
double m_phipr[3]
SF boundary condition at t=Nt.
Methods to shift a field in the lexical site index.
Recursive calculation for APE smeared fermion force.
ForceSmear_APE_SF(unique_ptr< Projection > &proj)