CHROMA
lcm_integrator_leaps.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 
3 #ifndef LCM_INTEGRATOR_LEAPS
4 #define LCM_INTEGRATOR_LEAPS
5 
6 #include "chromabase.h"
8 #include "handle.h"
9 
10 #include "singleton.h"
13 namespace Chroma
14 {
15 
16  //! LatticeColorMatrix integrator leaps
17  /*! @ingroup integrator */
18  namespace LCMMDIntegratorSteps
19  {
21  public:
23  step_factors.resize(Nd);
24  for(int mu=0; mu < Nd; mu++) {
25  step_factors[mu] = Real(1);
26  }
27  }
28 
29  inline void
30  setAnisoStepSize(int t_dir_, const Real& step_factor_) {
31  QDPIO::cout << "Setting dir " << t_dir_ << " to aniso factor " << step_factor_ << " originally " << Real(1)/(step_factor_*step_factor_) << std::endl;
32  if( (t_dir_ >= 0) && (t_dir_ < Nd) ) {
33  step_factors[t_dir_] = step_factor_;
34  }
35  else {
36  QDPIO::cout << "Error t_dir must be between 0 and " << Nd-1 << ". It is " << t_dir_ << std::endl;
37  QDP_abort(1);
38  }
39  }
40 
41  inline Real
42  getStepSizeFactor(int t_dir) {
43  if( (t_dir < 0) || (t_dir >= Nd) ) {
44  QDPIO::cout << "Error t_dir must be between 0 and " << Nd-1 << ". It is " << t_dir << std::endl;
45  QDP_abort(1);
46  }
47  return step_factors[t_dir];
48  }
49 
50  private:
51  multi1d<Real> step_factors;
52  };
53 
55 
56  //! Leap with Q (with all monomials)
57  /*! @ingroup integrator */
58  void leapQ(const Real& dt,
59  AbsFieldState<multi1d<LatticeColorMatrix>,
60  multi1d<LatticeColorMatrix> >& s);
61 
62 
63  // LeapP update for just a list of Monomials in an array of handles
64  void leapP(const multi1d< IntegratorShared::MonomialPair >& monomials,
65 
66  const Real& dt,
67 
68  AbsFieldState<multi1d<LatticeColorMatrix>,
69  multi1d<LatticeColorMatrix> >& s);
70 
71 
72 
73 
74  } // End Namespace MDIntegratorSteps
75 
76 } // End Namespace Chroma
77 
78 #endif
Abstract Hamiltonian.
Primary include file for CHROMA library code.
Abstract field state.
Definition: field_state.h:27
void setAnisoStepSize(int t_dir_, const Real &step_factor_)
EXTERN Real dt
int mu
Definition: cool.cc:24
Field state.
void leapQ(const Real &dt, AbsFieldState< multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > > &s)
Leap with Q (with all monomials)
Class for counted reference semantics.
Nd
Definition: meslate.cc:74
SingletonHolder< AnisoStepSizeArray > theAnisoStepSizeArray
void leapP(const multi1d< IntegratorShared::MonomialPair > &monomials, const Real &dt, AbsFieldState< multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > > &s)
LeapP for just a selected list of monomials.
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
multi1d< LatticeFermion > s(Ncb)
Singleton support.