CHROMA
|
Even-odd preconditioned linear operator. More...
#include <seoprec_linop.h>
Public Member Functions | |
virtual | ~SymEvenOddPrecLinearOperator () |
Virtual destructor to help with cleanup;. More... | |
const Subset & | subset () const |
Only defined on the odd lattice. More... | |
virtual const FermBC< T, P, Q > & | getFermBC () const =0 |
Return the fermion BC object for this linear operator. More... | |
virtual void | unprecEvenEvenLinOp (T &chi, const T &psi, enum PlusMinus isign) const =0 |
Apply the even-even block onto a source std::vector. More... | |
virtual void | unprecEvenEvenInvLinOp (T &chi, const T &psi, enum PlusMinus isign) const =0 |
Apply the inverse of the even-even block onto a source std::vector. More... | |
virtual void | unprecOddOddLinOp (T &chi, const T &psi, enum PlusMinus isign) const =0 |
Apply the the odd-odd block onto a source std::vector. More... | |
virtual void | unprecOddOddInvLinOp (T &chi, const T &psi, enum PlusMinus isign) const =0 |
Apply the inverse of the odd-odd block onto a source std::vector. More... | |
virtual void | unprecEvenOddLinOp (T &chi, const T &psi, enum PlusMinus isign) const =0 |
Apply the the even-odd block onto a source std::vector. More... | |
virtual void | unprecOddEvenLinOp (T &chi, const T &psi, enum PlusMinus isign) const =0 |
Apply the the odd-even block onto a source std::vector. More... | |
virtual void | evenOddLinOp (T &chi, const T &psi, enum PlusMinus isign) const |
Apply the EvenOdd Linop for which we have a category default) More... | |
virtual void | oddEvenLinOp (T &chi, const T &psi, enum PlusMinus isign) const |
virtual void | operator() (T &chi, const T &psi, enum PlusMinus isign) const |
Apply the operator onto a source std::vector. More... | |
virtual void | jacobiOp (T &chi, const T &psi, enum PlusMinus isign) const |
Apply the Jacobi Operator. More... | |
virtual void | unprecLinOp (T &chi, const T &psi, enum PlusMinus isign) const |
Apply the UNPRECONDITIONED operator onto a source std::vector. More... | |
virtual void | derivEvenOddLinOp (P &ds_u, const T &chi, const T &psi, enum PlusMinus isign) const =0 |
Compute force coming from EvenOdd (A^{-1}_ee D_eo) term. More... | |
virtual void | derivOddEvenLinOp (P &ds_u, const T &chi, const T &psi, enum PlusMinus isign) const =0 |
Compute force coming from OddEven (A^{-1}_oo D_oe ) term. More... | |
virtual void | deriv (P &ds_u, const T &chi, const T &psi, enum PlusMinus isign) const |
Deriv. More... | |
virtual void | derivMultipole (P &ds_u, const multi1d< T > &chi, const multi1d< T > &psi, enum PlusMinus isign) const |
Apply the derivative of the operator onto a source std::vector. More... | |
Public Member Functions inherited from Chroma::DiffLinearOperator< T, P, Q > | |
virtual | ~DiffLinearOperator () |
Virtual destructor to help with cleanup;. More... | |
virtual void | deriv (P &ds_u, const T &chi, const T &psi, enum PlusMinus isign, const Real &epsilon) const |
Apply the derivative of the operator onto a source std::vector to some precision. More... | |
Public Member Functions inherited from Chroma::LinearOperator< T > | |
virtual | ~LinearOperator () |
Virtual destructor to help with cleanup;. More... | |
virtual void | operator() (T &chi, const T &psi, enum PlusMinus isign, Real epsilon) const |
Apply the operator onto a source std::vector to some precision. More... | |
virtual unsigned long | nFlops () const |
Even-odd preconditioned linear operator.
Support for even-odd preconditioned linear operators Given a matrix M written in block form:
[ A D ] [ E,E E,O ] [ ] [ D A ] [ O,E O,O ]
The preconditioning consists of factorizing as
M_unprec = M_diag x M' M_diag = [ A_E,E 0 ] [ 0 A_O,O ] [ 1 M_E,O ] M' = [ ] [ M_O,E 1 ] M_E,O = A^{-1}_E,E D_E,O M_O,E = A^{-1}_O,O D_E,O
We then do a schur precondition of M'
as M' = L M R
L = [ 1 0 ] [ ] [ M_O,E 1 ] R = [ 1 M_E,O ] [ ] [ 0 1 ] M = [ 1 0 ] [ ] [ 0 S ]
where S = 1 - ( M_O,E )( M_E,O )
L^{-1} = [ 1 0 ] [ ] [- M_O,E 1 ]
R^{-1} = [ 1 - M_E,O ] [ ] [ 0 1 ]
For props we need to solve:
M x' = L^{-1} (M_diag)^{-1} b
and then x = R^{-1} x' (backsubstitution)
for HMC we have det(L)=1 det(R)=1 det(M_diag) is handled by TraceLog/LogDet calls to clover and we pseudofermionize only the 'S' operators
Structure: capture D_oe, D_eo, A_ee, A_oo, A^{-1}_oo and A^{-1}_ee as unprecEvenOddLinOp unprecOddEvenLinOp unprecEvenEvenLinOp unprecOddOddLinOp unprecOddOddInvLinOp unprecEvenEvenInvLinOp
then we can write category defaults for:
then evenOddLinOp is M_eo = A^{-1}_ee D_eo or h.c. oddEvenLinOp is M_oe = A^{-1}_oo D_oe or h.c.
the so called Jacobi Operator: [ 1 M_eo ] [ M_oe 1 ]
the Schur Operator: S = 1 - M_oe M_eo
the Unprec Operator: diag( A_ee A_oo ) M_jacobi
We can also write category default for the forces in terms of derivEvenOddLinOp and derivOddEvenLinOp
Const-detness or log-det ness will depend on how the derivEvenOdd and derivOddEven operators are coded
ConstDet will treat A as a constant (muliplicative factor) LogDet will evaluate chain rule in derivEvenOddLinOp and also provide lodDet terms and TraceLog forces
Definition at line 131 of file seoprec_linop.h.
|
inlinevirtual |
Virtual destructor to help with cleanup;.
Definition at line 135 of file seoprec_linop.h.
|
inlinevirtual |
Deriv.
Reimplemented from Chroma::DiffLinearOperator< T, P, Q >.
Reimplemented in Chroma::SymEvenOddPrecCloverLinOp.
Definition at line 292 of file seoprec_linop.h.
References chi, Chroma::isign, Chroma::MINUS, Nd, Chroma::PLUS, psi, and Chroma::zero.
|
pure virtual |
Compute force coming from EvenOdd (A^{-1}_ee D_eo) term.
Implemented in Chroma::SymEvenOddPrecLogDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecConstDetLinearOperator< T, P, Q >, and Chroma::SymEvenOddPrecLogDetLinearOperator< LatticeFermion, multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > >.
|
inlinevirtual |
Apply the derivative of the operator onto a source std::vector.
User should make sure deriv routines do a resize
Reimplemented from Chroma::DiffLinearOperator< T, P, Q >.
Reimplemented in Chroma::SymEvenOddPrecCloverLinOp.
Definition at line 317 of file seoprec_linop.h.
References chi, i, Chroma::isign, Chroma::MINUS, Nd, Chroma::PLUS, psi, and Chroma::zero.
|
pure virtual |
Compute force coming from OddEven (A^{-1}_oo D_oe ) term.
Implemented in Chroma::SymEvenOddPrecLogDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecConstDetLinearOperator< T, P, Q >, and Chroma::SymEvenOddPrecLogDetLinearOperator< LatticeFermion, multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > >.
|
inlinevirtual |
Apply the EvenOdd Linop for which we have a category default)
Definition at line 170 of file seoprec_linop.h.
References chi, Chroma::isign, Chroma::MINUS, Chroma::PLUS, psi, and tmp.
|
pure virtual |
Return the fermion BC object for this linear operator.
Implements Chroma::DiffLinearOperator< T, P, Q >.
Implemented in Chroma::SymEvenOddPrecLogDetLinearOperator< LatticeFermion, multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > >, Chroma::SymEvenOddPrecLogDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecConstDetLinearOperator< T, P, Q >, and Chroma::SymEvenOddPrecCloverLinOp.
|
inlinevirtual |
Apply the Jacobi Operator.
Definition at line 228 of file seoprec_linop.h.
References chi, Chroma::isign, psi, and tmp.
|
inlinevirtual |
Definition at line 188 of file seoprec_linop.h.
References chi, Chroma::isign, Chroma::MINUS, Chroma::PLUS, psi, and tmp.
|
inlinevirtual |
Apply the operator onto a source std::vector.
Implements Chroma::LinearOperator< T >.
Reimplemented in Chroma::SymEvenOddPrecCloverLinOp.
Definition at line 208 of file seoprec_linop.h.
References chi, Chroma::isign, psi, and tmp2.
|
inlinevirtual |
Only defined on the odd lattice.
Implements Chroma::LinearOperator< T >.
Reimplemented in Chroma::SymEvenOddPrecLogDetLinearOperator< T, P, Q >, and Chroma::SymEvenOddPrecLogDetLinearOperator< LatticeFermion, multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > >.
Definition at line 138 of file seoprec_linop.h.
|
pure virtual |
Apply the inverse of the even-even block onto a source std::vector.
Implemented in Chroma::SymEvenOddPrecLogDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecConstDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecCloverLinOp, and Chroma::SymEvenOddPrecLogDetLinearOperator< LatticeFermion, multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > >.
|
pure virtual |
Apply the even-even block onto a source std::vector.
This does not need to be optimized
Implemented in Chroma::SymEvenOddPrecLogDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecConstDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecCloverLinOp, and Chroma::SymEvenOddPrecLogDetLinearOperator< LatticeFermion, multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > >.
|
pure virtual |
Apply the the even-odd block onto a source std::vector.
Implemented in Chroma::SymEvenOddPrecLogDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecConstDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecCloverLinOp, and Chroma::SymEvenOddPrecLogDetLinearOperator< LatticeFermion, multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > >.
|
inlinevirtual |
Apply the UNPRECONDITIONED operator onto a source std::vector.
Mainly intended for debugging
Definition at line 249 of file seoprec_linop.h.
References chi, Chroma::isign, Chroma::PLUS, and psi.
|
pure virtual |
Apply the the odd-even block onto a source std::vector.
Implemented in Chroma::SymEvenOddPrecLogDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecConstDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecCloverLinOp, and Chroma::SymEvenOddPrecLogDetLinearOperator< LatticeFermion, multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > >.
|
pure virtual |
Apply the inverse of the odd-odd block onto a source std::vector.
Implemented in Chroma::SymEvenOddPrecLogDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecConstDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecCloverLinOp, and Chroma::SymEvenOddPrecLogDetLinearOperator< LatticeFermion, multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > >.
|
pure virtual |
Apply the the odd-odd block onto a source std::vector.
Implemented in Chroma::SymEvenOddPrecLogDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecConstDetLinearOperator< T, P, Q >, Chroma::SymEvenOddPrecCloverLinOp, and Chroma::SymEvenOddPrecLogDetLinearOperator< LatticeFermion, multi1d< LatticeColorMatrix >, multi1d< LatticeColorMatrix > >.