KSPCG

The preconditioned conjugate gradient (PCG) iterative method

Options Database Keys

-ksp_cg_type Hermitian - (for complex matrices only) indicates the matrix is Hermitian
-ksp_cg_type symmetric - (for complex matrices only) indicates the matrix is symmetric

Notes: The PCG method requires both the matrix and preconditioner to be symmetric positive (semi) definite

See Also

KSPCreate(), KSPSetType(), KSPType (for list of available types), KSP,
KSPCGSetType()

Level:beginner
Location:
src/ksp/ksp/impls/cg/cg.c
Index of all KSP routines
Table of Contents for all manual pages
Index of all manual pages

Examples

src/ksp/pc/examples/tutorials/ex1.c.html
src/ksp/pc/examples/tutorials/ex2.c.html