:orphan:
# DMForestGetAdaptivitySF
Get `PetscSF`s that relate the pre-adaptation forest to the post-adaptation forest. Adaptation can be any combination of refinement, coarsening, repartition, and change of overlap, so there may be some cells of the pre-adaptation that are parents of post-adaptation cells, and vice versa.  Therefore there are two `PetscSF`s: one that relates pre-adaptation coarse cells to post-adaptation fine cells, and one that relates pre-adaptation fine cells to post-adaptation coarse cells. 
## Synopsis
```
#include "petscdmforest.h" 
#include "petscdm.h" 
#include "petscdmlabel.h" 
PetscErrorCode DMForestGetAdaptivitySF(DM dm, PetscSF *preCoarseToFine, PetscSF *coarseToPreFine)
```
Not Collective


## Input Parameter

- ***dm -*** the post-adaptation forest



## Output Parameters

- ***preCoarseToFine -*** pre-adaptation coarse cells to post-adaptation fine cells: BCast goes from pre- to post-
- ***coarseToPreFine -*** post-adaptation coarse cells to pre-adaptation fine cells: BCast goes from post- to pre-





## See Also
 `DM`, `DMFOREST`, `DMForestGetComputeAdaptivitySF()`, `DMForestSetComputeAdaptivitySF()`

## Level
advanced

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/impls/forest/forest.c.html#DMForestGetAdaptivitySF">src/dm/impls/forest/forest.c</A>


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


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