mirror of
https://github.com/paboyle/Grid.git
synced 2025-04-09 21:50:45 +01:00
Inclusion of ExportPhysicalFermionSource that fixes a bug in the low mode w vectors
This commit is contained in:
parent
cecee1ef2c
commit
7dfd3cdae8
@ -183,7 +183,7 @@ class A2AModesSchurDiagTwo
|
|||||||
|
|
||||||
action.DminusDag(tmp_wout, wout_5d);
|
action.DminusDag(tmp_wout, wout_5d);
|
||||||
|
|
||||||
action.ExportPhysicalFermionSolution(wout_5d, wout_4d);
|
action.ExportPhysicalFermionSource(wout_5d, wout_4d);
|
||||||
}
|
}
|
||||||
|
|
||||||
void high_mode_v(Matrix &action, Solver &solver, const Field &source, Field &vout_5d, Field &vout_4d)
|
void high_mode_v(Matrix &action, Solver &solver, const Field &source, Field &vout_5d, Field &vout_4d)
|
||||||
|
@ -68,6 +68,18 @@ void CayleyFermion5D<Impl>::ExportPhysicalFermionSolution(const FermionField &so
|
|||||||
ExtractSlice(exported4d, tmp, 0, 0);
|
ExtractSlice(exported4d, tmp, 0, 0);
|
||||||
}
|
}
|
||||||
template<class Impl>
|
template<class Impl>
|
||||||
|
void CayleyFermion5D<Impl>::ExportPhysicalFermionSource(const FermionField &solution5d,FermionField &exported4d)
|
||||||
|
{
|
||||||
|
int Ls = this->Ls;
|
||||||
|
FermionField tmp(this->FermionGrid());
|
||||||
|
tmp = solution5d;
|
||||||
|
conformable(solution5d._grid,this->FermionGrid());
|
||||||
|
conformable(exported4d._grid,this->GaugeGrid());
|
||||||
|
axpby_ssp_pplus (tmp, 0., solution5d, 1., solution5d, 0, 0);
|
||||||
|
axpby_ssp_pminus(tmp, 1., tmp , 1., solution5d, 0, Ls-1);
|
||||||
|
ExtractSlice(exported4d, tmp, 0, 0);
|
||||||
|
}
|
||||||
|
template<class Impl>
|
||||||
void CayleyFermion5D<Impl>::ImportPhysicalFermionSource(const FermionField &input4d,FermionField &imported5d)
|
void CayleyFermion5D<Impl>::ImportPhysicalFermionSource(const FermionField &input4d,FermionField &imported5d)
|
||||||
{
|
{
|
||||||
int Ls = this->Ls;
|
int Ls = this->Ls;
|
||||||
|
@ -89,6 +89,7 @@ namespace Grid {
|
|||||||
virtual void Dminus(const FermionField &psi, FermionField &chi);
|
virtual void Dminus(const FermionField &psi, FermionField &chi);
|
||||||
virtual void DminusDag(const FermionField &psi, FermionField &chi);
|
virtual void DminusDag(const FermionField &psi, FermionField &chi);
|
||||||
virtual void ExportPhysicalFermionSolution(const FermionField &solution5d,FermionField &exported4d);
|
virtual void ExportPhysicalFermionSolution(const FermionField &solution5d,FermionField &exported4d);
|
||||||
|
virtual void ExportPhysicalFermionSource(const FermionField &solution5d, FermionField &exported4d);
|
||||||
virtual void ImportPhysicalFermionSource(const FermionField &input4d,FermionField &imported5d);
|
virtual void ImportPhysicalFermionSource(const FermionField &input4d,FermionField &imported5d);
|
||||||
|
|
||||||
/////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////
|
||||||
|
@ -166,6 +166,10 @@ namespace Grid {
|
|||||||
{
|
{
|
||||||
exported=solution;
|
exported=solution;
|
||||||
};
|
};
|
||||||
|
virtual void ExportPhysicalFermionSource(const FermionField &solution, FermionField &exported)
|
||||||
|
{
|
||||||
|
exported = solution;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user