SNESSetMonitor
Sets an ADDITIONAL function that is to be used at every iteration of the nonlinear solver to display the iteration's progress.
Synopsis
int SNESSetMonitor( SNES snes, int (*func)(SNES,int,double,void*),void *mctx )
Collective on
SNES
Input Parameters
| snes | - the SNES context
|
| func | - monitoring routine
|
| mctx | - [optional] user-defined context for private data for the
monitor routine (may be PETSC_NULL)
|
Calling sequence of func
int func(SNES snes,int its, Vec x,Vec f,double norm,void *mctx)
| snes | - the SNES context
|
| its | - iteration number
|
| mctx | - [optional] monitoring context
|
| norm | - 2-norm function value (may be estimated)
for SNES_NONLINEAR_EQUATIONS methods
|
| norm | - 2-norm gradient value (may be estimated)
for SNES_UNCONSTRAINED_MINIMIZATION methods
|
Options Database Keys