1
0
mirror of https://github.com/paboyle/Grid.git synced 2024-11-10 15:55:37 +00:00

Namespace

This commit is contained in:
paboyle 2018-01-14 22:13:46 +00:00
parent 34a788331f
commit 81dcd0e6ea

View File

@ -1,13 +1,12 @@
/* /*
* Policy classes for the HMC * Policy classes for the HMC
* Authors: Guido Cossu, David Preti * Authors: Guido Cossu, David Preti
*/ */
#ifndef SUN2INDEX_H_H #ifndef SUN2INDEX_H_H
#define SUN2INDEX_H_H #define SUN2INDEX_H_H
namespace Grid { NAMESPACE_BEGIN(Grid);
namespace QCD {
/* /*
* This is an helper class for the HMC * This is an helper class for the HMC
@ -23,7 +22,7 @@ namespace QCD {
template <int ncolour, TwoIndexSymmetry S> template <int ncolour, TwoIndexSymmetry S>
class TwoIndexRep { class TwoIndexRep {
public: public:
// typdef to be used by the Representations class in HMC to get the // typdef to be used by the Representations class in HMC to get the
// types for the higher representation fields // types for the higher representation fields
typedef typename SU_TwoIndex<ncolour, S>::LatticeTwoIndexMatrix LatticeMatrix; typedef typename SU_TwoIndex<ncolour, S>::LatticeTwoIndexMatrix LatticeMatrix;
@ -79,21 +78,22 @@ class TwoIndexRep {
return out; return out;
} }
private: private:
void projectOnAlgebra(typename SU<ncolour>::LatticeAlgebraVector &h_out, void projectOnAlgebra(typename SU<ncolour>::LatticeAlgebraVector &h_out,
const LatticeMatrix &in, Real scale = 1.0) const { const LatticeMatrix &in, Real scale = 1.0) const {
SU_TwoIndex<ncolour, S>::projectOnAlgebra(h_out, in, scale); SU_TwoIndex<ncolour, S>::projectOnAlgebra(h_out, in, scale);
} }
void FundamentalLieAlgebraMatrix( void FundamentalLieAlgebraMatrix(
typename SU<ncolour>::LatticeAlgebraVector &h, typename SU<ncolour>::LatticeAlgebraVector &h,
typename SU<ncolour>::LatticeMatrix &out, Real scale = 1.0) const { typename SU<ncolour>::LatticeMatrix &out, Real scale = 1.0) const {
SU<ncolour>::FundamentalLieAlgebraMatrix(h, out, scale); SU<ncolour>::FundamentalLieAlgebraMatrix(h, out, scale);
} }
}; };
typedef TwoIndexRep<Nc, Symmetric> TwoIndexSymmetricRepresentation; typedef TwoIndexRep<Nc, Symmetric> TwoIndexSymmetricRepresentation;
typedef TwoIndexRep<Nc, AntiSymmetric> TwoIndexAntiSymmetricRepresentation; typedef TwoIndexRep<Nc, AntiSymmetric> TwoIndexAntiSymmetricRepresentation;
}
} NAMESPACE_END(Grid);
#endif #endif