# MatCoarsenApply
Gets a coarsen for a matrix. 
## Synopsis
```
#include "petscmatcoarsen.h" 
PetscErrorCode MatCoarsenApply(MatCoarsen coarser)
```
Collective on coarser


## Input Parameter

- ***coarsen -*** the coarsen



## Options Database Keys
To specify the coarsen through the options database, use one of
the following
```none
-mat_coarsen_type mis|hem|misk
```
To see the coarsen result
```none
-mat_coarsen_view
```




## Notes
Use `MatCoarsenGetData()` to access the results of the coarsening

The user can define additional coarsens; see `MatCoarsenRegister()`.


## See Also
 `MatCoarsen`, `MatCoarseSetFromOptions()`, `MatCoarsenSetType()`, `MatCoarsenRegister()`, `MatCoarsenCreate()`,
`MatCoarsenDestroy()`, `MatCoarsenSetAdjacency()`
`MatCoarsenGetData()`

## Level
advanced

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/coarsen/coarsen.c.html#MatCoarsenApply">src/mat/coarsen/coarsen.c</A>

## Implementations

<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/coarsen/impls/hem/hem.c.html#MatCoarsenApply_HEM">MatCoarsenApply_HEM in src/mat/coarsen/impls/hem/hem.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/coarsen/impls/mis/mis.c.html#MatCoarsenApply_MIS">MatCoarsenApply_MIS in src/mat/coarsen/impls/mis/mis.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/coarsen/impls/misk/misk.c.html#MatCoarsenApply_MISK">MatCoarsenApply_MISK in src/mat/coarsen/impls/misk/misk.c</A><BR>


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


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