petsc-3.3-p3 2012-08-29

Krylov Methods - KSP: : Examples

The scalable linear equations solvers (KSP) 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. KSP users can set various Krylov subspace options at runtime via the options database (e.g., -ksp_type cg ). KSP users can also set KSP options directly in application by directly calling the KSP routines listed below (e.g., KSPSetType() ). KSP 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
KSP KSPGMRES KSPSetOperators
KSPBCGS KSPIBCGS KSPSolve
KSPBCGSL KSPIFBCGS KSPTCQMR
KSPBICG KSPLCD KSPTFQMR
KSPCG KSPLGMRES KSPType
KSPCGNE KSPLSQR KSPView
KSPCGS KSPMINRES KSP_CONVERGED_ATOL
KSPCGType KSPMonitorSet KSP_CONVERGED_ITERATING
KSPCHEBYSHEV KSPPGMRES KSP_CONVERGED_ITS
KSPCR KSPPREONLY KSP_CONVERGED_RTOL
KSPConvergedReason KSPRICHARDSON KSP_DIVERGED_BREAKDOWN
KSPCreate KSPReset KSP_DIVERGED_BREAKDOWN_BICG
KSPDGMRES KSPSYMMLQ KSP_DIVERGED_DTOL
KSPDestroy KSPSetComputeOperators KSP_DIVERGED_INDEFINITE_PC
KSPFBCGS KSPSetComputeRHS KSP_DIVERGED_ITS
KSPFGMRES KSPSetFromOptions KSP_DIVERGED_NONSYMMETRIC
KSPGCR KSPSetInitialGuessNonzero
Intermediate - Setting options for algorithms and data structures
KSPBCGSLSetEll KSPGMRESSetPreAllocateVectors KSPMonitorLGTrueResidualNormCreate
KSPBCGSLSetPol KSPGMRESSetRestart KSPMonitorLGTrueResidualNormDestroy
KSPBCGSLSetXRes KSPGetApplicationContext KSPMonitorRange
KSPCGSetType KSPGetConvergedReason KSPMonitorSingularValue
KSPCGUseSingleReduction KSPGetDM KSPMonitorSolution
KSPChebyshevSetEigenvalues KSPGetDiagonalScale KSPMonitorTrueResidualNorm
KSPChebyshevSetEstimateEigenvalues KSPGetDiagonalScaleFix KSPPythonSetType
KSPDefaultConverged KSPGetErrorIfNotConverged KSPRichardsonSetScale
KSPDefaultConvergedCreate KSPGetInitialGuessNonzero KSPRichardsonSetSelfScale
KSPDefaultConvergedDestroy KSPGetIterationNumber KSPSPECEST
KSPDefaultConvergedSetUIRNorm KSPGetMonitorContext KSPSetApplicationContext
KSPDefaultConvergedSetUMIRNorm KSPGetOperators KSPSetDM
KSPFGMRESModifyPCKSP KSPGetOperatorsSet KSPSetDMActive
KSPFGMRESModifyPCNoChange KSPGetPCSide KSPSetDiagonalScale
KSPFGMRESSetModifyPC KSPGetResidualNorm KSPSetDiagonalScaleFix
KSPGCRSetModifyPC KSPGetTolerances KSPSetErrorIfNotConverged
KSPGMRESClassicalGramSchmidtOrthogonalization KSPGetType KSPSetPCSide
KSPGMRESGetCGSRefinementType KSPLSQRDefaultConverged KSPSetTolerances
KSPGMRESGetOrthogonalization KSPLSQRMonitorDefault KSPSetType
KSPGMRESGetRestart KSPMonitorCancel MatCreateSchurComplement
KSPGMRESModifiedGramSchmidtOrthogonalization KSPMonitorDefault MatSchurComplementGetKSP
KSPGMRESMonitorKrylov KSPMonitorLGCreate MatSchurComplementGetSubmatrices
KSPGMRESSetCGSRefinementType KSPMonitorLGDestroy MatSchurComplementUpdate
KSPGMRESSetHapTol KSPMonitorLGRangeCreate
KSPGMRESSetOrthogonalization KSPMonitorLGRangeDestroy
Advanced - Setting more advanced options and customization
DMKSPGetComputeOperators KSPGetNormType KSPSetComputeSingularValues
DMKSPGetComputeRHS KSPGetNullSpace KSPSetConvergenceTest
DMKSPSetComputeOperators KSPGetOptionsPrefix KSPSetFischerGuess
DMKSPSetComputeRHS KSPGetResidualHistory KSPSetInitialGuessKnoll
KSPAppendOptionsPrefix KSPGetVecs KSPSetLagNorm
KSPBuildResidual KSPMonitorAMS KSPSetNormType
KSPBuildSolution KSPNASHGetNormD KSPSetNullSpace
KSPComputeEigenvalues KSPNASHGetObjFcn KSPSetOptionsPrefix
KSPComputeEigenvaluesExplicitly KSPNASHSetRadius KSPSetResidualHistory
KSPComputeExplicitOperator KSPNormType KSPSetUpOnBlocks
KSPComputeExtremeSingularValues KSPQCGGetQuadratic KSPSetUseFischerGuess
KSPFischerGuessCreate KSPQCGGetTrialStepNorm KSPSkipConverged
KSPGLTRGetLambda KSPQCGSetTrustRegionRadius KSPUnwindPreconditioner
KSPGLTRGetMinEig KSPRegister KSP_GMRES_CGS_REFINE_IFNEEDED
KSPGLTRGetNormD KSPRegisterAll KSP_GMRES_CGS_REFINE_NEVER
KSPGLTRGetObjFcn KSPRegisterDestroy KSP_NORM_NATURAL
KSPGLTRSetRadius KSPRegisterDynamic KSP_NORM_NONE
KSPGMRESCGSRefinementType KSPSTCGGetNormD KSP_NORM_PRECONDITIONED
KSPGetComputeEigenvalues KSPSTCGGetObjFcn KSP_NORM_UNPRECONDITIONED
KSPGetComputeSingularValues KSPSTCGSetRadius MatGetSchurComplement
KSPGetConvergenceContext KSPSetCheckNormIteration
KSPGetInitialGuessKnoll KSPSetComputeEigenvalues
Developer - Interfaces intended primarily for library developers, not for typical applications programmers
DMKSPCopyContext KSPGetRhs KSPQCG
DMKSPGetContext KSPGetSolution KSPSTCG
DMKSPGetContextWrite KSPInitialResidual KSPSetPC
KSPChebyshevSetNewMatrix KSPInitializePackage KSPSetSupportedNorm
KSPFinalizePackage KSPMonitor KSPSetUp
KSPGLTR KSPMonitorAMSCreate KSPSolveTranspose
KSPGetFischerGuess KSPMonitorAMSDestroy PCFinalizePackage
KSPGetPC KSPNASH PCInitializePackage
No deprecated routines

Table of Contents