ML Version of the Day
|
Basic wrapper from ML_Operator to Epetra_RowMatrix. More...
#include <ml_RowMatrix.h>
Public Member Functions | |
RowMatrix (ML_Operator *Op, const Epetra_Comm *Comm=0, const bool cheap=false, const USR_COMM=MPI_COMM_WORLD) | |
Constructor, constructs Comm object if not provided. | |
virtual | ~RowMatrix () |
Destructor. | |
virtual int | NumMyRowEntries (int MyRow, int &NumEntries) const |
Returns the number of nonzero entries in MyRow. | |
virtual int | MaxNumEntries () const |
Returns the maximum of NumMyRowEntries() over all rows. | |
virtual int | ExtractMyRowCopy (int MyRow, int Length, int &NumEntries, double *Values, int *Indices) const |
Returns a copy of the specified local row in user-provided arrays. | |
virtual int | ExtractDiagonalCopy (Epetra_Vector &Diagonal) const |
Returns a copy of the main diagonal in a user-provided vector. | |
virtual int | Multiply (bool TransA, const Epetra_MultiVector &X, Epetra_MultiVector &Y) const |
Returns the result of a Epetra_RowMatrix multiplied by a Epetra_MultiVector X in Y. | |
virtual int | Solve (bool, bool, bool, const Epetra_MultiVector &, Epetra_MultiVector &) const |
Returns result of a local-only solve using a triangular Epetra_RowMatrix with Epetra_MultiVectors X and Y. | |
virtual int | Apply (const Epetra_MultiVector &X, Epetra_MultiVector &Y) const |
virtual int | ApplyInverse (const Epetra_MultiVector &, Epetra_MultiVector &) const |
virtual int | InvRowSums (Epetra_Vector &) const |
Computes the sum of absolute values of the rows of the Epetra_RowMatrix, results returned in x. | |
virtual int | LeftScale (const Epetra_Vector &) |
Scales the Epetra_RowMatrix on the left with a Epetra_Vector x. | |
virtual int | InvColSums (Epetra_Vector &) const |
Computes the sum of absolute values of the columns of the Epetra_RowMatrix, results returned in x. | |
virtual int | RightScale (const Epetra_Vector &) |
Scales the Epetra_RowMatrix on the right with a Epetra_Vector x. | |
virtual bool | Filled () const |
If FillComplete() has been called, this query returns true, otherwise it returns false. | |
virtual double | NormInf () const |
Returns the infinity norm of the global matrix. | |
virtual double | NormOne () const |
Returns the one norm of the global matrix. | |
virtual int | NumGlobalNonzeros () const |
Returns the number of nonzero entries in the global matrix. | |
virtual int | NumGlobalRows () const |
Returns the number of global matrix rows. | |
virtual int | NumGlobalCols () const |
Returns the number of global matrix columns. | |
virtual int | NumGlobalDiagonals () const |
Returns the number of global nonzero diagonal entries, based on global row/column index comparisons. | |
virtual long long | NumGlobalNonzeros64 () const |
Returns the number of nonzero entries in the global matrix. | |
virtual long long | NumGlobalRows64 () const |
Returns the number of global matrix rows. | |
virtual long long | NumGlobalCols64 () const |
Returns the number of global matrix columns. | |
virtual long long | NumGlobalDiagonals64 () const |
Returns the number of global nonzero diagonal entries, based on global row/column index comparisons. | |
virtual int | NumMyNonzeros () const |
Returns the number of nonzero entries in the calling processor's portion of the matrix. | |
virtual int | NumMyRows () const |
Returns the number of matrix rows owned by the calling processor. | |
virtual int | NumMyCols () const |
Returns the number of matrix columns owned by the calling processor. | |
virtual int | NumMyDiagonals () const |
Returns the number of local nonzero diagonal entries, based on global row/column index comparisons. | |
virtual bool | LowerTriangular () const |
If matrix is lower triangular in local index space, this query returns true, otherwise it returns false. | |
virtual bool | UpperTriangular () const |
If matrix is upper triangular in local index space, this query returns true, otherwise it returns false. | |
virtual const Epetra_Map & | RowMatrixRowMap () const |
Returns the Epetra_Map object associated with the rows of this matrix. | |
virtual const Epetra_Map & | RowMatrixColMap () const |
Returns the Epetra_Map object associated with the columns of this matrix. | |
virtual const Epetra_Import * | RowMatrixImporter () const |
Returns the Epetra_Import object that contains the import operations for distributed operations. | |
int | SetOwnership (bool) |
Sets ownership. | |
int | SetUseTranspose (bool) |
Sets use transpose (not implemented). | |
bool | UseTranspose () const |
Returns the current UseTranspose setting. | |
bool | HasNormInf () const |
Returns true if the this object can provide an approximate Inf-norm, false otherwise. | |
const Epetra_Comm & | Comm () const |
Returns a pointer to the Epetra_Comm communicator associated with this operator. | |
const Epetra_Map & | OperatorDomainMap () const |
Returns the Epetra_Map object associated with the domain of this operator. | |
const Epetra_Map & | OperatorRangeMap () const |
Returns the Epetra_Map object associated with the range of this operator. | |
void | SetLabel (const char *label) |
const char * | Label () const |
const Epetra_BlockMap & | Map () const |
Returns a reference to RowMatrix->Map(). | |
int | Print () const |
Print the global matrix. This uses a potentially artificial numbering. | |
Basic wrapper from ML_Operator to Epetra_RowMatrix.
|
inlinevirtual |
Implements Epetra_Operator.
|
inlinevirtual |
Implements Epetra_Operator.
|
inlinevirtual |
Returns a pointer to the Epetra_Comm communicator associated with this operator.
Implements Epetra_Operator.
Referenced by ML_Epetra::MultiLevelPreconditioner::MultiLevelPreconditioner(), and ML_Epetra::MultiLevelPreconditioner::MultiLevelPreconditioner().
|
virtual |
Returns a copy of the main diagonal in a user-provided vector.
Out | Diagonal - Extracted main diagonal. |
Implements Epetra_RowMatrix.
|
virtual |
Returns a copy of the specified local row in user-provided arrays.
In | MyRow - Local row to extract. |
In | Length - Length of Values and Indices. |
Out | NumEntries - Number of nonzero entries extracted. |
Out | Values - Extracted values for this row. |
Out | Indices - Extracted global column indices for the corresponding values. |
Implements Epetra_RowMatrix.
|
inlinevirtual |
If FillComplete() has been called, this query returns true, otherwise it returns false.
Implements Epetra_RowMatrix.
|
inlinevirtual |
Returns true if the this object can provide an approximate Inf-norm, false otherwise.
Implements Epetra_Operator.
|
inlinevirtual |
Computes the sum of absolute values of the columns of the Epetra_RowMatrix, results returned in x.
The vector x will return such that x[j] will contain the inverse of sum of the absolute values of the this matrix will be sca such that A(i,j) = x(j)*A(i,j) where i denotes the global row number of A and j denotes the global column number of A. Using the resulting vector from this function as input to RighttScale() will make the one norm of the resulting matrix exactly 1.
Out | x -A Epetra_Vector containing the column sums of the this matrix. |
Implements Epetra_RowMatrix.
|
inlinevirtual |
Computes the sum of absolute values of the rows of the Epetra_RowMatrix, results returned in x.
The vector x will return such that x[i] will contain the inverse of sum of the absolute values of the this matrix will be scaled such that A(i,j) = x(i)*A(i,j) where i denotes the global row number of A and j denotes the global column number of A. Using the resulting vector from this function as input to LeftScale() will make the infinity norm of the resulting matrix exactly 1.
Out | x -A Epetra_Vector containing the row sums of the this matrix. |
Implements Epetra_RowMatrix.
|
inlinevirtual |
Implements Epetra_Operator.
|
inlinevirtual |
Scales the Epetra_RowMatrix on the left with a Epetra_Vector x.
The this matrix will be scaled such that A(i,j) = x(i)*A(i,j) where i denotes the row number of A and j denotes the column number of A.
In | x -A Epetra_Vector to solve for. |
Implements Epetra_RowMatrix.
|
virtual |
If matrix is lower triangular in local index space, this query returns true, otherwise it returns false.
Implements Epetra_RowMatrix.
|
inlinevirtual |
Returns a reference to RowMatrix->Map().
Implements Epetra_SrcDistObject.
|
virtual |
Returns the maximum of NumMyRowEntries() over all rows.
Implements Epetra_RowMatrix.
|
virtual |
Returns the result of a Epetra_RowMatrix multiplied by a Epetra_MultiVector X in Y.
In | TransA -If true, multiply by the transpose of matrix, otherwise just use matrix. |
In | X - A Epetra_MultiVector of dimension NumVectors to multiply with matrix. |
Out | Y -A Epetra_MultiVector of dimension NumVectorscontaining result. |
Implements Epetra_RowMatrix.
|
virtual |
Returns the infinity norm of the global matrix.
Implements Epetra_RowMatrix.
|
inlinevirtual |
Returns the one norm of the global matrix.
Implements Epetra_RowMatrix.
|
virtual |
Returns the number of global matrix columns.
Implements Epetra_RowMatrix.
|
virtual |
Returns the number of global nonzero diagonal entries, based on global row/column index comparisons.
Implements Epetra_RowMatrix.
|
virtual |
Returns the number of nonzero entries in the global matrix.
Implements Epetra_RowMatrix.
|
virtual |
Returns the number of global matrix rows.
Implements Epetra_RowMatrix.
|
virtual |
Returns the number of matrix columns owned by the calling processor.
Implements Epetra_RowMatrix.
|
virtual |
Returns the number of local nonzero diagonal entries, based on global row/column index comparisons.
Implements Epetra_RowMatrix.
|
virtual |
Returns the number of nonzero entries in the calling processor's portion of the matrix.
Implements Epetra_RowMatrix.
|
virtual |
Returns the number of nonzero entries in MyRow.
In | MyRow - Local row. |
Out | NumEntries - Number of nonzero values present. |
Implements Epetra_RowMatrix.
|
virtual |
Returns the number of matrix rows owned by the calling processor.
Implements Epetra_RowMatrix.
|
inlinevirtual |
Returns the Epetra_Map object associated with the domain of this operator.
Implements Epetra_Operator.
Referenced by ML_Epetra::MultiLevelPreconditioner::MultiLevelPreconditioner(), and ML_Epetra::MultiLevelPreconditioner::MultiLevelPreconditioner().
|
inlinevirtual |
Returns the Epetra_Map object associated with the range of this operator.
Implements Epetra_Operator.
Referenced by ML_Epetra::MultiLevelPreconditioner::MultiLevelPreconditioner(), and ML_Epetra::MultiLevelPreconditioner::MultiLevelPreconditioner().
|
inlinevirtual |
Scales the Epetra_RowMatrix on the right with a Epetra_Vector x.
The this matrix will be scaled such that A(i,j) = x(j)*A(i,j) where i denotes the global row number of A and j denotes the global column number of A.
In | x -The Epetra_Vector used for scaling this. |
Implements Epetra_RowMatrix.
|
virtual |
Returns the Epetra_Map object associated with the columns of this matrix.
Implements Epetra_RowMatrix.
|
virtual |
Returns the Epetra_Import object that contains the import operations for distributed operations.
Implements Epetra_RowMatrix.
|
virtual |
Returns the Epetra_Map object associated with the rows of this matrix.
Implements Epetra_RowMatrix.
|
inlinevirtual |
Sets use transpose (not implemented).
Implements Epetra_Operator.
|
inlinevirtual |
Returns result of a local-only solve using a triangular Epetra_RowMatrix with Epetra_MultiVectors X and Y.
This method will perform a triangular solve independently on each processor of the parallel machine. No communication is performed.
In | Upper -If true, solve Ux = y, otherwise solve Lx = y. |
In | Trans -If true, solve transpose problem. |
In | UnitDiagonal -If true, assume diagonal is unit (whether it's stored or not). |
In | X - A Epetra_MultiVector of dimension NumVectors to solve for. |
Out | Y -A Epetra_MultiVector of dimension NumVectors containing result. |
Implements Epetra_RowMatrix.
|
virtual |
If matrix is upper triangular in local index space, this query returns true, otherwise it returns false.
Implements Epetra_RowMatrix.
|
inlinevirtual |
Returns the current UseTranspose setting.
Implements Epetra_Operator.