Belos Version of the Day
Alternative run-time polymorphic interface for operators. More...
|Default constructor (does nothing). |
|Virtual destructor, for memory safety of derived classes. |
Operator application method
|virtual void||Apply (const MultiVec< ScalarType > &x, MultiVec< ScalarType > &y, ETrans trans=NOTRANS) const =0|
|Apply the operator to x, putting the result in y. |
Alternative run-time polymorphic interface for operators.
Belos' linear solvers are templated on the scalar (Scalar), multivector (MV), and operator (OP) types. The term "operator" includes the matrix A in the linear system , any left or right preconditioners, and any left or right scaling operators. If you have enabled the right packages, you can use Belos' solvers directly with OP = Epetra_Operator, Tpetra::Operator, or Thyra::LinearOpBase. Alternately, you may wish to use some other object as an operator. If so, you can make that object inherit from Belos::Operator<Scalar>, and make its corresponding multivector objects inherit from Belos::MultiVec<Scalar>. Belos' solvers may also be instantiated with MV = Belos::MultiVec<Scalar> and OP = Belos::Operator<Scalar>.
A concrete implementation of this class is necessary. Users may create their own implementation if the supplied implementations are not suitable for their needs.
|virtual void Belos::Operator< ScalarType >::Apply||(||const MultiVec< ScalarType > &||x,|
|MultiVec< ScalarType > &||y,|
Apply the operator to x, putting the result in y.
xwill be indicated by an std::exception being thrown.