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

cleaning up requested by Julian

This commit is contained in:
Alessandro Lupo 2023-05-02 13:31:17 +01:00
parent 7b3b7093fa
commit 86b02c3cd8
4 changed files with 6 additions and 10 deletions

View File

@ -340,12 +340,12 @@ class GaugeGroup {
template <class vtype, int N> template <class vtype, int N>
static void ProjectOnGaugeGroup(iVector<vtype,N> &r) { static void ProjectOnGaugeGroup(iVector<vtype,N> &r) {
r = ProjectOnGaugeGroup(r, group_name()); ProjectOnGaugeGroup(r, group_name());
} }
template <class vtype,int N, typename std::enable_if< GridTypeMapper<vtype>::TensorLevel == 0 >::type * =nullptr> template <class vtype,int N, typename std::enable_if< GridTypeMapper<vtype>::TensorLevel == 0 >::type * =nullptr>
static void ProjectOnGaugeGroup(iMatrix<vtype,N> &arg) { static void ProjectOnGaugeGroup(iMatrix<vtype,N> &arg) {
arg = ProjectOnGaugeGroup(arg, group_name()); ProjectOnGaugeGroup(arg, group_name());
} }
template <int N> // reunitarise, resimplectify... previously ProjectSUn template <int N> // reunitarise, resimplectify... previously ProjectSUn
@ -428,7 +428,6 @@ static void ProjectSUn(
} }
} }
// Explicit specialisation for SU(3).
// Explicit specialisation for SU(3). // Explicit specialisation for SU(3).
static void ProjectSU3( static void ProjectSU3(
Lattice<iScalar<iScalar<iMatrix<vComplexD, 3> > > > &Umu) { Lattice<iScalar<iScalar<iMatrix<vComplexD, 3> > > > &Umu) {

View File

@ -68,8 +68,7 @@ public:
for (int a = 0; a < Dimension; a++) { for (int a = 0; a < Dimension; a++) {
tmp = ta[a] * ta[Index] - ta[Index] * ta[a]; tmp = ta[a] * ta[Index] - ta[Index] * ta[a];
for (int b = 0; b < (ncolour * ncolour - 1); b++) { for (int b = 0; b < (ncolour * ncolour - 1); b++) {
iSUnMatrix<cplx> tmp1 = iSUnMatrix<cplx> tmp1 = 2.0 * tmp * ta[b]; // 2.0 from the normalization
2.0 * tmp * ta[b]; // 2.0 from the normalization
Complex iTr = TensorRemove(timesI(trace(tmp1))); Complex iTr = TensorRemove(timesI(trace(tmp1)));
//iAdjTa()()(b, a) = iTr; //iAdjTa()()(b, a) = iTr;
iAdjTa()()(a, b) = iTr; iAdjTa()()(a, b) = iTr;

View File

@ -126,8 +126,7 @@ public:
template <class cplx> template <class cplx>
static void generator(int Index, iSUnTwoIndexMatrix<cplx> &i2indTa) { static void generator(int Index, iSUnTwoIndexMatrix<cplx> &i2indTa) {
Vector<iSUnMatrix<cplx> > ta( Vector<iSUnMatrix<cplx> > ta(ncolour * ncolour - 1);
ncolour * ncolour - 1);
Vector<iSUnMatrix<cplx> > eij(Dimension); Vector<iSUnMatrix<cplx> > eij(Dimension);
iSUnMatrix<cplx> tmp; iSUnMatrix<cplx> tmp;
i2indTa = Zero(); i2indTa = Zero();

View File

@ -66,8 +66,6 @@ template<class vtype,int N> accelerator_inline iMatrix<vtype,N> Ta(const iMatrix
return ret; return ret;
} }
// for sp2n can't be as simple as Ta. We do a Gram-Schmidt
template<class vtype> accelerator_inline iScalar<vtype> SpTa(const iScalar<vtype>&r) template<class vtype> accelerator_inline iScalar<vtype> SpTa(const iScalar<vtype>&r)
{ {
iScalar<vtype> ret; iScalar<vtype> ret;
@ -82,7 +80,8 @@ template<class vtype,int N> accelerator_inline iVector<vtype,N> SpTa(const iVect
} }
return ret; return ret;
} }
template<class vtype,int N, typename std::enable_if< GridTypeMapper<vtype>::TensorLevel == 0 >::type * =nullptr> accelerator_inline iMatrix<vtype,N> SpTa(const iMatrix<vtype,N> &arg) template<class vtype,int N, typename std::enable_if< GridTypeMapper<vtype>::TensorLevel == 0 >::type * =nullptr>
accelerator_inline iMatrix<vtype,N> SpTa(const iMatrix<vtype,N> &arg)
{ {
// Generalises Ta to Sp2n // Generalises Ta to Sp2n
// Applies the following projections // Applies the following projections