[petsc-users] PCFieldSplit additive and multiplicative operations

Jed Brown jed at jedbrown.org
Fri Jun 28 16:09:49 CDT 2019


Justin Chang via petsc-users <petsc-users at mcs.anl.gov> writes:

> Hi all,
>
> Suppose I have a 2x2 block system of equations that I want to solve using
> gmres + field split:
>
> (A00 A01) (u0) = (b0)
> (A10 A11) (u1) = (b1)
>
> Based on what I understand from the PCApply_FieldSplit(pc,x,y) source code
> <https://bitbucket.org/petsc/petsc/src/3b49ee3ec70d6dde98134df8f402aa75075296ac/src/ksp/pc/impls/fieldsplit/fieldsplit.c#lines-1194>,
> the Block Jacobi (aka pc_fieldsplit_type additive) implementation performs
> the following operations:
>
> y0 = inv(A00)*x0
> y1 = inv(A11)*x1
>
> and for the Block Gauss Seidel (aka pc_fieldsplit_type multiplicative)
>
> y0 = inv(A00)*x0
> y1 = inv(A11)*(x1 - A10*y0)
>
> But based on my understanding of the Jacobi
> <https://en.wikipedia.org/wiki/Jacobi_method> and Gauss-Seidel
> <https://en.wikipedia.org/wiki/Gauss–Seidel_method> methods, shouldn't the
> above sets of operations be more like:
>
> y0 = inv(A00)*(x0 - A01*y1_0)
> y1 = inv(A11)*(x1 - A10*y0_0)
>
> and
>
> y0 = inv(A00)*(x0 - A01*y1_0)
> y1 = inv(A11)*(x1 - A10*y0)
>
> where y0_0 and y1_0 denote the initial/previous values of y0 and y1,
> respectively? Or does it not matter as much because x0 and x1 don't exactly
> correspond to u0 and u1, respectively, but instead correspond to either b -
> A*u or A*vec_vv depending on the stage you're in inside the gmres solver?

When applying a preconditioner, the "initial guess" of the correction is
zero.  The stationary iterations above are basically using KSPRichardson
with the stated preconditioner.  In such cases, you can do it more
efficiently using PCApplyRichardson(), which is used automatically when
available.


More information about the petsc-users mailing list