# TaoCreate
Creates a Tao solver 
## Synopsis
```
#include "petsctao.h" 
PetscErrorCode TaoCreate(MPI_Comm comm, Tao *newtao)
```
Collective


## Input Parameter

- ***comm -*** MPI communicator



## Output Parameter

- ***newtao -*** the new Tao context



## Available methods include

- ***`TAONLS` -*** nls Newton's method with line search for unconstrained minimization
- ***`TAONTR` -*** ntr Newton's method with trust region for unconstrained minimization
- ***`TAONTL` -*** ntl Newton's method with trust region, line search for unconstrained minimization
- ***`TAOLMVM` -*** lmvm Limited memory variable metric method for unconstrained minimization
- ***`TAOCG` -*** cg Nonlinear conjugate gradient method for unconstrained minimization
- ***`TAONM` -*** nm Nelder-Mead algorithm for derivate-free unconstrained minimization
- ***`TAOTRON` -*** tron Newton Trust Region method for bound constrained minimization
- ***`TAOGPCG` -*** gpcg Newton Trust Region method for quadratic bound constrained minimization
- ***`TAOBLMVM` -*** blmvm Limited memory variable metric method for bound constrained minimization
- ***`TAOLCL` -*** lcl Linearly constrained Lagrangian method for pde-constrained minimization
- ***`TAOPOUNDERS` -*** pounders Model-based algorithm for nonlinear least squares



## Options Database Keys

- ***-tao_type -*** select which method Tao should use





## See Also
 `Tao`, `TaoSolve()`, `TaoDestroy()`, `TAOSetFromOptions()`, `TAOSetType()`

## Level
beginner

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/interface/taosolver.c.html#TaoCreate">src/tao/interface/taosolver.c</A>

## Examples
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ts/tutorials/ex20opt_ic.c.html">src/ts/tutorials/ex20opt_ic.c.html</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ts/tutorials/ex20opt_p.c.html">src/ts/tutorials/ex20opt_p.c.html</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/tutorials/burgers_spectral.c.html">src/tao/unconstrained/tutorials/burgers_spectral.c.html</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/tutorials/eptorsion1.c.html">src/tao/unconstrained/tutorials/eptorsion1.c.html</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/tutorials/eptorsion2.c.html">src/tao/unconstrained/tutorials/eptorsion2.c.html</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/tutorials/eptorsion2f.F90.html">src/tao/unconstrained/tutorials/eptorsion2f.F90.html</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/tutorials/eptorsion3.c.html">src/tao/unconstrained/tutorials/eptorsion3.c.html</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/tutorials/minsurf1.c.html">src/tao/unconstrained/tutorials/minsurf1.c.html</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/tutorials/minsurf2.c.html">src/tao/unconstrained/tutorials/minsurf2.c.html</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/tutorials/rosenbrock1.c.html">src/tao/unconstrained/tutorials/rosenbrock1.c.html</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/tutorials/rosenbrock1f.F90.html">src/tao/unconstrained/tutorials/rosenbrock1f.F90.html</A><BR>

## Implementations

