# DMPlexComputeGradientFVM
Compute geometric factors for gradient reconstruction, which are stored in the geometry data, and compute layout for gradient data 
## Synopsis
```
#include "petscdmplex.h"   
#include "petscfe.h"       
PetscErrorCode DMPlexComputeGradientFVM(DM dm, PetscFV fvm, Vec faceGeometry, Vec cellGeometry, DM *dmGrad)
```
Collective on dm


## Input Parameters

- ***dm  -*** The DM
- ***fvm -*** The PetscFV
- ***cellGeometry -*** The face geometry from DMPlexComputeCellGeometryFVM()



## Input/Output Parameter

- ***faceGeometry -*** The face geometry from DMPlexComputeFaceGeometryFVM(); on output
the geometric factors for gradient calculation are inserted



## Output Parameter

- ***dmGrad -*** The DM describing the layout of gradient data





## See Also
 `DMPlexGetFaceGeometryFVM()`, `DMPlexGetCellGeometryFVM()`

## Level
developer

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/impls/plex/plexgeometry.c.html#DMPlexComputeGradientFVM">src/dm/impls/plex/plexgeometry.c</A>


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


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