# MatCreateIS
Creates a "process" unassembled matrix, `MATIS`, assembled on each process but not across processes. 
## Synopsis
```
#include "petscmat.h" 
PetscErrorCode MatCreateIS(MPI_Comm comm, PetscInt bs, PetscInt m, PetscInt n, PetscInt M, PetscInt N, ISLocalToGlobalMapping rmap, ISLocalToGlobalMapping cmap, Mat *A)
```

## Input Parameters

- ***comm    -*** MPI communicator that will share the matrix
- ***bs      -*** block size of the matrix
- ***m,n,M,N -*** local and/or global sizes of the left and right vector used in matrix vector products
- ***rmap    -*** local to global map for rows
- ***cmap    -*** local to global map for cols



## Output Parameter

- ***A -*** the resulting matrix





## Notes
m and n are NOT related to the size of the map; they represent the size of the local parts of the distributed vectors
used in `MatMult()` operations. The sizes of rmap and cmap define the size of the local matrices.

If rmap (cmap) is NULL, then the local row (column) spaces matches the global space.


## See Also
 `MATIS`, `MatSetLocalToGlobalMapping()`

## Level
advanced

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/impls/is/matis.c.html#MatCreateIS">src/mat/impls/is/matis.c</A>

## Examples
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/tutorials/ex3.c.html">src/mat/tutorials/ex3.c.html</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ksp/ksp/tutorials/ex59.c.html">src/ksp/ksp/tutorials/ex59.c.html</A><BR>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/mat/impls/is/matis.c)


[Index of all Mat routines](index.md)  
[Table of Contents for all manual pages](/docs/manualpages/index.md)  
[Index of all manual pages](/docs/manualpages/singleindex.md)  
