From 1a5e562bdef350cdc3ac2008b4dc5977c390703d Mon Sep 17 00:00:00 2001 From: ferben Date: Thu, 5 Dec 2019 16:46:58 +0000 Subject: [PATCH] only one FIMPL left! --- .../Modules/MContraction/SigmaToNucleonEye.cc | 2 +- .../MContraction/SigmaToNucleonEye.hpp | 43 +++++++++--------- .../MContraction/SigmaToNucleonNonEye.cc | 2 +- .../MContraction/SigmaToNucleonNonEye.hpp | 45 +++++++++---------- 4 files changed, 43 insertions(+), 49 deletions(-) diff --git a/Hadrons/Modules/MContraction/SigmaToNucleonEye.cc b/Hadrons/Modules/MContraction/SigmaToNucleonEye.cc index 4e938309..ca4bb341 100644 --- a/Hadrons/Modules/MContraction/SigmaToNucleonEye.cc +++ b/Hadrons/Modules/MContraction/SigmaToNucleonEye.cc @@ -4,4 +4,4 @@ using namespace Grid; using namespace Hadrons; using namespace MContraction; -template class Grid::Hadrons::MContraction::TSigmaToNucleonEye; +template class Grid::Hadrons::MContraction::TSigmaToNucleonEye; diff --git a/Hadrons/Modules/MContraction/SigmaToNucleonEye.hpp b/Hadrons/Modules/MContraction/SigmaToNucleonEye.hpp index 781c9d0a..1aa0b9b7 100644 --- a/Hadrons/Modules/MContraction/SigmaToNucleonEye.hpp +++ b/Hadrons/Modules/MContraction/SigmaToNucleonEye.hpp @@ -82,17 +82,14 @@ public: std::string, output); }; -template +template class TSigmaToNucleonEye: public Module { public: - FERM_TYPE_ALIASES(FImpl1, 1); - FERM_TYPE_ALIASES(FImpl2, 2); - FERM_TYPE_ALIASES(FImpl3, 3); - FERM_TYPE_ALIASES(FImpl4, 4); + FERM_TYPE_ALIASES(FImpl,); BASIC_TYPE_ALIASES(ScalarImplCR, Scalar); SINK_TYPE_ALIASES(Scalar); - typedef typename SpinMatrixField1::vector_object::scalar_object SpinMatrix; + typedef typename SpinMatrixField::vector_object::scalar_object SpinMatrix; class Metadata: Serializable { public: @@ -122,28 +119,28 @@ protected: Gamma::Algebra al; }; -MODULE_REGISTER_TMP(SigmaToNucleonEye, ARG(TSigmaToNucleonEye), MContraction); +MODULE_REGISTER_TMP(SigmaToNucleonEye, ARG(TSigmaToNucleonEye), MContraction); /****************************************************************************** * TSigmaToNucleonEye implementation * ******************************************************************************/ // constructor ///////////////////////////////////////////////////////////////// -template -TSigmaToNucleonEye::TSigmaToNucleonEye(const std::string name) +template +TSigmaToNucleonEye::TSigmaToNucleonEye(const std::string name) : Module(name) {} // dependencies/products /////////////////////////////////////////////////////// -template -std::vector TSigmaToNucleonEye::getInput(void) +template +std::vector TSigmaToNucleonEye::getInput(void) { std::vector input = {par().qq_loop, par().qu_spec, par().qd_xf, par().qs_xi, par().sink}; return input; } -template -std::vector TSigmaToNucleonEye::getOutput(void) +template +std::vector TSigmaToNucleonEye::getOutput(void) { std::vector out = {}; @@ -151,15 +148,15 @@ std::vector TSigmaToNucleonEye::get } // setup /////////////////////////////////////////////////////////////////////// -template -void TSigmaToNucleonEye::setup(void) +template +void TSigmaToNucleonEye::setup(void) { - envTmpLat(SpinMatrixField1, "c"); + envTmpLat(SpinMatrixField, "c"); } // execution /////////////////////////////////////////////////////////////////// -template -void TSigmaToNucleonEye::execute(void) +template +void TSigmaToNucleonEye::execute(void) { const Gamma GammaB(Gamma::Algebra::SigmaXZ); // C*gamma_5 const Gamma Id(Gamma::Algebra::Identity); // C*gamma_5 @@ -168,7 +165,7 @@ void TSigmaToNucleonEye::execute(void) LOG(Message) << "' with (Gamma^A,Gamma^B)_sigma = ( Identity, C*gamma_5 ) and (Gamma^A,Gamma^B)_nucl = ( Identity, C*gamma_5 )" << std::endl; LOG(Message) << " using sink " << par().sink << "." << std::endl; - envGetTmp(SpinMatrixField1, c); + envGetTmp(SpinMatrixField, c); std::vector buf; std::vector result; @@ -178,10 +175,10 @@ void TSigmaToNucleonEye::execute(void) r.info.gammaA_nucl = Id.g; r.info.gammaB_nucl = GammaB.g; - auto &qq_loop = envGet(PropagatorField1, par().qq_loop); - auto &qu_spec = envGet(SlicedPropagator2, par().qu_spec); - auto &qd_xf = envGet(PropagatorField3, par().qd_xf); - auto &qs_xi = envGet(PropagatorField4, par().qs_xi); + auto &qq_loop = envGet(PropagatorField, par().qq_loop); + auto &qu_spec = envGet(SlicedPropagator, par().qu_spec); + auto &qd_xf = envGet(PropagatorField, par().qd_xf); + auto &qs_xi = envGet(PropagatorField, par().qs_xi); auto qut = qu_spec[par().xf]; for (auto &G: Gamma::gall) { diff --git a/Hadrons/Modules/MContraction/SigmaToNucleonNonEye.cc b/Hadrons/Modules/MContraction/SigmaToNucleonNonEye.cc index 7d5ee247..117541a3 100644 --- a/Hadrons/Modules/MContraction/SigmaToNucleonNonEye.cc +++ b/Hadrons/Modules/MContraction/SigmaToNucleonNonEye.cc @@ -4,4 +4,4 @@ using namespace Grid; using namespace Hadrons; using namespace MContraction; -template class Grid::Hadrons::MContraction::TSigmaToNucleonNonEye; +template class Grid::Hadrons::MContraction::TSigmaToNucleonNonEye; diff --git a/Hadrons/Modules/MContraction/SigmaToNucleonNonEye.hpp b/Hadrons/Modules/MContraction/SigmaToNucleonNonEye.hpp index 58c25e90..cb73af88 100644 --- a/Hadrons/Modules/MContraction/SigmaToNucleonNonEye.hpp +++ b/Hadrons/Modules/MContraction/SigmaToNucleonNonEye.hpp @@ -87,17 +87,14 @@ public: std::string, output); }; -template +template class TSigmaToNucleonNonEye: public Module { public: - FERM_TYPE_ALIASES(FImpl1, 1); - FERM_TYPE_ALIASES(FImpl2, 2); - FERM_TYPE_ALIASES(FImpl3, 3); - FERM_TYPE_ALIASES(FImpl4, 4); + FERM_TYPE_ALIASES(FImpl,); BASIC_TYPE_ALIASES(ScalarImplCR, Scalar); SINK_TYPE_ALIASES(Scalar); - typedef typename SpinMatrixField1::vector_object::scalar_object SpinMatrix; + typedef typename SpinMatrixField::vector_object::scalar_object SpinMatrix; class Metadata: Serializable { public: @@ -127,28 +124,28 @@ protected: Gamma::Algebra al; }; -MODULE_REGISTER_TMP(SigmaToNucleonNonEye, ARG(TSigmaToNucleonNonEye), MContraction); +MODULE_REGISTER_TMP(SigmaToNucleonNonEye, ARG(TSigmaToNucleonNonEye), MContraction); /****************************************************************************** * TSigmaToNucleonNonEye implementation * ******************************************************************************/ // constructor ///////////////////////////////////////////////////////////////// -template -TSigmaToNucleonNonEye::TSigmaToNucleonNonEye(const std::string name) +template +TSigmaToNucleonNonEye::TSigmaToNucleonNonEye(const std::string name) : Module(name) {} // dependencies/products /////////////////////////////////////////////////////// -template -std::vector TSigmaToNucleonNonEye::getInput(void) +template +std::vector TSigmaToNucleonNonEye::getInput(void) { std::vector input = {par().qu_xi, par().qu_xf, par().qu_spec, par().qd_xf, par().qs_xi, par().sink}; return input; } -template -std::vector TSigmaToNucleonNonEye::getOutput(void) +template +std::vector TSigmaToNucleonNonEye::getOutput(void) { std::vector out = {}; @@ -156,15 +153,15 @@ std::vector TSigmaToNucleonNonEye:: } // setup /////////////////////////////////////////////////////////////////////// -template -void TSigmaToNucleonNonEye::setup(void) +template +void TSigmaToNucleonNonEye::setup(void) { - envTmpLat(SpinMatrixField1, "c"); + envTmpLat(SpinMatrixField, "c"); } // execution /////////////////////////////////////////////////////////////////// -template -void TSigmaToNucleonNonEye::execute(void) +template +void TSigmaToNucleonNonEye::execute(void) { const Gamma GammaB(Gamma::Algebra::SigmaXZ); // C*gamma_5 const Gamma Id(Gamma::Algebra::Identity); // C*gamma_5 @@ -173,7 +170,7 @@ void TSigmaToNucleonNonEye::execute(void) LOG(Message) << "' with (Gamma^A,Gamma^B)_sigma = ( Identity, C*gamma_5 ) and (Gamma^A,Gamma^B)_nucl = ( Identity, C*gamma_5 )" << std::endl; LOG(Message) << " using sink " << par().sink << "." << std::endl; - envGetTmp(SpinMatrixField1, c); + envGetTmp(SpinMatrixField, c); std::vector buf; std::vector result; @@ -183,11 +180,11 @@ void TSigmaToNucleonNonEye::execute(void) r.info.gammaA_nucl = Id.g; r.info.gammaB_nucl = GammaB.g; - auto &qu_xi = envGet(PropagatorField1, par().qu_xi); - auto &qu_xf = envGet(PropagatorField1, par().qu_xf); - auto &qu_spec = envGet(SlicedPropagator2, par().qu_spec); - auto &qd_xf = envGet(PropagatorField3, par().qd_xf); - auto &qs_xi = envGet(PropagatorField4, par().qs_xi); + auto &qu_xi = envGet(PropagatorField, par().qu_xi); + auto &qu_xf = envGet(PropagatorField, par().qu_xf); + auto &qu_spec = envGet(SlicedPropagator, par().qu_spec); + auto &qd_xf = envGet(PropagatorField, par().qd_xf); + auto &qs_xi = envGet(PropagatorField, par().qs_xi); auto qut = qu_spec[par().xf]; for (auto &G: Gamma::gall) {