Belos Package Browser (Single Doxygen Collection)
Development
|
Simple example of a user's defined Belos::Operator class. More...
#include <MyOperator.hpp>
Public Member Functions | |
MyOperator (const int NumRows) | |
MyOperator (const int NumRows, std::vector< ScalarType > ldu) | |
MyOperator (std::vector< ScalarType > diag) | |
~MyOperator () | |
Dtor. More... | |
void | Apply (const Belos::MultiVec< ScalarType > &X, Belos::MultiVec< ScalarType > &Y, Belos::ETrans trans=Belos::NOTRANS) const |
Applies the tridiagonal or diagonal matrix to a multivector. More... | |
Public Member Functions inherited from Belos::Operator< ScalarType > | |
Operator () | |
Default constructor (does nothing). More... | |
virtual | ~Operator () |
Virtual destructor, for memory safety of derived classes. More... | |
virtual bool | HasApplyTranspose () const |
Whether this operator implements applying the transpose. More... | |
Private Attributes | |
int | NumRows_ |
Number of rows and columns. More... | |
ScalarType | l_ |
Elements on subdiagonal, diagonal, and superdiagonal. More... | |
ScalarType | d_ |
ScalarType | u_ |
std::vector< ScalarType > | diag_ |
Elements on diagonal (for variable-diagonal case). More... | |
Simple example of a user's defined Belos::Operator class.
This is a simple, single processor example of user's defined Belos::Operator-derived class. The class is templated with ScalarType; possible choices are, for example, "float", "double", or "std::complex<double>".
This file can be easily extended to tackle more interesting cases.
Definition at line 65 of file MyOperator.hpp.
|
inline |
Definition at line 74 of file MyOperator.hpp.
|
inline |
Definition at line 83 of file MyOperator.hpp.
|
inline |
Definition at line 92 of file MyOperator.hpp.
|
inline |
Dtor.
Definition at line 101 of file MyOperator.hpp.
|
inlinevirtual |
Applies the tridiagonal or diagonal matrix to a multivector.
Implements Belos::Operator< ScalarType >.
Definition at line 105 of file MyOperator.hpp.
|
private |
Number of rows and columns.
Definition at line 157 of file MyOperator.hpp.
|
private |
Elements on subdiagonal, diagonal, and superdiagonal.
Definition at line 159 of file MyOperator.hpp.
|
private |
Definition at line 159 of file MyOperator.hpp.
|
private |
Definition at line 159 of file MyOperator.hpp.
|
private |
Elements on diagonal (for variable-diagonal case).
Definition at line 161 of file MyOperator.hpp.