[petsc-users] Multigrid with defect correction

Mark Adams mfadams at lbl.gov
Wed Feb 22 22:07:44 CST 2017


On Wed, Feb 22, 2017 at 5:53 AM, Matt Landreman <matt.landreman at gmail.com>
wrote:

> Hi, PETSc developers,
>
> 1. Consider solving a linear problem with -pc_type mg, assembling the
> matrix using KSPSetComputeOperators(ksp,ComputeMatrix,&user) and
> MatSetValuesStencil as in ksp ex25.c.  I’d like Pmat to be different than
> Amat (a stable low-order discretization and a high-order discretization,
> respectively.) However the two Mat arguments that PETSc passes to
> ComputeMatrix appear to be the same object, so Pmat and Amat are forced to
> be the same.  (For example in ex25, J==jac). How do I allow Amat and Pmat
> to differ?
>

> 2. I suppose if the above issue were resolved, the resulting gmres/mg
> iteration would amount to doing defect correction on only the finest grid.
> Another defect correction method is to use a different Mat for smoothing
> and residual computation at every level. (Stable low-order for smoothing,
> high-order for residual.) This latter approach is recommended on page 103
> of Brandt’s multigrid guide (http://www.wisdom.weizmann.ac
> .il/~achi/classics.pdf). What would be the best way to do this second
> kind of defect correction in PETSc mg? Perhaps loop over every multigrid
> level and call PCMGSetResidual(pc,l,PCMGResidualDefault,Amat) on each
> level, after calling ComputeMatrix to build the appropriately-sized Amat?
>
>
I am not familiar with this KSPSetComputeOperators interface, but yes you
can loop over the levels and change operators. If you want to modify the
default algorithm then you can dive in and modify it.


> 3. Is it at all sensible to do this second kind of defect correction with
> _algebraic_ multigrid?
>

Not likely,


> Perhaps Amat for each level could be formed from the high-order matrix at
> the fine level by the Galerkin operator R A P, after getting all the
> restriction matrices created by gamg for Pmat?
>

RAP will kill the high order unless you come up with very clever AMG coarse
grid spaces. You probably want to keep all explicit matrices
stable/low-order and do high order matrix free.


>
> Thanks,
> Matt Landreman
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20170222/d031791b/attachment.html>


More information about the petsc-users mailing list