Xpetra-specific matrix class. More...
#include <Xpetra_Matrix_fwd.hpp>
Public Types | |
typedef Scalar | scalar_type |
typedef LocalOrdinal | local_ordinal_type |
typedef GlobalOrdinal | global_ordinal_type |
typedef Node | node_type |
Public Types inherited from Xpetra::Operator< Scalar, LocalOrdinal, GlobalOrdinal, Node > | |
typedef Scalar | scalar_type |
The type of the entries of the input and output multivectors. More... | |
typedef LocalOrdinal | local_ordinal_type |
The local index type. More... | |
typedef GlobalOrdinal | global_ordinal_type |
The global index type. More... | |
typedef Node | node_type |
The Kokkos Node type. More... | |
Public Member Functions | |
virtual const Teuchos::RCP < const Xpetra::Map < LocalOrdinal, GlobalOrdinal, Node > > | getMap () const =0 |
Multiplies this matrix by a MultiVector. More... | |
virtual void | doImport (const Matrix &source, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, CombineMode CM)=0 |
Import. More... | |
virtual void | doExport (const Matrix &dest, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, CombineMode CM)=0 |
Export. More... | |
virtual void | doImport (const Matrix &source, const Export< LocalOrdinal, GlobalOrdinal, Node > &exporter, CombineMode CM)=0 |
Import (using an Exporter). More... | |
virtual void | doExport (const Matrix &dest, const Export< LocalOrdinal, GlobalOrdinal, Node > &exporter, CombineMode CM)=0 |
Export (using an Importer). More... | |
virtual bool | hasCrsGraph () const =0 |
Supports the getCrsGraph() call. More... | |
virtual RCP< const CrsGraph > | getCrsGraph () const =0 |
Returns the CrsGraph associated with this matrix. More... | |
void | SetFixedBlockSize (LocalOrdinal blksize, GlobalOrdinal offset=0) |
LocalOrdinal | GetFixedBlockSize () const |
virtual void | SetMaxEigenvalueEstimate (Scalar const &sigma) |
virtual Scalar | GetMaxEigenvalueEstimate () const |
Public Member Functions inherited from Xpetra::Operator< Scalar, LocalOrdinal, GlobalOrdinal, Node > | |
virtual | ~Operator () |
virtual void | removeEmptyProcessesInPlace (const RCP< const Map > &) |
virtual Teuchos::RCP< const Map > | getDomainMap () const =0 |
The Map associated with the domain of this operator, which must be compatible with X.getMap(). More... | |
virtual Teuchos::RCP< const Map > | getRangeMap () const =0 |
The Map associated with the range of this operator, which must be compatible with Y.getMap(). More... | |
virtual void | apply (const MultiVector &X, MultiVector &Y, Teuchos::ETransp mode=Teuchos::NO_TRANS, Scalar alpha=Teuchos::ScalarTraits< Scalar >::one(), Scalar beta=Teuchos::ScalarTraits< Scalar >::zero()) const =0 |
Computes the operator-multivector application. More... | |
virtual bool | hasTransposeApply () const |
Whether this operator supports applying the transpose or conjugate transpose. More... | |
Public Member Functions inherited from Teuchos::Describable | |
void | describe (std::ostream &out, const EVerbosityLevel verbLevel=verbLevel_default) const |
virtual | ~Describable () |
LabeledObject () | |
virtual | ~LabeledObject () |
virtual std::string | getObjectLabel () const |
DescribableStreamManipulatorState | describe (const Describable &describable, const EVerbosityLevel verbLevel=Describable::verbLevel_default) |
std::ostream & | operator<< (std::ostream &os, const DescribableStreamManipulatorState &d) |
Protected Attributes | |
Teuchos::Hashtable < viewLabel_t, RCP< MatrixView > > | operatorViewTable_ |
viewLabel_t | defaultViewLabel_ |
viewLabel_t | currentViewLabel_ |
Private Types | |
typedef Xpetra::Map < LocalOrdinal, GlobalOrdinal, Node > | Map |
typedef Xpetra::CrsMatrix < Scalar, LocalOrdinal, GlobalOrdinal, Node > | CrsMatrix |
typedef Xpetra::CrsGraph < LocalOrdinal, GlobalOrdinal, Node > | CrsGraph |
typedef Xpetra::CrsMatrixFactory < Scalar, LocalOrdinal, GlobalOrdinal, Node > | CrsMatrixFactory |
typedef Xpetra::MatrixView < Scalar, LocalOrdinal, GlobalOrdinal, Node > | MatrixView |
Constructor/Destructor Methods | |
Matrix () | |
virtual | ~Matrix () |
Destructor. More... | |
View management methods | |
void | CreateView (viewLabel_t viewLabel, const RCP< const Map > &rowMap, const RCP< const Map > &colMap) |
void | CreateView (const viewLabel_t viewLabel, const RCP< const Matrix > &A, bool transposeA=false, const RCP< const Matrix > &B=Teuchos::null, bool transposeB=false) |
void | PrintViews (Teuchos::FancyOStream &out) const |
Print all of the views associated with the Matrix. More... | |
void | RemoveView (const viewLabel_t viewLabel) |
const viewLabel_t | SwitchToView (const viewLabel_t viewLabel) |
bool | IsView (const viewLabel_t viewLabel) const |
const viewLabel_t | SwitchToDefaultView () |
const viewLabel_t & | GetDefaultViewLabel () const |
const viewLabel_t & | GetCurrentViewLabel () const |
Insertion/Removal Methods | |
virtual void | insertGlobalValues (GlobalOrdinal globalRow, const ArrayView< const GlobalOrdinal > &cols, const ArrayView< const Scalar > &vals)=0 |
Insert matrix entries, using global IDs. More... | |
virtual void | insertLocalValues (LocalOrdinal localRow, const ArrayView< const LocalOrdinal > &cols, const ArrayView< const Scalar > &vals)=0 |
Insert matrix entries, using local IDs. More... | |
virtual void | replaceGlobalValues (GlobalOrdinal globalRow, const ArrayView< const GlobalOrdinal > &cols, const ArrayView< const Scalar > &vals)=0 |
Replace matrix entries, using global IDs. More... | |
virtual void | replaceLocalValues (LocalOrdinal localRow, const ArrayView< const LocalOrdinal > &cols, const ArrayView< const Scalar > &vals)=0 |
Replace matrix entries, using local IDs. More... | |
virtual void | setAllToScalar (const Scalar &alpha)=0 |
Set all matrix entries equal to scalar. More... | |
virtual void | scale (const Scalar &alpha)=0 |
Scale the current values of a matrix, this = alpha*this. More... | |
Transformational Methods | |
virtual void | resumeFill (const RCP< ParameterList > ¶ms=null)=0 |
virtual void | fillComplete (const RCP< const Map > &domainMap, const RCP< const Map > &rangeMap, const RCP< ParameterList > ¶ms=null)=0 |
Signal that data entry is complete, specifying domain and range maps. More... | |
virtual void | fillComplete (const RCP< ParameterList > ¶ms=null)=0 |
Signal that data entry is complete. More... | |
Methods implementing RowMatrix | |
virtual const RCP< const Map > & | getRowMap () const |
Returns the Map that describes the row distribution in this matrix. More... | |
virtual const RCP< const Map > & | getRowMap (viewLabel_t viewLabel) const |
Returns the Map that describes the row distribution in this matrix. More... | |
virtual const RCP< const Map > & | getColMap () const |
Returns the Map that describes the column distribution in this matrix. This might be null until fillComplete() is called. More... | |
virtual const RCP< const Map > & | getColMap (viewLabel_t viewLabel) const |
Returns the Map that describes the column distribution in this matrix. More... | |
virtual global_size_t | getGlobalNumRows () const =0 |
Returns the number of global rows in this matrix. More... | |
virtual global_size_t | getGlobalNumCols () const =0 |
Returns the number of global columns in the matrix. More... | |
virtual size_t | getNodeNumRows () const =0 |
Returns the number of matrix rows owned on the calling node. More... | |
virtual global_size_t | getGlobalNumEntries () const =0 |
Returns the global number of entries in this matrix. More... | |
virtual size_t | getNodeNumEntries () const =0 |
Returns the local number of entries in this matrix. More... | |
virtual size_t | getNumEntriesInLocalRow (LocalOrdinal localRow) const =0 |
Returns the current number of entries on this node in the specified local row. More... | |
virtual size_t | getGlobalMaxNumRowEntries () const =0 |
Returns the maximum number of entries across all rows/columns on all nodes. More... | |
virtual size_t | getNodeMaxNumRowEntries () const =0 |
Returns the maximum number of entries across all rows/columns on this node. More... | |
virtual bool | isLocallyIndexed () const =0 |
If matrix indices are in the local range, this function returns true. Otherwise, this function returns false. */. More... | |
virtual bool | isGloballyIndexed () const =0 |
If matrix indices are in the global range, this function returns true. Otherwise, this function returns false. */. More... | |
virtual bool | isFillComplete () const =0 |
Returns true if fillComplete() has been called and the matrix is in compute mode. More... | |
virtual void | getLocalRowCopy (LocalOrdinal LocalRow, const ArrayView< LocalOrdinal > &Indices, const ArrayView< Scalar > &Values, size_t &NumEntries) const =0 |
Extract a list of entries in a specified local row of the matrix. Put into storage allocated by calling routine. More... | |
virtual void | getGlobalRowView (GlobalOrdinal GlobalRow, ArrayView< const GlobalOrdinal > &indices, ArrayView< const Scalar > &values) const =0 |
Extract a const, non-persisting view of global indices in a specified row of the matrix. More... | |
virtual void | getLocalRowView (LocalOrdinal LocalRow, ArrayView< const LocalOrdinal > &indices, ArrayView< const Scalar > &values) const =0 |
Extract a const, non-persisting view of local indices in a specified row of the matrix. More... | |
virtual void | getLocalDiagCopy (Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &diag) const =0 |
Get a copy of the diagonal entries owned by this node, with local row indices. More... | |
virtual ScalarTraits< Scalar > ::magnitudeType | getFrobeniusNorm () const =0 |
Get Frobenius norm of the matrix. More... | |
virtual void | leftScale (const Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &x)=0 |
Left scale matrix using the given vector entries. More... | |
virtual void | rightScale (const Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &x)=0 |
Right scale matrix using the given vector entries. More... | |
virtual bool | haveGlobalConstants () const =0 |
Returns true if globalConstants have been computed; false otherwise. More... | |
Overridden from Teuchos::Describable | |
Return a simple one-line description of this object. Print the object with some verbosity level to an FancyOStream object. | |
virtual std::string | description () const =0 |
Return a simple one-line description of this object. More... | |
virtual void | describe (Teuchos::FancyOStream &out, const Teuchos::EVerbosityLevel verbLevel=Teuchos::Describable::verbLevel_default) const =0 |
Print the object with some verbosity level to an FancyOStream object. More... | |
Overridden from Teuchos::LabeledObject | |
virtual void | setObjectLabel (const std::string &objectLabel)=0 |
Additional Inherited Members | |
Static Public Attributes inherited from Teuchos::Describable | |
static const EVerbosityLevel | verbLevel_default |
Xpetra-specific matrix class.
This class is specific to Xpetra and has no analogue in Epetra or Tpetra. The main motivation for this class is to be able to access matrix data in a manner different than how it is stored. For example, it might be more convenient to treat ("view") a matrix stored in compressed row storage as if it were a block matrix. The Xpetra::Matrix class is intended to manage these "views".
How to create a Matrix from an existing CrsMatrix
Definition at line 51 of file Xpetra_Matrix_fwd.hpp.
|
private |
Definition at line 98 of file Xpetra_Matrix.hpp.
|
private |
Definition at line 99 of file Xpetra_Matrix.hpp.
|
private |
Definition at line 100 of file Xpetra_Matrix.hpp.
|
private |
Definition at line 101 of file Xpetra_Matrix.hpp.
|
private |
Definition at line 102 of file Xpetra_Matrix.hpp.
typedef Scalar Xpetra::Matrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >::scalar_type |
Definition at line 105 of file Xpetra_Matrix.hpp.
typedef LocalOrdinal Xpetra::Matrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >::local_ordinal_type |
Definition at line 106 of file Xpetra_Matrix.hpp.
typedef GlobalOrdinal Xpetra::Matrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >::global_ordinal_type |
Definition at line 107 of file Xpetra_Matrix.hpp.
typedef Node Xpetra::Matrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >::node_type |
Definition at line 108 of file Xpetra_Matrix.hpp.
|
inline |
Definition at line 119 of file Xpetra_Matrix.hpp.
|
inlinevirtual |
Destructor.
Definition at line 122 of file Xpetra_Matrix.hpp.
|
inline |
Definition at line 128 of file Xpetra_Matrix.hpp.
|
inline |
Definition at line 135 of file Xpetra_Matrix.hpp.
|
inline |
Print all of the views associated with the Matrix.
Definition at line 180 of file Xpetra_Matrix.hpp.
|
inline |
Definition at line 194 of file Xpetra_Matrix.hpp.
|
inline |
Definition at line 200 of file Xpetra_Matrix.hpp.
|
inline |
Definition at line 207 of file Xpetra_Matrix.hpp.
|
inline |
Definition at line 211 of file Xpetra_Matrix.hpp.
|
inline |
Definition at line 213 of file Xpetra_Matrix.hpp.
|
inline |
Definition at line 215 of file Xpetra_Matrix.hpp.
|
pure virtual |
Insert matrix entries, using global IDs.
All index values must be in the global space.
globalRow
exists as an ID in the global row map isLocallyIndexed() == false
isStorageOptimized() == false
isGloballyIndexed() == true
globalRow
does not belong to the matrix on this node, then it will be communicated to the appropriate node when globalAssemble() is called (which will, at the latest, occur during the next call to fillComplete().) Otherwise, the entries will be inserted in the local matrix. cols
, then the new values will be summed with the old values; this may happen at insertion or during the next call to fillComplete(). hasColMap() == true
, only (cols[i],vals[i]) where cols[i] belongs to the column map on this node will be inserted into the matrix. Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Insert matrix entries, using local IDs.
All index values must be in the local space.
localRow
exists as an ID in the local row map isGloballyIndexed() == false
isStorageOptimized() == false
isLocallyIndexed() == true
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Replace matrix entries, using global IDs.
All index values must be in the global space.
globalRow
is a global row belonging to the matrix on this node.Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Replace matrix entries, using local IDs.
All index values must be in the local space. Note that if a value is not already present for the specified location in the matrix, the input value will be ignored silently.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Set all matrix entries equal to scalar.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Scale the current values of a matrix, this = alpha*this.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Resume fill operations. After calling fillComplete(), resumeFill() must be called before initiating any changes to the matrix.
resumeFill() may be called repeatedly.
isFillActive() == true
isFillComplete() == false
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Signal that data entry is complete, specifying domain and range maps.
Off-node indices are distributed (via globalAssemble()), indices are sorted, redundant indices are eliminated, and global indices are transformed to local indices.
isFillActive() == true
isFillComplete()() == false
isFillActive() == false
isFillComplete() == true
if os == DoOptimizeStorage, then isStorageOptimized() == true
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Signal that data entry is complete.
Off-node entries are distributed (via globalAssemble()), repeated entries are summed, and global indices are transformed to local indices.
isFillActive() == true
isFillComplete()() == false
isFillActive() == false
isFillComplete() == true
if os == DoOptimizeStorage, then isStorageOptimized() == true
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
inlinevirtual |
Returns the Map that describes the row distribution in this matrix.
Definition at line 320 of file Xpetra_Matrix.hpp.
|
inlinevirtual |
Returns the Map that describes the row distribution in this matrix.
Definition at line 323 of file Xpetra_Matrix.hpp.
|
inlinevirtual |
Returns the Map that describes the column distribution in this matrix. This might be null
until fillComplete() is called.
Reimplemented in Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
Definition at line 330 of file Xpetra_Matrix.hpp.
|
inlinevirtual |
Returns the Map that describes the column distribution in this matrix.
Reimplemented in Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
Definition at line 333 of file Xpetra_Matrix.hpp.
|
pure virtual |
Returns the number of global rows in this matrix.
Undefined if isFillActive().
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Returns the number of global columns in the matrix.
Undefined if isFillActive().
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Returns the number of matrix rows owned on the calling node.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Returns the global number of entries in this matrix.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Returns the local number of entries in this matrix.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Returns the current number of entries on this node in the specified local row.
Returns OrdinalTraits<size_t>::invalid() if the specified local row is not valid for this matrix.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Returns the maximum number of entries across all rows/columns on all nodes.
Undefined if isFillActive().
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Returns the maximum number of entries across all rows/columns on this node.
Undefined if isFillActive().
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
If matrix indices are in the local range, this function returns true. Otherwise, this function returns false. */.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
If matrix indices are in the global range, this function returns true. Otherwise, this function returns false. */.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Returns true
if fillComplete() has been called and the matrix is in compute mode.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Extract a list of entries in a specified local row of the matrix. Put into storage allocated by calling routine.
LocalRow | - (In) Local row number for which indices are desired. |
Indices | - (Out) Local column indices corresponding to values. |
Values | - (Out) Matrix values. |
NumIndices | - (Out) Number of indices. |
Note: A std::runtime_error exception is thrown if either Indices
or Values
is not large enough to hold the data associated with row LocalRow
. If LocalRow
is not valid for this node, then Indices
and Values
are unchanged and NumIndices
is returned as OrdinalTraits<size_t>::invalid().
isLocallyIndexed()==true
or hasColMap() == true
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Extract a const, non-persisting view of global indices in a specified row of the matrix.
GlobalRow | - (In) Global row number for which indices are desired. |
Indices | - (Out) Global column indices corresponding to values. |
Values | - (Out) Row values |
isLocallyIndexed() == false
indices.size() == getNumEntriesInGlobalRow(GlobalRow)
Note: If GlobalRow
does not belong to this node, then indices
is set to null.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Extract a const, non-persisting view of local indices in a specified row of the matrix.
LocalRow | - (In) Local row number for which indices are desired. |
Indices | - (Out) Local column indices corresponding to values. |
Values | - (Out) Row values |
isGloballyIndexed() == false
indices.size() == getNumEntriesInLocalRow(LocalRow)
Note: If LocalRow
does not belong to this node, then indices
is set to null.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Get a copy of the diagonal entries owned by this node, with local row indices.
Returns a distributed Vector object partitioned according to this matrix's row map, containing the zero and non-zero diagonals owned by this node.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Get Frobenius norm of the matrix.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Left scale matrix using the given vector entries.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Right scale matrix using the given vector entries.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Returns true if globalConstants have been computed; false otherwise.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Multiplies this matrix by a MultiVector.
\c X is required to be post-imported, i.e., described by the column map of the matrix. \c Y is required to be pre-exported, i.e., described by the row map of the matrix.
Both are required to have constant stride, and they are not permitted to ocupy overlapping space. No runtime checking will be performed in a non-debug build.
This method is templated on the scalar type of MultiVector objects, allowing this method to be applied to MultiVector objects of arbitrary type. However, it is recommended that multiply() not be called directly; instead, use the CrsMatrixMultiplyOp, as it will handle the import/exprt operations required to apply a matrix with non-trivial communication needs.
If beta
is equal to zero, the operation will enjoy overwrite semantics (Y
will be overwritten with the result of the multiplication). Otherwise, the result of the multiplication will be accumulated into Y.Implements
DistObject interface Access function for the Tpetra::Map this DistObject was constructed with.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
|
pure virtual |
|
pure virtual |
Import (using an Exporter).
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Export (using an Importer).
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Return a simple one-line description of this object.
Reimplemented from Teuchos::Describable.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::ReorderedBlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Print the object with some verbosity level to an FancyOStream object.
Reimplemented from Teuchos::Describable.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::ReorderedBlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Reimplemented from Teuchos::Describable.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Supports the getCrsGraph() call.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
pure virtual |
Returns the CrsGraph associated with this matrix.
Implemented in Xpetra::BlockedCrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >, and Xpetra::CrsMatrixWrap< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
|
inline |
Set fixed block size of operator (e.g., 3 for 3 DOFs per node).
blksize,: | block size denoting how many DOFs per node are used (LocalOrdinal) |
offset,: | global offset allows to define operators with global indices starting from a given value "offset" instead of 0. (GlobalOrdinal, default = 0) |
Definition at line 533 of file Xpetra_Matrix.hpp.
|
inline |
Definition at line 560 of file Xpetra_Matrix.hpp.
|
inlinevirtual |
Definition at line 575 of file Xpetra_Matrix.hpp.
|
inlinevirtual |
Definition at line 581 of file Xpetra_Matrix.hpp.
|
protected |
Definition at line 599 of file Xpetra_Matrix.hpp.
|
protected |
Definition at line 601 of file Xpetra_Matrix.hpp.
|
protected |
Definition at line 602 of file Xpetra_Matrix.hpp.