Linear Solvers - SLES: Examples

The Scalable Linear Equations Solvers (SLES) component provides an easy-to-use interface to the combination of a Krylov subspace iterative method and a preconditioner (in the KSP and PC components, respectively) or a sequential direct solver. SLES users can set various Krylov and preconditioning options at runtime via the options database (e.g., -pc_type jacobi -ksp_type gmres ). SLES users can also set KSP and PC options directly in application codes by first extracting the KSP and/or PC context from the SLES context via SLESGetKSP()/ SLESGetPC() and then directly calling the KSP and PC routines (e.g., KSPSetType()/ PCSetType() ). Both KSP and PC components can be used directly to create and destroy solvers; this is not needed for users but is intended for library developers.

Beginner - Basic usage
SLES SLESGetKSP SLESSetOperators
SLESCreate SLESGetPC SLESSolve
SLESDestroy SLESSetFromOptions SLESView
Intermediate - Setting options for algorithms and data structures
SLESAppendOptionsPrefix SLESSetDiagonalScale SLESSolveTranspose
SLESGetDiagonalScale SLESSetDiagonalScaleFix
SLESGetOptionsPrefix SLESSetOptionsPrefix
Advanced - Setting more advanced options and customization
DMMGCreate DMMGSetUp SLESSetUp
DMMGDestroy DMMGSetUseGalerkinCoarse SLESSetUpOnBlocks
DMMGSetDM DMMGSolve
DMMGSetSLES DMMGView
No developer routines

Table of Contents