From 73d467699766e82b0efaff5dab392941108846cf Mon Sep 17 00:00:00 2001 From: Peter Boyle Date: Tue, 23 Apr 2019 21:53:44 +0100 Subject: [PATCH] Action and Deriv solvers allowed to differ --- .../pseudofermion/ExactOneFlavourRatio.h | 21 ++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/Grid/qcd/action/pseudofermion/ExactOneFlavourRatio.h b/Grid/qcd/action/pseudofermion/ExactOneFlavourRatio.h index 54a2c594..feba94c8 100644 --- a/Grid/qcd/action/pseudofermion/ExactOneFlavourRatio.h +++ b/Grid/qcd/action/pseudofermion/ExactOneFlavourRatio.h @@ -59,12 +59,23 @@ namespace QCD{ AbstractEOFAFermion& Lop; // the basic LH operator AbstractEOFAFermion& Rop; // the basic RH operator SchurRedBlackDiagMooeeSolve Solver; + SchurRedBlackDiagMooeeSolve DerivativeSolver; FermionField Phi; // the pseudofermion field for this trajectory public: - ExactOneFlavourRatioPseudoFermionAction(AbstractEOFAFermion& _Lop, AbstractEOFAFermion& _Rop, - OperatorFunction& S, Params& p, bool use_fc=false) : Lop(_Lop), Rop(_Rop), - Solver(S, false, true), Phi(_Lop.FermionGrid()), param(p), use_heatbath_forecasting(use_fc) + ExactOneFlavourRatioPseudoFermionAction(AbstractEOFAFermion& _Lop, + AbstractEOFAFermion& _Rop, + OperatorFunction& ActionCG, + OperatorFunction& DerivCG, + Params& p, + bool use_fc=false) : + Lop(_Lop), + Rop(_Rop), + Solver(ActionCG, false, true), + DerivativeSolver(DerivCG, false, true), + Phi(_Lop.FermionGrid()), + param(p), + use_heatbath_forecasting(use_fc) { AlgRemez remez(param.lo, param.hi, param.precision); @@ -245,7 +256,7 @@ namespace QCD{ Lop.Omega(spProj_Phi, Omega_spProj_Phi, -1, 0); G5R5(CG_src, Omega_spProj_Phi); spProj_Phi = zero; - Solver(Lop, CG_src, spProj_Phi); + DerivativeSolver(Lop, CG_src, spProj_Phi); Lop.Dtilde(spProj_Phi, Chi); G5R5(g5_R5_Chi, Chi); Lop.MDeriv(force, g5_R5_Chi, Chi, DaggerNo); @@ -257,7 +268,7 @@ namespace QCD{ Rop.Omega(spProj_Phi, Omega_spProj_Phi, 1, 0); G5R5(CG_src, Omega_spProj_Phi); spProj_Phi = zero; - Solver(Rop, CG_src, spProj_Phi); + DerivativeSolver(Rop, CG_src, spProj_Phi); Rop.Dtilde(spProj_Phi, Chi); G5R5(g5_R5_Chi, Chi); Lop.MDeriv(force, g5_R5_Chi, Chi, DaggerNo);