[petsc-users] multigrid questions
Jed Brown
jed at jedbrown.org
Wed Feb 15 12:18:32 CST 2017
Matt Landreman <matt.landreman at gmail.com> writes:
> Hi, Petsc developers,
>
> A few basic questions about geometric and algebraic multigrid in petsc:
>
> Based on the output of -ksp_view, I see that for both -pc_type mg and
> -pc_type gamg, the smoothing on each multigrid level is implemented using a
> ksp with default type chebyshev, associated with a pc of default type sor.
> I also see in section 4.4.5 of the petsc manual that switching to
> -mg_levels_ksp_type richardson is sometimes recommended, and I see in the
> ksp examples makefile that ksp ex28.c uses -mg_levels_ksp_type gmres.
>
> 1. Does “textbook” Gauss-Seidel smoothing correspond in petsc to
> -mg_levels_ksp_type richardson?
Yeah, default Richardson/SOR is plain GS.
> 2. It says in
> http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/KSP/KSPCHEBYSHEV.html
> that PETSc’s chebyshev iteration only works for symmetric matrices. So to
> confirm, for any problem with non-symmetric matrices such as
> convection-diffusion, setting -mg_levels_ksp_type to some non-default value
> like richardson or gmres is *mandatory* then? (If so, it would be helpful
> if this were stated in the manual.)
A lot of nonsymmetric problems are "not too non-symmetric".
Chebyshev(1) is actually just Richardson. High-degree Chebyshev has a
tighter smoothing profile on the real axis so problems with eigenvalues
far from the real axis can be unstable. The defaults were chosen
because they tend to be robust on a variety of problems.
> 3. For smoothing with geometric multigrid, is there a way in petsc to do
> red-black Gauss Seidel? Line relaxation?
Multi-color GS would need a coloring which is difficult in parallel and
the performance tends to be poor when there are many colors. Block
Jacobi/ILU smoothers often behave similarly to line smoothers (depends
on ordering). Usually people write custom code for
discretization-dependent smoothers.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 832 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20170215/7e0f00e7/attachment.pgp>
More information about the petsc-users
mailing list