# PetscSpaceCreate
Creates an empty `PetscSpace` object. The type can then be set with `PetscSpaceSetType()`. 
## Synopsis
```
#include "petscfe.h"  
PetscErrorCode PetscSpaceCreate(MPI_Comm comm, PetscSpace *sp)
```
Collective


## Input Parameter

- ***comm -*** The communicator for the `PetscSpace` object



## Output Parameter

- ***sp -*** The `PetscSpace` object





## See Also
 `PetscSpace`, `PetscSpaceSetType()`, `PETSCSPACEPOLYNOMIAL`

## Level
beginner

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/dt/space/interface/space.c.html#PetscSpaceCreate">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#PetscSpaceCreate_Point">PetscSpaceCreate_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#PetscSpaceCreate_Polynomial">PetscSpaceCreate_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#PetscSpaceCreate_Ptrimmed">PetscSpaceCreate_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#PetscSpaceCreate_Subspace">PetscSpaceCreate_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#PetscSpaceCreate_Sum">PetscSpaceCreate_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#PetscSpaceCreate_Tensor">PetscSpaceCreate_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#PetscSpaceCreate_WXY">PetscSpaceCreate_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)  
