Bridge++  Ver. 2.0.2
projection_Maximum_SU_N.h
Go to the documentation of this file.
1 
14 #ifndef PROJECTION_MAXIMUM_SU_N_INCLUDED
15 #define PROJECTION_MAXIMUM_SU_N_INCLUDED
16 
17 #include "projection.h"
18 
19 #include "IO/bridgeIO.h"
20 using Bridge::vout;
21 
23 
37 {
38  public:
39  static const std::string class_name;
40 
41  private:
43 
44  int m_Niter;
45  double m_Enorm;
46 
47  public:
49  : m_vl(CommonParameters::Vlevel())
50  {
51  //- defaults
52  m_Niter = 100;
53  m_Enorm = 1.0e-12;
54  }
55 
57  : m_vl(CommonParameters::Vlevel())
58  {
59  //- defaults
60  m_Niter = 100;
61  m_Enorm = 1.0e-12;
62 
63  set_parameters(params);
64  }
65 
67 
68  void set_parameters(const Parameters& params);
69  void set_parameters(const int Niter, const double Enorm);
70 
71  void get_parameters(Parameters& params) const;
72 
74  void project(Field_G& U,
75  const double alpha,
76  const Field_G& C, const Field_G& Uorg);
77 
79  void force_recursive(Field_G& Xi, Field_G& iTheta,
80  const double alpha, const Field_G& Sigmap,
81  const Field_G& C, const Field_G& U);
82 
83  private:
84  //- maximization of ReTr[U^\dag V].
85  void maxTr(Field_G& U, const Field_G& V);
86 
87  //- maximization by SU(2) subgroup.
88  void maxTr_SU2(const int, const int, Field_G&, Field_G&, Field_G&);
89 
90  //- matrix index for convenience.
91  int mindex(const int i, const int j, const int Nc)
92  {
93  return i + j * Nc;
94  }
95 
96 #ifdef USE_FACTORY
97  private:
98  static Projection *create_object()
99  {
100  return new Projection_Maximum_SU_N();
101  }
102 
103  static Projection *create_object_with_params(const Parameters& params)
104  {
105  return new Projection_Maximum_SU_N(params);
106  }
107 
108  public:
109  static bool register_factory()
110  {
111  bool init = true;
112  init &= Projection::Factory::Register("Maximum_SU_N", create_object);
113  init &= Projection::Factory_params::Register("Maximum_SU_N", create_object_with_params);
114  return init;
115  }
116 #endif
117 };
118 #endif
bridgeIO.h
CommonParameters
Common parameter class: provides parameters as singleton.
Definition: commonParameters.h:42
Parameters
Class for parameters.
Definition: parameters.h:46
Projection_Maximum_SU_N::maxTr_SU2
void maxTr_SU2(const int, const int, Field_G &, Field_G &, Field_G &)
Definition: projection_Maximum_SU_N.cpp:209
Projection_Maximum_SU_N::~Projection_Maximum_SU_N
~Projection_Maximum_SU_N()
Definition: projection_Maximum_SU_N.h:66
projection.h
Projection_Maximum_SU_N::m_vl
Bridge::VerboseLevel m_vl
Definition: projection_Maximum_SU_N.h:42
Projection_Maximum_SU_N::get_parameters
void get_parameters(Parameters &params) const
Definition: projection_Maximum_SU_N.cpp:51
Projection_Maximum_SU_N
Maximum projection to SU(N) gauge group.
Definition: projection_Maximum_SU_N.h:36
Projection_Maximum_SU_N::force_recursive
void force_recursive(Field_G &Xi, Field_G &iTheta, const double alpha, const Field_G &Sigmap, const Field_G &C, const Field_G &U)
force calculation: invalid in this class.
Definition: projection_Maximum_SU_N.cpp:109
Projection_Maximum_SU_N::project
void project(Field_G &U, const double alpha, const Field_G &C, const Field_G &Uorg)
projection U = P[alpha, C, Uorg]
Definition: projection_Maximum_SU_N.cpp:85
Projection_Maximum_SU_N::mindex
int mindex(const int i, const int j, const int Nc)
Definition: projection_Maximum_SU_N.h:91
Projection_Maximum_SU_N::set_parameters
void set_parameters(const Parameters &params)
Definition: projection_Maximum_SU_N.cpp:25
Projection_Maximum_SU_N::m_Enorm
double m_Enorm
convergence criterion of maximization
Definition: projection_Maximum_SU_N.h:45
Projection_Maximum_SU_N::Projection_Maximum_SU_N
Projection_Maximum_SU_N()
Definition: projection_Maximum_SU_N.h:48
Projection
base class for projection operator into gauge group.
Definition: projection.h:30
Projection_Maximum_SU_N::Projection_Maximum_SU_N
Projection_Maximum_SU_N(const Parameters &params)
Definition: projection_Maximum_SU_N.h:56
Projection_Maximum_SU_N::maxTr
void maxTr(Field_G &U, const Field_G &V)
Definition: projection_Maximum_SU_N.cpp:119
Projection_Maximum_SU_N::class_name
static const std::string class_name
Definition: projection_Maximum_SU_N.h:39
Bridge::VerboseLevel
VerboseLevel
Definition: bridgeIO.h:42
Field_G
SU(N) gauge field.
Definition: field_G.h:38
Projection_Maximum_SU_N::m_Niter
int m_Niter
maximum iteration of maximization steps
Definition: projection_Maximum_SU_N.h:44
Bridge::vout
BridgeIO vout
Definition: bridgeIO.cpp:512