7 #ifndef __two_flavor_monomial5d_w_h__
8 #define __two_flavor_monomial5d_w_h__
31 template<
typename P,
typename Q,
typename Phi>
49 push(xml_out,
"TwoFlavorExactWilsonTypeFermMonomial5D");
79 multi1d<Phi> X(FA.
size());
95 multi1d<Phi> Y(FA.
size());
103 M->deriv(F_tmp, Y, X,
PLUS);
106 for(
int mu=0;
mu <
F.size(); ++
mu) {
135 multi1d<Phi>
eta(
N5);
139 for(
int s=0;
s <
N5; ++
s)
146 for(
int s=0;
s <
N5; ++
s)
147 eta[
s][M->subset()] *= sqrt(0.5);
153 QDPIO::cout <<
"TwoFlavWilson5DMonomial: resetting Predictor at end of field refresh" << std::endl;
171 for(
int i=0 ;
i < fm.
getPhi().size();
i++) {
175 catch(std::bad_cast) {
176 QDPIO::cerr <<
"Failed to cast input Monomial to TwoFlavorExactWilsonTypeFermMonomial5D" << std::endl;
192 virtual const multi1d<Phi>&
getPhi()
const = 0;
217 template<
typename P,
typename Q,
typename Phi>
231 push(xml_out,
"TwoFlavorExactUnprecWilsonTypeFermMonomial5D");
240 multi1d<Phi> X(FA.
size());
246 QDPIO::cout <<
"TwoFlavWilson5DMonomial: energy calc solve" << std::endl;
255 for(
int s=0;
s < FA.
size(); ++
s)
256 action += innerProductReal(
getPhi()[
s], X[
s]);
259 write(xml_out,
"S", action);
270 virtual const multi1d<Phi>&
getPhi()
const = 0;
293 template<
typename P,
typename Q,
typename Phi>
309 push(xml_out,
"S_odd_odd");
322 multi1d<Phi> X(FA.
size());
328 QDPIO::cout <<
"TwoFlavWilson5DMonomial: energy calc solve" << std::endl;
336 Double action = innerProductReal(
getPhi(), X, M->subset());
339 write(xml_out,
"S_oo", action);
353 push(xml_out,
"TwoFlavorExactEvenOddPrecWilsonTypeFermMonomial5D");
357 write(xml_out,
"S", action);
376 virtual const multi1d<Phi>&
getPhi()
const = 0;
389 template<
typename P,
typename Q,
typename Phi>
Monomials - gauge action or fermion binlinear contributions for HMC.
Chronological predictor for HMC.
Abstract interface for a Chronological Solution predictor in 5D.
virtual const Q & getQ(void) const =0
virtual DiffLinearOperatorArray< T, P, Q > * linOp(Handle< FermState< T, P, Q > > state) const =0
Produce a linear operator for this action.
Even-odd preconditioned Wilson-like fermion actions including derivatives.
Even-odd preconditioned Wilson-like fermion actions including derivatives.
virtual EvenOddPrecLinearOperatorArray< T, P, Q > * linOp(Handle< FermState< T, P, Q > > state) const =0
Override to produce an even-odd prec. linear operator for this action.
Fermionic monomials (binlinears in fermion fields)
virtual int size() const =0
Expected length of array index.
virtual const FermBC< T, P, Q > & getFermBC() const
Return the fermion BC object for this action.
virtual FermState< T, P, Q > * createState(const Q &q) const
Given links (coordinates Q) create the state needed for the linear operators.
Class for counted reference semantics.
An abstract monomial class, for inexact algorithms.
Exact 2 degen flavor even-odd preconditioned fermact monomial living in extra dimensions.
~TwoFlavorExactEvenOddPrecConstDetWilsonTypeFermMonomial5D()
virtual destructor:
virtual const EvenOddPrecConstDetWilsonTypeFermAct5D< Phi, P, Q > & getFermAct() const =0
Get at fermion action.
virtual Double S_even_even(const AbsFieldState< P, Q > &s)
Even even contribution (eg ln det Clover)
Exact 2 degen flavor even-odd preconditioned fermact monomial living in extra dimensions.
~TwoFlavorExactEvenOddPrecWilsonTypeFermMonomial5D()
virtual destructor:
virtual Double S_even_even(const AbsFieldState< P, Q > &s)=0
Even even contribution (eg ln det Clover)
virtual Double S_odd_odd(const AbsFieldState< P, Q > &s)
Compute the odd odd contribution (eg.
virtual multi1d< Phi > & getPhi()=0
mutator for pseudofermion with Pf index i
virtual const EvenOddPrecWilsonTypeFermAct5D< Phi, P, Q > & getFermAct() const =0
Get at fermion action.
virtual AbsChronologicalPredictor5D< Phi > & getMDSolutionPredictor()=0
Get the initial guess predictor.
virtual const GroupXML_t & getInvParams() const =0
Get inverter params.
Double S(const AbsFieldState< P, Q > &s)
Compute the total action.
virtual const multi1d< Phi > & getPhi() const =0
Accessor for pseudofermion with Pf index i (read only)
Exact 2 degen flavor unpreconditioned fermact monomial living in extra dimensions.
virtual Double S(const AbsFieldState< P, Q > &s)
Compute the total action.
virtual AbsChronologicalPredictor5D< Phi > & getMDSolutionPredictor()=0
Get the initial guess predictor.
virtual const UnprecWilsonTypeFermAct5D< Phi, P, Q > & getFermAct() const =0
Get at fermion action.
~TwoFlavorExactUnprecWilsonTypeFermMonomial5D()
virtual destructor:
virtual const GroupXML_t & getInvParams() const =0
Get inverter params.
virtual multi1d< Phi > & getPhi()=0
mutator for pseudofermion with Pf index i
virtual const multi1d< Phi > & getPhi() const =0
Accessor for pseudofermion with Pf index i (read only)
Exact 2 degen flavor fermact monomial in extra dimensions.
virtual void setInternalFields(const Monomial< P, Q > &m)
Copy pseudofermions if any.
virtual void refreshInternalFields(const AbsFieldState< P, Q > &field_state)
Refresh pseudofermions.
virtual const WilsonTypeFermAct5D< Phi, P, Q > & getFermAct() const =0
Get at fermion action.
virtual const GroupXML_t & getInvParams() const =0
Get inverter params.
virtual void dsdq(P &F, const AbsFieldState< P, Q > &s)
Compute dsdq for the system...
virtual multi1d< Phi > & getPhi()=0
mutator for pseudofermion with Pf index i
~TwoFlavorExactWilsonTypeFermMonomial5D()
virtual destructor:
virtual AbsChronologicalPredictor5D< Phi > & getMDSolutionPredictor()=0
Get the initial guess predictor.
virtual void resetPredictors()
Reset predictors.
virtual Double S(const AbsFieldState< P, Q > &s)=0
Compute the total action.
virtual const multi1d< Phi > & getPhi() const =0
Accessor for pseudofermion with Pf index i (read only)
Unpreconditioned Wilson-like fermion actions in extra dims with derivatives.
Wilson-like fermion actions.
virtual MdagMSystemSolverArray< T > * invMdagM(Handle< FermState< T, P, Q > > state, const GroupXML_t &invParam) const
Return a linear operator solver for this action to solve MdagM*psi=chi.
virtual DiffLinearOperatorArray< T, P, Q > * lMdagM(Handle< FermState< T, P, Q > > state) const
Produce a linear operator M^dag.M for this action.
Even-odd const determinant Wilson-like fermact.
Helper function for calculating forces.
void write(XMLWriter &xml, const std::string &path, const AsqtadFermActParams ¶m)
Writer parameters.
void monitorForces(XMLWriter &xml_out, const std::string &path, const multi1d< LatticeColorMatrix > &F)
Calculate and write out forces.
Asqtad Staggered-Dirac operator.
push(xml_out,"Condensates")
const WilsonTypeFermAct< multi1d< LatticeFermion > > Handle< const ConnectState > state
multi1d< LatticeFermion > s(Ncb)
FloatingPoint< double > Double
Hold group xml and type id.
Holds return info from SystemSolver call.
Handle< LinearOperator< T > > MdagM
multi1d< LatticeColorMatrix > P
Wilson-like fermion actions.
static INTERNAL_PRECISION F