#include "petscmat.h" PetscErrorCode MatGetSubMatrices(Mat mat,PetscInt n,const IS irow[],const IS icol[],MatReuse scall,Mat *submat[])Collective on Mat Many br
mat | - the matrix Many br | |
n | - the number of submatrixes to be extracted (on this processor, may be zero) Many br | |
irow, icol | - index sets of rows and columns to extract Many br | |
scall | - either MAT_INITIAL_MATRIX or MAT_REUSE_MATRIX Many br |
Some matrix types place restrictions on the row and column Many brindices, such as that they be sorted or that they be equal to each other. Many br
The index sets may not have duplicate entries. Many br
When extracting submatrices from a parallel matrix, each processor can Many brform a different submatrix by setting the rows and columns of its Many brindividual index sets according to the local submatrix desired. Many br
When finished using the submatrices, the user should destroy Many brthem with MatDestroyMatrices(). Many br
MAT_REUSE_MATRIX can only be used when the nonzero structure of the Many broriginal matrix has not changed from that last call to MatGetSubMatrices(). Many br
This routine creates the matrices in submat; you should NOT create them before Many brcalling it. It also allocates the array of matrix pointers submat. Many br
For BAIJ matrices the index sets must respect the block structure, that is if they Many brrequest one row/column in a block, they must request all rows/columns that are in Many brthat block. For example, if the block size is 2 you cannot request just row 0 and Many brcolumn 0. Many br
Many br
Level:advanced
Location:src/mat/interface/matrix.c
Index of all Mat routines
Table of Contents for all manual pages
Index of all manual pages