#include "petscmat.h" PetscErrorCode MatCreateMPIAIJWithSplitArrays(MPI_Comm comm,PetscInt m,PetscInt n,PetscInt M,PetscInt N,PetscInt i[],PetscInt j[],PetscScalar a[],PetscInt oi[], PetscInt oj[],PetscScalar oa[],Mat *mat)Collective on MPI_Comm Many br
comm | - MPI communicator Many br | |
m | - number of local rows (Cannot be PETSC_DECIDE) Many br | |
n | - This value should be the same as the local size used in creating the Many brx vector for the matrix-vector product y = Ax. (or PETSC_DECIDE to have Many brcalculated if N is given) For square matrices n is almost always m. Many br | |
M | - number of global rows (or PETSC_DETERMINE to have calculated if m is given) Many br | |
N | - number of global columns (or PETSC_DETERMINE to have calculated if n is given) Many br | |
i | - row indices for "diagonal" portion of matrix Many br | |
j | - column indices Many br | |
a | - matrix values Many br | |
oi | - row indices for "off-diagonal" portion of matrix Many br | |
oj | - column indices Many br | |
oa | - matrix values Many br |
Many br
The i and j indices are 0 based Many br
See MatCreateAIJ() for the definition of "diagonal" and "off-diagonal" portion of the matrix Many br
This sets local rows and cannot be used to set off-processor values. Many br
Use of this routine is discouraged because it is inflexible and cumbersome to use. It is extremely rare that a Many brlegacy application natively assembles into exactly this split format. The code to do so is nontrivial and does Many brnot easily support in-place reassembly. It is recommended to use MatSetValues() (or a variant thereof) because Many brthe resulting assembly is easier to implement, will work with any matrix format, and the user does not have to Many brkeep track of the underlying array. Use MatSetOption(A,MAT_IGNORE_OFF_PROC_ENTRIES,PETSC_TRUE) to disable all Many brcommunication if it is known that only local entries will be set. Many br
Level:advanced
Location:src/mat/impls/aij/mpi/mpiaij.c
Index of all Mat routines
Table of Contents for all manual pages
Index of all manual pages