1
0
mirror of https://github.com/paboyle/Grid.git synced 2024-09-20 09:15:38 +01:00

Namespace

This commit is contained in:
paboyle 2018-01-14 23:49:11 +00:00
parent 041d9137c0
commit eda4fd9912

View File

@ -27,66 +27,60 @@ with this program; if not, write to the Free Software Foundation, Inc.,
See the full license in the file "LICENSE" in the top level distribution See the full license in the file "LICENSE" in the top level distribution
directory directory
*************************************************************************************/ *************************************************************************************/
/* END LEGAL */ /* END LEGAL */
#ifndef GRID_QCD_ACTION_PARAMS_H #ifndef GRID_QCD_ACTION_PARAMS_H
#define GRID_QCD_ACTION_PARAMS_H #define GRID_QCD_ACTION_PARAMS_H
namespace Grid { NAMESPACE_BEGIN(Grid);
namespace QCD {
// These can move into a params header and be given MacroMagic serialisation // These can move into a params header and be given MacroMagic serialisation
struct GparityWilsonImplParams { struct GparityWilsonImplParams {
bool overlapCommsCompute; bool overlapCommsCompute;
std::vector<int> twists; std::vector<int> twists;
GparityWilsonImplParams() : twists(Nd, 0), overlapCommsCompute(false){}; GparityWilsonImplParams() : twists(Nd, 0), overlapCommsCompute(false){};
}; };
struct WilsonImplParams { struct WilsonImplParams {
bool overlapCommsCompute; bool overlapCommsCompute;
std::vector<Complex> boundary_phases; std::vector<Complex> boundary_phases;
WilsonImplParams() : overlapCommsCompute(false) { WilsonImplParams() : overlapCommsCompute(false) {
boundary_phases.resize(Nd, 1.0); boundary_phases.resize(Nd, 1.0);
};
WilsonImplParams(const std::vector<Complex> phi)
: boundary_phases(phi), overlapCommsCompute(false) {}
}; };
WilsonImplParams(const std::vector<Complex> phi)
: boundary_phases(phi), overlapCommsCompute(false) {}
};
struct StaggeredImplParams { struct StaggeredImplParams {
StaggeredImplParams() {}; StaggeredImplParams() {};
}; };
struct OneFlavourRationalParams : Serializable { struct OneFlavourRationalParams : Serializable {
GRID_SERIALIZABLE_CLASS_MEMBERS(OneFlavourRationalParams, GRID_SERIALIZABLE_CLASS_MEMBERS(OneFlavourRationalParams,
RealD, lo, RealD, lo,
RealD, hi, RealD, hi,
int, MaxIter, int, MaxIter,
RealD, tolerance, RealD, tolerance,
int, degree, int, degree,
int, precision); int, precision);
// MaxIter and tolerance, vectors?? // MaxIter and tolerance, vectors??
// constructor // constructor
OneFlavourRationalParams( RealD _lo = 0.0, OneFlavourRationalParams( RealD _lo = 0.0,
RealD _hi = 1.0, RealD _hi = 1.0,
int _maxit = 1000, int _maxit = 1000,
RealD tol = 1.0e-8, RealD tol = 1.0e-8,
int _degree = 10, int _degree = 10,
int _precision = 64) int _precision = 64)
: lo(_lo), : lo(_lo),
hi(_hi), hi(_hi),
MaxIter(_maxit), MaxIter(_maxit),
tolerance(tol), tolerance(tol),
degree(_degree), degree(_degree),
precision(_precision){}; precision(_precision){};
}; };
}
}
NAMESPACE_END(Grid);
#endif #endif