# TaoGetTotalIterationNumber
Gets the total number of Tao iterations completed. This number keeps accumulating if multiple solves are called with the Tao object. 
## Synopsis
```
#include "petsctao.h" 
PetscErrorCode TaoGetTotalIterationNumber(Tao tao, PetscInt *iter)
```
Not Collective


## Input Parameter

- ***tao -*** Tao context



## Output Parameter

- ***iter -*** iteration number



## Notes
The total iteration count is updated after each solve, if there is a current
TaoSolve() in progress then those iterations are not yet counted.




## See Also
 `TaoGetLinearSolveIterations()`

## Level
intermediate

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


---
[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)  
