# PCDeflationSetSpaceToCompute
Set deflation space type and size to compute. 
## Synopsis
```
#include "petscksp.h" 
PetscErrorCode PCDeflationSetSpaceToCompute(PC pc, PCDeflationSpaceType type, PetscInt size)
```
Logically Collective


## Input Parameters

- ***pc   -*** the preconditioner context
- ***type -*** deflation space type to compute (or `PETSC_IGNORE`)
- ***size -*** size of the space to compute (or `PETSC_DEFAULT`)



## Options Database Keys

- ***-pc_deflation_compute_space      <haar> -*** compute `PCDeflationSpaceType` deflation space
- ***-pc_deflation_compute_space_size <1>    -*** size of the deflation space



## Notes
For wavelet-based deflation, size represents number of levels.

The deflation space is computed in `PCSetUp()`.




## See Also
 `PCDeflationSetLevels()`, `PCDEFLATION`

## Level
intermediate

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ksp/pc/impls/deflation/deflation.c.html#PCDeflationSetSpaceToCompute">src/ksp/pc/impls/deflation/deflation.c</A>

## Implementations

<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ksp/pc/impls/deflation/deflation.c.html#PCDeflationSetSpaceToCompute_Deflation">PCDeflationSetSpaceToCompute_Deflation in src/ksp/pc/impls/deflation/deflation.c</A><BR>


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


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