#include "petscmat.h" PetscErrorCode MatConvert(Mat mat, MatType newtype,MatReuse reuse,Mat *M)Collective on Mat
mat | - the matrix | |
newtype | - new matrix type. Use MATSAME to create a new matrix of the same type as the original matrix. | |
reuse | - denotes if the destination matrix is to be created or reused. Use MAT_INPLACE_MATRIX for inplace conversion (that is when you want the input mat to be changed to contain the matrix in the new format), otherwise use MAT_INITIAL_MATRIX or MAT_REUSE_MATRIX (can only be used after the first call was made with MAT_INITIAL_MATRIX, causes the matrix space in M to be reused). |
Cannot be used to convert a sequential matrix to parallel or parallel to sequential, the MPI communicator of the generated matrix is always the same as the communicator of the input matrix.
Level:intermediate
Location:src/mat/interface/matrix.c
Index of all Mat routines
Table of Contents for all manual pages
Index of all manual pages