:orphan:
# DMPlexTSComputeRHSFunctionFEM
Form the local residual `locG` from the local input `locX` using pointwise functions specified by the user 
## Synopsis
```
#include "petscdmplex.h" 
#include "petscts.h" 
PetscErrorCode DMPlexTSComputeRHSFunctionFEM(DM dm, PetscReal time, Vec locX, Vec locG, void *user)
```

## Input Parameters

- ***dm -*** The mesh
- ***t -*** The time
- ***locX  -*** Local solution
- ***user -*** The user context



## Output Parameter

- ***locG  -*** Local output vector





## See Also
 [](ch_ts), `TS`, `DM`, `DMPlexTSComputeIFunctionFEM()`, `DMPlexTSComputeIJacobianFEM()`

## Level
developer

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ts/utils/dmplexts.c.html#DMPlexTSComputeRHSFunctionFEM">src/ts/utils/dmplexts.c</A>

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


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/ts/utils/dmplexts.c)


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