# PetscSpaceDestroy
Destroys a `PetscSpace` object 
## Synopsis
```
#include "petscfe.h"  
PetscErrorCode PetscSpaceDestroy(PetscSpace *sp)
```
Collective on sp


## Input Parameter

- ***sp -*** the PetscSpace object to destroy





## See Also
 `PetscSpace`, `PetscSpaceCreate()`

## Level
beginner

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/dt/space/interface/space.c.html#PetscSpaceDestroy">src/dm/dt/space/interface/space.c</A>

## Implementations

<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/dt/space/impls/point/spacepoint.c.html#PetscSpaceDestroy_Point">PetscSpaceDestroy_Point in src/dm/dt/space/impls/point/spacepoint.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/dt/space/impls/poly/spacepoly.c.html#PetscSpaceDestroy_Polynomial">PetscSpaceDestroy_Polynomial in src/dm/dt/space/impls/poly/spacepoly.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/dt/space/impls/ptrimmed/spaceptrimmed.c.html#PetscSpaceDestroy_Ptrimmed">PetscSpaceDestroy_Ptrimmed in src/dm/dt/space/impls/ptrimmed/spaceptrimmed.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/dt/space/impls/subspace/spacesubspace.c.html#PetscSpaceDestroy_Subspace">PetscSpaceDestroy_Subspace in src/dm/dt/space/impls/subspace/spacesubspace.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/dt/space/impls/sum/spacesum.c.html#PetscSpaceDestroy_Sum">PetscSpaceDestroy_Sum in src/dm/dt/space/impls/sum/spacesum.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/dt/space/impls/tensor/spacetensor.c.html#PetscSpaceDestroy_Tensor">PetscSpaceDestroy_Tensor in src/dm/dt/space/impls/tensor/spacetensor.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/dt/space/impls/wxy/spacewxy.c.html#PetscSpaceDestroy_WXY">PetscSpaceDestroy_WXY in src/dm/dt/space/impls/wxy/spacewxy.c</A><BR>


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


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