:orphan:
# DMFieldDestroy
destroy a `DMField`
## Synopsis
```
#include "petscdmfield.h"
#include "petscdmfield.h"
PetscErrorCode DMFieldDestroy(DMField *field)
```
Collective
## Input Parameter
- ***field -*** address of `DMField`
## See Also
`DMField`, `DMFieldCreate()`
## Level
advanced
## Location
src/dm/field/interface/dmfield.c
## Examples
src/dm/field/tutorials/ex1.c
## Implementations
DMFieldDestroy_DA in src/dm/field/impls/da/dmfieldda.c
DMFieldDestroy_DS in src/dm/field/impls/ds/dmfieldds.c
DMFieldDestroy_Shell in src/dm/field/impls/shell/dmfieldshell.c
---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/dm/field/interface/dmfield.c)
[Index of all DM routines](index.md)
[Table of Contents for all manual pages](/manualpages/index.md)
[Index of all manual pages](/manualpages/singleindex.md)