Bridge++  Ver. 2.0.2
aforce_F_Smeared.h
Go to the documentation of this file.
1 
10 #ifndef AFORCE_F_SMEARED_INCLUDED
11 #define AFORCE_F_SMEARED_INCLUDED
12 
13 #include "lib/Force/Fermion/aforce_F.h"
14 #include "lib/Smear/forceSmear.h"
16 #include "lib/Fopr/afopr.h"
17 
18 
20 
32 template<typename AFIELD>
33 class AForce_F_Smeared : public AForce_F<AFIELD>
34 {
35  public:
36  typedef typename AFIELD::real_t real_t;
37  using AForce_F<AFIELD>::m_vl;
38  using AForce_F<AFIELD>::m_U;
39  using AForce_F<AFIELD>::m_Ucp;
40  static const std::string class_name;
41 
42  private:
43  AForce_F<AFIELD> *m_force;
45  // Note that this template version always smear the force
46  // voa Director_Smear.
47 
48  public:
49  AForce_F_Smeared(AForce_F<AFIELD> *force,
50  Director_Smear *director_smear)
51  : AForce_F<AFIELD>(), m_force(force), m_director_smear(director_smear)
52  { init(); }
53 
54  void set_parameters(const Parameters&);
55 
56  void set_config(Field *U);
57 
58  void set_mode(const std::string& mode)
59  { m_force->set_mode(mode); }
60 
61  void force_udiv(AFIELD& force, const AFIELD& eta);
62 
63  void force_udiv1(AFIELD& force, const AFIELD& zeta, const AFIELD& eta);
64 
65  private:
67  void init();
68 
69  void mult_jacobian(Field_G& force);
70 
71 #ifdef USE_FACTORY
72  private:
73  static AForce_F<AFIELD> *create_object_with_force_director(
74  AForce_F<AFIELD> *fopr, Director *director)
75  { return new AForce_F_Smeared(fopr, (Director_Smear *)director); }
76 
77  public:
78  static bool register_factory()
79  {
80  bool init1 = AForce_F<AFIELD>::Factory_force_director::Register(
81  "Smeared", create_object_with_force_director);
82  return init1;
83  }
84 #endif
85 };
86 #endif
director_Smear.h
AForce_F_Smeared::real_t
AFIELD::real_t real_t
Definition: aforce_F_Smeared.h:36
Parameters
Class for parameters.
Definition: parameters.h:46
AForce_F_Smeared
Force calculation for smeared fermion operators.
Definition: aforce_F_Smeared.h:33
AForce_F_Smeared::m_force
AForce_F< AFIELD > * m_force
Definition: aforce_F_Smeared.h:43
AForce_F_Smeared::AForce_F_Smeared
AForce_F_Smeared(AForce_F< AFIELD > *force, Director_Smear *director_smear)
Definition: aforce_F_Smeared.h:49
AForce_F_Smeared::m_director_smear
Director_Smear * m_director_smear
Definition: aforce_F_Smeared.h:44
Field::real_t
double real_t
Definition: field.h:51
AForce_F_Smeared::force_udiv1
void force_udiv1(AFIELD &force, const AFIELD &zeta, const AFIELD &eta)
Definition: aforce_F_Smeared-tmpl.h:98
AForce_F_Smeared::set_mode
void set_mode(const std::string &mode)
Definition: aforce_F_Smeared.h:58
AForce_F_Smeared::init
void init()
initial setup.
Definition: aforce_F_Smeared-tmpl.h:18
Director_Smear
Manager of smeared configurations.
Definition: director_Smear.h:39
AForce_F_Smeared::force_udiv
void force_udiv(AFIELD &force, const AFIELD &eta)
Definition: aforce_F_Smeared-tmpl.h:55
AForce_F_Smeared::set_parameters
void set_parameters(const Parameters &)
Definition: aforce_F_Smeared-tmpl.h:45
Director
Manager of commonly used data object in HMC.
Definition: director.h:37
Field
Container of Field-type object.
Definition: field.h:46
afopr.h
Field_G
SU(N) gauge field.
Definition: field_G.h:38
AForce_F_Smeared::class_name
static const std::string class_name
Definition: aforce_F_Smeared.h:40
AForce_F_Smeared::mult_jacobian
void mult_jacobian(Field_G &force)
Definition: aforce_F_Smeared-tmpl.h:141
AForce_F_Smeared::set_config
void set_config(Field *U)
Definition: aforce_F_Smeared-tmpl.h:26