GEOS
|
Abstract base class for linear operators. More...
#include <LinearOperator.hpp>
Public Types | |
using | Vector = VECTOR |
Alias for template parameter. | |
Public Member Functions | |
LinearOperator ()=default | |
Constructor. | |
virtual | ~LinearOperator ()=default |
Destructor. | |
virtual void | apply (Vector const &src, Vector &dst) const =0 |
Apply operator to a vector, dst = this(src) . More... | |
virtual void | residual (Vector const &x, Vector const &b, Vector &r) const |
Compute residual r = b - this(x) . More... | |
virtual globalIndex | numGlobalRows () const =0 |
Get the number of global rows. More... | |
virtual globalIndex | numGlobalCols () const =0 |
Get the number of global columns. More... | |
virtual localIndex | numLocalRows () const =0 |
Get the number of local rows. More... | |
virtual localIndex | numLocalCols () const =0 |
Get the number of local columns. More... | |
virtual MPI_Comm | comm () const =0 |
Get the MPI communicator the matrix was created with. More... | |
Abstract base class for linear operators.
VECTOR | Type of vector this operator can be applied to |
Definition at line 34 of file LinearOperator.hpp.
|
pure virtual |
Apply operator to a vector, dst = this(src)
.
src | input vector |
dst | output vector |
src
and dst
cannot alias the same vector (some implementations may allow this). Implemented in geos::MatrixBase< MATRIX, VECTOR >, geos::MatrixBase< HypreMatrix, HypreVector >, geos::MatrixBase< PetscMatrix, PetscVector >, geos::MatrixBase< EpetraMatrix, EpetraVector >, geos::KrylovSolver< VECTOR >, geos::BlockOperatorView< VECTOR, OPERATOR >, geos::BlockOperatorView< VECTOR, LinearOperator< VECTOR > >, geos::BlockOperatorView< VECTOR, OPERATOR >, geos::HyprePreconditioner, geos::PetscMatrix, geos::HypreMatrix, and geos::EpetraMatrix.
|
pure virtual |
Get the MPI communicator the matrix was created with.
create
...()Implemented in geos::KrylovSolver< VECTOR >, geos::TransposeOperator< LAI >, geos::NormalOperator< LAI >, geos::InverseNormalOperator< LAI, SOLVER >, geos::BlockOperatorView< VECTOR, OPERATOR >, geos::BlockOperatorView< VECTOR, LinearOperator< VECTOR > >, geos::BlockOperatorView< VECTOR, OPERATOR >, geos::EpetraMatrix, geos::PetscMatrix, geos::HypreMatrix, geos::PreconditionerBase< LAI >, geos::PreconditionerBase< PetscInterface >, geos::PreconditionerBase< HypreInterface >, and geos::PreconditionerBase< TrilinosInterface >.
|
pure virtual |
Get the number of global columns.
Implemented in geos::PreconditionerJacobi< LAI >, geos::KrylovSolver< VECTOR >, geos::TransposeOperator< LAI >, geos::NormalOperator< LAI >, geos::InverseNormalOperator< LAI, SOLVER >, geos::BlockOperatorView< VECTOR, OPERATOR >, geos::BlockOperatorView< VECTOR, LinearOperator< VECTOR > >, geos::BlockOperatorView< VECTOR, OPERATOR >, geos::EpetraMatrix, geos::PetscMatrix, geos::HypreMatrix, geos::PreconditionerBase< LAI >, geos::PreconditionerBase< PetscInterface >, geos::PreconditionerBase< HypreInterface >, and geos::PreconditionerBase< TrilinosInterface >.
|
pure virtual |
Get the number of global rows.
Implemented in geos::PreconditionerJacobi< LAI >, geos::KrylovSolver< VECTOR >, geos::TransposeOperator< LAI >, geos::NormalOperator< LAI >, geos::InverseNormalOperator< LAI, SOLVER >, geos::BlockOperatorView< VECTOR, OPERATOR >, geos::BlockOperatorView< VECTOR, LinearOperator< VECTOR > >, geos::BlockOperatorView< VECTOR, OPERATOR >, geos::EpetraMatrix, geos::PetscMatrix, geos::HypreMatrix, geos::PreconditionerBase< LAI >, geos::PreconditionerBase< PetscInterface >, geos::PreconditionerBase< HypreInterface >, and geos::PreconditionerBase< TrilinosInterface >.
|
pure virtual |
Get the number of local columns.
Implemented in geos::KrylovSolver< VECTOR >, geos::TransposeOperator< LAI >, geos::NormalOperator< LAI >, geos::InverseNormalOperator< LAI, SOLVER >, geos::BlockOperatorView< VECTOR, OPERATOR >, geos::BlockOperatorView< VECTOR, LinearOperator< VECTOR > >, geos::BlockOperatorView< VECTOR, OPERATOR >, geos::EpetraMatrix, geos::PetscMatrix, geos::HypreMatrix, geos::PreconditionerBase< LAI >, geos::PreconditionerBase< PetscInterface >, geos::PreconditionerBase< HypreInterface >, and geos::PreconditionerBase< TrilinosInterface >.
|
pure virtual |
Get the number of local rows.
Implemented in geos::KrylovSolver< VECTOR >, geos::TransposeOperator< LAI >, geos::NormalOperator< LAI >, geos::InverseNormalOperator< LAI, SOLVER >, geos::BlockOperatorView< VECTOR, OPERATOR >, geos::BlockOperatorView< VECTOR, LinearOperator< VECTOR > >, geos::BlockOperatorView< VECTOR, OPERATOR >, geos::EpetraMatrix, geos::PetscMatrix, geos::HypreMatrix, geos::PreconditionerBase< LAI >, geos::PreconditionerBase< PetscInterface >, geos::PreconditionerBase< HypreInterface >, and geos::PreconditionerBase< TrilinosInterface >.
|
inlinevirtual |
Compute residual r = b - this(x)
.
x | Input solution. |
b | Input right hand side. |
r | Output residual. |
b
and x
may alias the same vector. r
cannot alias any of the other two vectors (some implementations may allow this). Reimplemented in geos::MatrixBase< MATRIX, VECTOR >, geos::MatrixBase< HypreMatrix, HypreVector >, geos::MatrixBase< PetscMatrix, PetscVector >, and geos::MatrixBase< EpetraMatrix, EpetraVector >.
Definition at line 70 of file LinearOperator.hpp.