petsc-3.3-p7 2013-05-11


Applies several steps of Richardson iteration with the particular preconditioner. This routine is usually used by the Krylov solvers and not the application code directly.


#include "petscksp.h" 
PetscErrorCode  PCApplyRichardson(PC pc,Vec b,Vec y,Vec w,PetscReal rtol,PetscReal abstol, PetscReal dtol,PetscInt its,PetscBool  guesszero,PetscInt *outits,PCRichardsonConvergedReason *reason)
Collective on PC

Input Parameters

pc - the preconditioner context
b - the right hand side
w - one work vector
rtol - relative decrease in residual norm convergence criteria
abstol - absolute residual norm convergence criteria
dtol - divergence residual norm increase criteria
its - the number of iterations to apply.
guesszero - if the input x contains nonzero initial guess

Output Parameter

outits - number of iterations actually used (for SOR this always equals its)
reason - the reason the apply terminated
y - the solution (also contains initial guess if guesszero is PETSC_FALSE


Most preconditioners do not support this function. Use the command PCApplyRichardsonExists() to determine if one does.

Except for the multigrid PC this routine ignores the convergence tolerances and always runs for the number of iterations


PC, apply, Richardson

See Also


Index of all PC routines
Table of Contents for all manual pages
Index of all manual pages