Bridge++  Ver. 1.1.x
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
projection_Maximum_SU_N.h
Go to the documentation of this file.
1 
15 #ifndef PROJECTION_MAXIMUM_SU_N_INCLUDED
16 #define PROJECTION_MAXIMUM_SU_N_INCLUDED
17 
18 #include "projection.h"
19 
20 #include "bridgeIO.h"
21 using Bridge::vout;
22 
24 
36 //- parameters class
38 {
39  public:
41 };
42 //- end
43 
45 {
46  private:
47  int m_Niter;
48  double m_Enorm;
49 
50  public:
52  {
53  //- defaults
54  m_Niter = 100;
55  m_Enorm = 1.0e-12;
56  }
57 
59 
60  void set_parameters(const Parameters& params);
61  void set_parameters(const int Niter, const double Enorm);
62 
64  void project(Field_G& U,
65  double alpha,
66  const Field_G& C, const Field_G& Uorg);
67 
69  void force_recursive(Field_G& Xi, Field_G& iTheta,
70  double alpha, const Field_G& Sigmap,
71  const Field_G& C, const Field_G& U);
72 
73  private:
74  //- maximization of ReTr[U^\dag V].
75  void maxTr(Field_G& U, Field_G& V);
76 
77  //- maximization by SU(2) subgroup.
78  void maxTr_SU2(int, int, Field_G&, Field_G&, Field_G&);
79 
80  //- matrix index for convenience.
81  int mindex(int i, int j, int Nc)
82  {
83  return i + j * Nc;
84  }
85 };
86 #endif