Nonlinear Solution of Equations

Additional SNES example programs are available at ${PETSC_DIR}/src/snes/examples/tutorials

Programs: ~/petsc_examples/snes/ex5.c
or ~/petsc_examples/snes/ex5f.F and ex5f.h
or ~/petsc_examples/snes/ex5f90.F
Runtime commands:
% mpiexec -np 3 ex5 -snes_monitor -snes_view
or
% mpiexec -np 3 ex5f -snes_monitor -snes_view
or
% mpiexec -np 3 ex5f90 -snes_monitor -snes_view
where
-snes_monitor : print residual norm at each iteration
-snes_view : print information about the particular
nonlinear solvers used at runtime
Comments:
By default a Netwon line search method is used.