<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/bound/impls/blmvm/blmvm.c.html#TaoCreate_BLMVM">TaoCreate_BLMVM in src/tao/bound/impls/blmvm/blmvm.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/bound/impls/bncg/bncg.c.html#TaoCreate_BNCG">TaoCreate_BNCG in src/tao/bound/impls/bncg/bncg.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/bound/impls/bnk/bnk.c.html#TaoCreate_BNK">TaoCreate_BNK in src/tao/bound/impls/bnk/bnk.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/bound/impls/bnk/bnls.c.html#TaoCreate_BNLS">TaoCreate_BNLS in src/tao/bound/impls/bnk/bnls.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/bound/impls/bnk/bntl.c.html#TaoCreate_BNTL">TaoCreate_BNTL in src/tao/bound/impls/bnk/bntl.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/bound/impls/bnk/bntr.c.html#TaoCreate_BNTR">TaoCreate_BNTR in src/tao/bound/impls/bnk/bntr.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/bound/impls/bqnk/bqnk.c.html#TaoCreate_BQNK">TaoCreate_BQNK in src/tao/bound/impls/bqnk/bqnk.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/bound/impls/bqnk/bqnkls.c.html#TaoCreate_BQNKLS">TaoCreate_BQNKLS in src/tao/bound/impls/bqnk/bqnkls.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/bound/impls/bqnk/bqnktl.c.html#TaoCreate_BQNKTL">TaoCreate_BQNKTL in src/tao/bound/impls/bqnk/bqnktl.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/bound/impls/bqnk/bqnktr.c.html#TaoCreate_BQNKTR">TaoCreate_BQNKTR in src/tao/bound/impls/bqnk/bqnktr.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/bound/impls/bqnls/bqnls.c.html#TaoCreate_BQNLS">TaoCreate_BQNLS in src/tao/bound/impls/bqnls/bqnls.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/bound/impls/tron/tron.c.html#TaoCreate_TRON">TaoCreate_TRON in src/tao/bound/impls/tron/tron.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/complementarity/impls/asls/asfls.c.html#TaoCreate_ASFLS">TaoCreate_ASFLS in src/tao/complementarity/impls/asls/asfls.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/complementarity/impls/asls/asils.c.html#TaoCreate_ASILS">TaoCreate_ASILS in src/tao/complementarity/impls/asls/asils.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/complementarity/impls/ssls/ssfls.c.html#TaoCreate_SSFLS">TaoCreate_SSFLS in src/tao/complementarity/impls/ssls/ssfls.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/complementarity/impls/ssls/ssils.c.html#TaoCreate_SSILS">TaoCreate_SSILS in src/tao/complementarity/impls/ssls/ssils.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/constrained/impls/admm/admm.c.html#TaoCreate_ADMM">TaoCreate_ADMM in src/tao/constrained/impls/admm/admm.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/constrained/impls/almm/almm.c.html#TaoCreate_ALMM">TaoCreate_ALMM in src/tao/constrained/impls/almm/almm.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/constrained/impls/ipm/ipm.c.html#TaoCreate_IPM">TaoCreate_IPM in src/tao/constrained/impls/ipm/ipm.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/constrained/impls/ipm/pdipm.c.html#TaoCreate_PDIPM">TaoCreate_PDIPM in src/tao/constrained/impls/ipm/pdipm.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/leastsquares/impls/brgn/brgn.c.html#TaoCreate_BRGN">TaoCreate_BRGN in src/tao/leastsquares/impls/brgn/brgn.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/leastsquares/impls/pounders/pounders.c.html#TaoCreate_POUNDERS">TaoCreate_POUNDERS in src/tao/leastsquares/impls/pounders/pounders.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/pde_constrained/impls/lcl/lcl.c.html#TaoCreate_LCL">TaoCreate_LCL in src/tao/pde_constrained/impls/lcl/lcl.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/quadratic/impls/bqpip/bqpip.c.html#TaoCreate_BQPIP">TaoCreate_BQPIP in src/tao/quadratic/impls/bqpip/bqpip.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/quadratic/impls/gpcg/gpcg.c.html#TaoCreate_GPCG">TaoCreate_GPCG in src/tao/quadratic/impls/gpcg/gpcg.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/impls/bmrm/bmrm.c.html#TaoCreate_BMRM">TaoCreate_BMRM in src/tao/unconstrained/impls/bmrm/bmrm.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/impls/cg/taocg.c.html#TaoCreate_CG">TaoCreate_CG in src/tao/unconstrained/impls/cg/taocg.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/impls/lmvm/lmvm.c.html#TaoCreate_LMVM">TaoCreate_LMVM in src/tao/unconstrained/impls/lmvm/lmvm.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/impls/neldermead/neldermead.c.html#TaoCreate_NM">TaoCreate_NM in src/tao/unconstrained/impls/neldermead/neldermead.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/impls/nls/nls.c.html#TaoCreate_NLS">TaoCreate_NLS in src/tao/unconstrained/impls/nls/nls.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/impls/ntl/ntl.c.html#TaoCreate_NTL">TaoCreate_NTL in src/tao/unconstrained/impls/ntl/ntl.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/impls/ntr/ntr.c.html#TaoCreate_NTR">TaoCreate_NTR in src/tao/unconstrained/impls/ntr/ntr.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/impls/owlqn/owlqn.c.html#TaoCreate_OWLQN">TaoCreate_OWLQN in src/tao/unconstrained/impls/owlqn/owlqn.c</A><BR>


---
[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](/docs/manualpages/index.md)  
[Index of all manual pages](/docs/manualpages/singleindex.md)  
