# PetscSFCreateInverseSF
given a `PetscSF` in which all vertices have degree 1, creates the inverse map 
## Synopsis
```
#include "petscsf.h" 
PetscErrorCode PetscSFCreateInverseSF(PetscSF sf, PetscSF *isf)
```
Collective


## Input Parameter

- ***sf -*** star forest to invert



## Output Parameter

- ***isf -*** inverse of sf





## Notes
All roots must have degree 1.

The local space may be a permutation, but cannot be sparse.


## See Also
 `PetscSFType`, `PetscSFSetGraph()`

## Level
advanced

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

## Examples
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/vec/is/sf/tutorials/ex1.c.html">src/vec/is/sf/tutorials/ex1.c.html</A><BR>


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


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