petsc-3.5.4 2015-05-23
Nonlinear solvers - SNES: Examples
The Scalable Nonlinear Equations Solvers (SNES) component provides an
easy-to-use interface to Newton-type, quasi-Newton, full approximation scheme (FAS) multigrid, and other methods for solving systems of
nonlinear equations. SNES users can set various algorithmic options
at runtime via the options database (e.g., specifying a trust region
method via
-snes_type tr
).
SNES internally employs KSP for the solution of
its linear systems.
SNES users can also set KSP options directly in application
codes by first extracting the KSP context from the SNES context via
SNESGetKSP()
and then directly calling various KSP (and PC) routines (e.g.,
PCSetType()
).
ex1.c: Solves the nonlinear system, the Bratu (SFI - solid fuel ignition) problem in a 2D rectangular domain
ex5.c: Solves the modified Bratu problem in a 2D rectangular domain,\n\
ex7.c: Solves u`` + u^{2} = f with Newton-like methods
ex8.c: Parallel version of the minimum surface area problem using DMs
ex15.c:
ex16.c:
ex17.c: Newton's method to solve a two-variable system, sequentially
ex68.c: Test problems for Schur complement solvers
makefile