# PetscLimiterRegister
Adds a new `PetscLimiter` implementation 
## Synopsis
```
#include "petscfv.h" 
PetscErrorCode PetscLimiterRegister(const char sname[], PetscErrorCode (*function)(PetscLimiter))
```
Not Collective


## Input Parameters

- ***name        -*** The name of a new user-defined creation routine
- ***create_func -*** The creation routine itself



## Sample usage
```none
    PetscLimiterRegister("my_lim", MyPetscLimiterCreate);
```


Then, your `PetscLimiter` type can be chosen with the procedural interface via
```none
    PetscLimiterCreate(MPI_Comm, PetscLimiter *);
    PetscLimiterSetType(PetscLimiter, "my_lim");
```

or at runtime via the option
```none
    -petsclimiter_type my_lim
```





## Note
`PetscLimiterRegister()` may be called multiple times to add several user-defined PetscLimiters


## See Also
 `PetscLimiter`, `PetscLimiterType`, `PetscLimiterRegisterAll()`, `PetscLimiterRegisterDestroy()`

## Level
advanced

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/dt/fv/interface/fv.c.html#PetscLimiterRegister">src/dm/dt/fv/interface/fv.c</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/dm/dt/fv/interface/fv.c)


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