CHROMA
avp_bglf_solver.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 /*! \file
3  * \brief DWF/Bluegene single-prec solver
4  */
5 
6 #ifndef AVP_BGLF_SOLVER_H
7 #define AVP_BGLF_SOLVER_H
8 
9 #include "chromabase.h"
10 #include "avp_inverter_interface.h"
11 
12 extern "C" {
13  struct MIT_bluelightf_DWF_Gauge;
14  struct MIT_bluelightf_DWF_Fermion;
15 };
16 
17 namespace Chroma
18 {
19  //! Bluegene single-prec solver
20  /*!
21  * \ingroup qprop
22  *
23  * @{
24  */
25  namespace AVPSolver
26  {
27  //! DWF solver for Bluegene
28  class BGLDWFSolverF : public AVPSolverInterface< MIT_bluelightf_DWF_Gauge, MIT_bluelightf_DWF_Fermion >
29  {
30  public:
31  protected:
32  MIT_bluelightf_DWF_Fermion* loadFermionRHS(const void* OuterFermion) const;
33  MIT_bluelightf_DWF_Fermion* loadFermionGuess(const void *OuterFermion) const;
34  MIT_bluelightf_DWF_Fermion* allocateFermion(void) const ;
35  void saveFermionSolver(void *OuterFermion,
36  MIT_bluelightf_DWF_Fermion* CGFermion) const;
37 
38  void saveFermionOperator(void *OuterFermion,
39  MIT_bluelightf_DWF_Fermion* CGFermion) const;
40 
41  void deleteFermion(MIT_bluelightf_DWF_Fermion* ptr) const;
42  int cgInternal(MIT_bluelightf_DWF_Fermion *psi,
43  double *out_eps,
44  int *out_iter,
45  double M,
46  double m_f,
47  const MIT_bluelightf_DWF_Fermion *x0,
48  const MIT_bluelightf_DWF_Fermion *eta,
49  double eps,
50  int min_iter,
51  int max_iter) const;
52  public:
53  void loadGauge(const void *u,
54  const void *v);
55 
56  void deleteGauge(void);
57 
58  // Init the system -- Constructor call?
59  int init(const int lattice[5],
60  void *(*allocator)(size_t size),
61  void (*deallocator)(void *));
62 
63  // Finalize - destructor call
64  void fini(void);
65  private:
66  MIT_bluelightf_DWF_Gauge *g;
67  };
68  }
69 
70  /*! @} */ // end of group qprop
71 }
72 
73 #endif
Base class for AVP's DWF solver interface.
Primary include file for CHROMA library code.
DWF solver for Bluegene.
void saveFermionOperator(void *OuterFermion, MIT_bluelightf_DWF_Fermion *CGFermion) const
void deleteFermion(MIT_bluelightf_DWF_Fermion *ptr) const
int init(const int lattice[5], void *(*allocator)(size_t size), void(*deallocator)(void *))
void saveFermionSolver(void *OuterFermion, MIT_bluelightf_DWF_Fermion *CGFermion) const
void loadGauge(const void *u, const void *v)
MIT_bluelightf_DWF_Fermion * loadFermionGuess(const void *OuterFermion) const
MIT_bluelightf_DWF_Fermion * loadFermionRHS(const void *OuterFermion) const
MIT_bluelightf_DWF_Gauge * g
MIT_bluelightf_DWF_Fermion * allocateFermion(void) const
int cgInternal(MIT_bluelightf_DWF_Fermion *psi, double *out_eps, int *out_iter, double M, double m_f, const MIT_bluelightf_DWF_Fermion *x0, const MIT_bluelightf_DWF_Fermion *eta, double eps, int min_iter, int max_iter) const
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
static multi1d< LatticeColorMatrix > u
LatticeFermion psi
Definition: mespbg5p_w.cc:35
LatticeFermion eta
Definition: mespbg5p_w.cc:37