[petsc-users] DMMG preconditioner used in KSP
Barry Smith
bsmith at mcs.anl.gov
Tue Sep 28 21:13:07 CDT 2010
If you are using DMMGSetKSP() then just have the third argument (func) compute A+B as the first matrix and A as the second matrix. Then the smoothing and coarse grid solve will
only use the A entries. That is A+B will be preconditioned with geometric multigrid applied to A.
But, I suspect that you will do just as well using A+B.
Barry
On Sep 28, 2010, at 8:19 PM, Shao-Ching Huang wrote:
> Hi
>
> I can trying to solve a linear system
>
> (A+B)x=b
>
> where A is the standard finite difference Laplacian matrix and B has
> only a few elements (i.e. B's number of non-zero entries is much much
> smaller than A's).
> Is it possible to precondition by applying DMMG on A (like in ex34.c)
> in a KSP solver? Is there an example that I can follow to set this up?
>
> Thanks,
>
> Shao-Ching
More information about the petsc-users
mailing list