Bridge++  Version 1.4.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
solver_BiCGStab_L_Cmplx.h
Go to the documentation of this file.
1 
14 #ifndef SOLVER_BICGSTAB_L_CMPLX_INCLUDED
15 #define SOLVER_BICGSTAB_L_CMPLX_INCLUDED
16 
17 #include "solver.h"
18 
19 #include "IO/bridgeIO.h"
20 using Bridge::vout;
21 
22 
24 
41 {
42  public:
43  static const std::string class_name;
44 
45  private:
47 
49  double m_Stop_cond;
50 
51  int m_N_L;
52  double m_Tol_L;
53 
54  //- working area
56 
57  std::vector<Field> m_u, m_r;
59 
62 
63  public:
65  : Solver(), m_fopr(fopr)
66  {
67  m_Nrestart_count = 0;
68  m_Nconv_count = 0;
69  }
70 
72  : Solver(), m_fopr(fopr.get())
73  {
74  m_Nrestart_count = 0;
75  m_Nconv_count = 0;
76  }
77 
79 
80  void set_parameters(const Parameters& params);
81  void set_parameters(const int Niter, const int Nrestart, const double Stop_cond);
82  void set_parameters_L(const int N_L);
83 
84  void solve(Field& solution, const Field& source,
85  int& Nconv, double& diff);
86 
87  Fopr *get_fopr() { return m_fopr; }
88 
89  double flop_count();
90 
91  private:
92  void reset_field(const Field&);
93 
94  void solve_init(const Field&, double&);
95  void solve_step(double&);
96 
97  int index_ij(int i, int j)
98  {
99  return i + m_N_L * j;
100  }
101 };
102 #endif
BridgeIO vout
Definition: bridgeIO.cpp:495
static const std::string class_name
void set_parameters_L(const int N_L)
BiCGStab(L) algorithm.
Container of Field-type object.
Definition: field.h:39
void solve_init(const Field &, double &)
Class for parameters.
Definition: parameters.h:46
void set_parameters(const Parameters &params)
Base class for linear solver class family.
Definition: solver.h:37
Solver_BiCGStab_L_Cmplx(unique_ptr< Fopr > &fopr)
Base class of fermion operator family.
Definition: fopr.h:47
void solve(Field &solution, const Field &source, int &Nconv, double &diff)