slepc-3.18.2 2023-01-26
Report Typos and Errors

# MFNGetIterationNumber

Gets the current iteration number. If the call to MFNSolve() is complete, then it returns the number of iterations carried out by the solution method.

### Synopsis

    #include "slepcmfn.h"
    PetscErrorCode MFNGetIterationNumber(MFN mfn,PetscInt *its)

Not Collective

### Input Parameter

| mfn | - the matrix function context

### Output Parameter

| its | - number of iterations

### Note

During the i-th iteration this call returns i-1. If MFNSolve() is complete, then parameter "its" contains either the iteration number at which convergence was successfully reached, or failure was detected. Call MFNGetConvergedReason() to determine if the solver converged or failed and why.

### See Also

MFNGetConvergedReason(), MFNSetTolerances()

### Level

intermediate

### Location

src/mfn/interface/mfnsolve.c

### Examples

src/mfn/tutorials/ex23.c.html
src/mfn/tutorials/ex23f90.F90.html
src/mfn/tutorials/ex37.c.html
Index of all MFN routines
Table of Contents for all manual pages
Index of all manual pages