:orphan:
# PetscSpaceTensorGetSubspace
Get a space in the tensor product space 
## Synopsis
```
#include "petscfe.h" 
PetscErrorCode PetscSpaceTensorGetSubspace(PetscSpace sp, PetscInt s, PetscSpace *subsp)
```

## Input Parameters

- ***sp -*** the function space object
- ***s  -*** The space number



## Output Parameter

- ***subsp -*** the `PetscSpace`





## Note
The name GetSubspace is misleading because it is actually getting one of the defining spaces of the tensor product space, not a Subspace of it


## See Also
 `PETSCSPACETENSOR`, `PetscSpace`, `PetscSpaceTensorSetSubspace()`, `PetscSpaceSetDegree()`, `PetscSpaceSetNumVariables()`

## Level
intermediate

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/dt/space/impls/tensor/spacetensor.c.html#PetscSpaceTensorGetSubspace">src/dm/dt/space/impls/tensor/spacetensor.c</A>

## Implementations

<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/dt/space/impls/tensor/spacetensor.c.html#PetscSpaceTensorGetSubspace_Tensor">PetscSpaceTensorGetSubspace_Tensor in src/dm/dt/space/impls/tensor/spacetensor.c</A><BR>


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


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