1
0
mirror of https://github.com/paboyle/Grid.git synced 2025-06-17 23:37:06 +01:00

Hadrons: support for twisted boundary conditions

This commit is contained in:
2018-11-12 17:16:18 +00:00
parent f3f24b3017
commit 8e0d2f3402
10 changed files with 39 additions and 18 deletions

View File

@ -47,7 +47,9 @@ public:
GRID_SERIALIZABLE_CLASS_MEMBERS(WilsonPar,
std::string, gauge,
double , mass,
std::string, boundary);
std::string, boundary,
std::string, string,
std::string, twist);
};
template <typename FImpl>
@ -113,8 +115,9 @@ void TWilson<FImpl>::setup(void)
auto &U = envGet(GaugeField, par().gauge);
auto &grid = *envGetGrid(FermionField);
auto &gridRb = *envGetRbGrid(FermionField);
std::vector<Complex> boundary = strToVec<Complex>(par().boundary);
typename WilsonFermion<FImpl>::ImplParams implParams(boundary);
typename WilsonFermion<FImpl>::ImplParams implParams;
implParams.boundary_phases = strToVec<Complex>(par().boundary);
implParams.twist_n_2pi_L = strToVec<Real>(par().twist);
envCreateDerived(FMat, WilsonFermion<FImpl>, getName(), 1, U, grid, gridRb,
par().mass, implParams);
}