:orphan:
# TaoSetOptionsPrefix
Sets the prefix used for searching for all Tao options in the database.
## Synopsis
```
#include "petsctao.h"
PetscErrorCode TaoSetOptionsPrefix(Tao tao, const char p[])
```
Logically Collective
## Input Parameters
- ***tao -*** the `Tao` context
- ***prefix -*** the prefix string to prepend to all Tao option requests
## Notes
A hyphen (-) must NOT be given at the beginning of the prefix name.
The first character of all runtime options is AUTOMATICALLY the hyphen.
For example, to distinguish between the runtime options for two
different Tao solvers, one could call
```none
TaoSetOptionsPrefix(tao1,"sys1_")
TaoSetOptionsPrefix(tao2,"sys2_")
```
This would enable use of different options for each system, such as
```none
-sys1_tao_method blmvm -sys1_tao_grtol 1.e-3
-sys2_tao_method lmvm -sys2_tao_grtol 1.e-4
```
## See Also
[](ch_tao), `Tao`, `TaoSetFromOptions()`, `TaoAppendOptionsPrefix()`, `TaoGetOptionsPrefix()`
## Level
advanced
## Location
src/tao/interface/taosolver.c
## Examples
src/tao/tutorials/ex4.c
---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/tao/interface/taosolver.c)
[Index of all Tao routines](index.md)
[Table of Contents for all manual pages](/manualpages/index.md)
[Index of all manual pages](/manualpages/singleindex.md)