# ISRenumber
Renumbers the non-negative entries of an index set in a contiguous way, starting from 0. 
## Synopsis
```
#include "petscis.h" 
PetscErrorCode ISRenumber(IS subset, IS subset_mult, PetscInt *N, IS *subset_n)
```
Collective


## Input Parameters

- ***subset -*** the index set
- ***subset_mult -*** the multiplicity of each entry in subset (optional, can be NULL)



## Output Parameters

- ***N -*** one past the largest entry of the new IS
- ***subset_n -*** the new IS


Notes: All negative entries are mapped to -1. Indices with non positive multiplicities are skipped.




## See Also


## Level
intermediate

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/vec/is/is/interface/index.c.html#ISRenumber">src/vec/is/is/interface/index.c</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/vec/is/is/interface/index.c)


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