# MatDenseRestoreColumn
returns access to a column of a `MATDENSE` matrix which is returned by `MatDenseGetColumn()`. 
## Synopsis
```
#include "petscmat.h" 
PetscErrorCode MatDenseRestoreColumn(Mat A, PetscScalar **vals)
```
Not Collective


## Input Parameters

- ***mat -*** a `MATSEQDENSE` or `MATMPIDENSE` matrix
- ***vals -*** pointer to the data (may be NULL)





## See Also
 `MATDENSE`, `MatDenseGetColumn()`

## Level
intermediate

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/impls/dense/seq/dense.c.html#MatDenseRestoreColumn">src/mat/impls/dense/seq/dense.c</A>

## Examples
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ts/tutorials/ex20opt_ic.c.html">src/ts/tutorials/ex20opt_ic.c.html</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ts/tutorials/ex20opt_p.c.html">src/ts/tutorials/ex20opt_p.c.html</A><BR>

## Implementations

<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/impls/dense/mpi/mpidense.c.html#MatDenseRestoreColumn_MPIDense">MatDenseRestoreColumn_MPIDense in src/mat/impls/dense/mpi/mpidense.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/impls/dense/seq/dense.c.html#MatDenseRestoreColumn_SeqDense">MatDenseRestoreColumn_SeqDense in src/mat/impls/dense/seq/dense.c</A><BR>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/mat/impls/dense/seq/dense.c)


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