# DMCompositeRestoreLocalAccessArray
Returns the vectors obtained with `DMCompositeGetLocalAccessArray()`. 
## Synopsis
```
#include "petscdmcomposite.h"  
PetscErrorCode DMCompositeRestoreLocalAccessArray(DM dm, Vec pvec, PetscInt nwanted, const PetscInt *wanted, Vec *vecs)
```
Collective on dm.


## Input Parameters

- ***dm -*** the `DMCOMPOSITE` object
- ***pvec -*** packed vector
- ***nwanted -*** number of vectors wanted
- ***wanted -*** sorted array of vectors wanted, or NULL to restore all vectors
- ***vecs -*** array of local vectors to return





## Note
nwanted and wanted must match the values given to `DMCompositeGetLocalAccessArray()`
otherwise the call will fail.


## See Also
 `DMCOMPOSITE`, `DM`, `DMCompositeGetLocalAccessArray()`, `DMCompositeRestoreAccessArray()`,
`DMCompositeRestoreAccess()`, `DMCompositeRestoreEntries()`,
`DMCompositeScatter()`, `DMCompositeGather()`

## Level
advanced

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/impls/composite/pack.c.html#DMCompositeRestoreLocalAccessArray">src/dm/impls/composite/pack.c</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/dm/impls/composite/pack.c)


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