mirror of
https://github.com/paboyle/Grid.git
synced 2025-04-09 21:50:45 +01:00
Namespace
This commit is contained in:
parent
291407dc7f
commit
e598e65f69
@ -1,4 +1,4 @@
|
|||||||
/*************************************************************************************
|
/*************************************************************************************
|
||||||
|
|
||||||
Grid physics library, www.github.com/paboyle/Grid
|
Grid physics library, www.github.com/paboyle/Grid
|
||||||
|
|
||||||
@ -24,56 +24,53 @@ Author: Peter Boyle <paboyle@ph.ed.ac.uk>
|
|||||||
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
|
||||||
See the full license in the file "LICENSE" in the top level distribution directory
|
See the full license in the file "LICENSE" in the top level distribution directory
|
||||||
*************************************************************************************/
|
*************************************************************************************/
|
||||||
/* END LEGAL */
|
/* END LEGAL */
|
||||||
#ifndef GRID_QCD_ZMOBIUS_FERMION_H
|
#ifndef GRID_QCD_ZMOBIUS_FERMION_H
|
||||||
#define GRID_QCD_ZMOBIUS_FERMION_H
|
#define GRID_QCD_ZMOBIUS_FERMION_H
|
||||||
|
|
||||||
#include <Grid/qcd/action/fermion/FermionCore.h>
|
#include <Grid/qcd/action/fermion/FermionCore.h>
|
||||||
|
|
||||||
namespace Grid {
|
NAMESPACE_BEGIN(Grid);
|
||||||
|
|
||||||
namespace QCD {
|
template<class Impl>
|
||||||
|
class ZMobiusFermion : public CayleyFermion5D<Impl>
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
INHERIT_IMPL_TYPES(Impl);
|
||||||
|
public:
|
||||||
|
|
||||||
template<class Impl>
|
virtual void Instantiatable(void) {};
|
||||||
class ZMobiusFermion : public CayleyFermion5D<Impl>
|
// Constructors
|
||||||
{
|
ZMobiusFermion(GaugeField &_Umu,
|
||||||
public:
|
GridCartesian &FiveDimGrid,
|
||||||
INHERIT_IMPL_TYPES(Impl);
|
GridRedBlackCartesian &FiveDimRedBlackGrid,
|
||||||
public:
|
GridCartesian &FourDimGrid,
|
||||||
|
GridRedBlackCartesian &FourDimRedBlackGrid,
|
||||||
virtual void Instantiatable(void) {};
|
RealD _mass,RealD _M5,
|
||||||
// Constructors
|
std::vector<ComplexD> &gamma, RealD b,RealD c,const ImplParams &p= ImplParams()) :
|
||||||
ZMobiusFermion(GaugeField &_Umu,
|
|
||||||
GridCartesian &FiveDimGrid,
|
|
||||||
GridRedBlackCartesian &FiveDimRedBlackGrid,
|
|
||||||
GridCartesian &FourDimGrid,
|
|
||||||
GridRedBlackCartesian &FourDimRedBlackGrid,
|
|
||||||
RealD _mass,RealD _M5,
|
|
||||||
std::vector<ComplexD> &gamma, RealD b,RealD c,const ImplParams &p= ImplParams()) :
|
|
||||||
|
|
||||||
CayleyFermion5D<Impl>(_Umu,
|
CayleyFermion5D<Impl>(_Umu,
|
||||||
FiveDimGrid,
|
FiveDimGrid,
|
||||||
FiveDimRedBlackGrid,
|
FiveDimRedBlackGrid,
|
||||||
FourDimGrid,
|
FourDimGrid,
|
||||||
FourDimRedBlackGrid,_mass,_M5,p)
|
FourDimRedBlackGrid,_mass,_M5,p)
|
||||||
|
|
||||||
{
|
{
|
||||||
RealD eps = 1.0;
|
RealD eps = 1.0;
|
||||||
|
|
||||||
std::cout<<GridLogMessage << "ZMobiusFermion (b="<<b<<",c="<<c<<") with Ls= "<<this->Ls<<" gamma passed in"<<std::endl;
|
std::cout<<GridLogMessage << "ZMobiusFermion (b="<<b<<",c="<<c<<") with Ls= "<<this->Ls<<" gamma passed in"<<std::endl;
|
||||||
std::vector<Coeff_t> zgamma(this->Ls);
|
std::vector<Coeff_t> zgamma(this->Ls);
|
||||||
for(int s=0;s<this->Ls;s++){
|
for(int s=0;s<this->Ls;s++){
|
||||||
zgamma[s] = gamma[s];
|
zgamma[s] = gamma[s];
|
||||||
}
|
}
|
||||||
|
|
||||||
// Call base setter
|
|
||||||
this->SetCoefficientsInternal(1.0,zgamma,b,c);
|
|
||||||
}
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
|
// Call base setter
|
||||||
|
this->SetCoefficientsInternal(1.0,zgamma,b,c);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
};
|
||||||
|
|
||||||
|
NAMESPACE_END(Grid);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/*************************************************************************************
|
/*************************************************************************************
|
||||||
|
|
||||||
Grid physics library, www.github.com/paboyle/Grid
|
Grid physics library, www.github.com/paboyle/Grid
|
||||||
|
|
||||||
@ -23,13 +23,12 @@ Author: Peter Boyle <paboyle@ph.ed.ac.uk>
|
|||||||
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
|
||||||
See the full license in the file "LICENSE" in the top level distribution directory
|
See the full license in the file "LICENSE" in the top level distribution directory
|
||||||
*************************************************************************************/
|
*************************************************************************************/
|
||||||
/* END LEGAL */
|
/* END LEGAL */
|
||||||
#ifndef G5_HERMITIAN_LINOP
|
#ifndef G5_HERMITIAN_LINOP
|
||||||
#define G5_HERMITIAN_LINOP
|
#define G5_HERMITIAN_LINOP
|
||||||
|
|
||||||
namespace Grid {
|
NAMESPACE_BEGIN(Grid);
|
||||||
namespace QCD {
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////
|
||||||
// Wrap an already herm matrix
|
// Wrap an already herm matrix
|
||||||
@ -80,7 +79,7 @@ class Gamma5HermitianLinearOperator : public LinearOperatorBase<Field> {
|
|||||||
Matrix &_Mat;
|
Matrix &_Mat;
|
||||||
Gamma g5;
|
Gamma g5;
|
||||||
public:
|
public:
|
||||||
Gamma5HermitianLinearOperator(Matrix &Mat): _Mat(Mat), g5(Gamma::Algebra::Gamma5) {};
|
Gamma5HermitianLinearOperator(Matrix &Mat): _Mat(Mat), g5(Gamma::Algebra::Gamma5) {};
|
||||||
void Op (const Field &in, Field &out){
|
void Op (const Field &in, Field &out){
|
||||||
HermOp(in,out);
|
HermOp(in,out);
|
||||||
}
|
}
|
||||||
@ -116,6 +115,5 @@ public:
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
NAMESPACE_END(Grid);
|
||||||
}}
|
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user