:orphan:
# MatPartitioningImprove
Improves the quality of a given partition. 
## Synopsis
```
#include "petscmat.h" 
PetscErrorCode MatPartitioningImprove(MatPartitioning matp, IS *partitioning)
```
Collective


## Input Parameters

- ***matp -*** the matrix partitioning object
- ***partitioning -*** the original partitioning. For each local node this tells the processor
number that that node is assigned to.



## Options Database Key

- ***-mat_partitioning_improve -*** improve the quality of the given partition





## See Also
 [](ch_matrices), `Mat`, `MatPartitioning`, `MatPartitioningType`, `MatPartitioningApply()`, `MatPartitioningCreate()`,
`MatPartitioningDestroy()`, `MatPartitioningSetAdjacency()`, `ISPartitioningToNumbering()`,
`ISPartitioningCount()`

## Level
beginner

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/partition/partition.c.html#MatPartitioningImprove">src/mat/partition/partition.c</A>

## Implementations

<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/partition/impls/hierarchical/hierarchical.c.html#MatPartitioningImprove_Hierarchical">MatPartitioningImprove_Hierarchical in src/mat/partition/impls/hierarchical/hierarchical.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/partition/impls/pmetis/pmetis.c.html#MatPartitioningImprove_Parmetis">MatPartitioningImprove_Parmetis in src/mat/partition/impls/pmetis/pmetis.c</A><BR>


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


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