MatCreateSeqAIJSELL#
Creates a sparse matrix of type MATSEQAIJSELL. This type inherits from AIJ and is largely identical, but keeps a “shadow” copy of the matrix in MATSEQSELL format, which is used when this format may be more suitable for a requested operation. Currently, MATSEQSELL format is used for MatMult(), MatMultTranspose(), MatMultAdd(), MatMultTransposeAdd(), and MatSOR() operations.
Synopsis#
PetscErrorCode MatCreateSeqAIJSELL(MPI_Comm comm, PetscInt m, PetscInt n, PetscInt nz, const PetscInt nnz[], Mat *A)
Collective
Input Parameters#
comm - MPI communicator, set to
PETSC_COMM_SELFm - number of rows
n - number of columns
nz - number of nonzeros per row (same for all rows)
nnz - array containing the number of nonzeros in the various rows (possibly different for each row) or
NULL
Output Parameter#
A - the matrix
Options Database Keys#
-mat_aijsell_eager_shadow - Construct shadow matrix upon matrix assembly; default is to take a “lazy” approach, performing this step the first time the matrix is applied
Notes#
If nnz is given then nz is ignored
Because MATSEQAIJSELL is a subtype of MATSEQAIJ, the option -mat_seqaij_type seqaijsell can be used to make
sequential MATSEQAIJ matrices default to being instances of MATSEQAIJSELL.
See Also#
Matrices, Mat, MatCreate(), MatCreateMPIAIJSELL(), MatSetValues()
Level#
intermediate
Location#
src/mat/impls/aij/seq/aijsell/aijsell.c
Index of all Mat routines
Table of Contents for all manual pages
Index of all manual pages