# DMPlexGetDepth
Get the depth of the DAG representing this mesh 
## Synopsis
```
#include "petscdmplex.h"   
PetscErrorCode DMPlexGetDepth(DM dm, PetscInt *depth)
```
Not Collective


## Input Parameter

- ***dm    -*** The `DMPLEX` object



## Output Parameter

- ***depth -*** The number of strata (breadth first levels) in the DAG





## Notes
This returns maximum of point depths over all points, i.e. maximum value of the label returned by `DMPlexGetDepthLabel()`.

The point depth is described more in detail in `DMPlexGetDepthStratum()`.

An empty mesh gives -1.


## See Also
 [](chapter_unstructured), `DM`, `DMPLEX`, `DMPlexGetDepthLabel()`, `DMPlexGetDepthStratum()`, `DMPlexGetPointDepth()`, `DMPlexSymmetrize()`

## Level
developer

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

## Examples
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ts/tutorials/ex11_sa.c.html">src/ts/tutorials/ex11_sa.c.html</A><BR>


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


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