[petsc-users] preconditioning

Matthew Knepley knepley at gmail.com
Tue Apr 21 10:51:21 CDT 2015


On Tue, Apr 21, 2015 at 10:49 AM, Sanjay Kharche <
Sanjay.Kharche at manchester.ac.uk> wrote:

>
> Hi
>
> I am working through the KSP examples, but I will ask for any comments in
> the mean time.
>
> I have a TS code for 2D/3D heat equation, starting from ts/ex15. How can I
> easily modify this code to include a parallel preconditioner. As of now, I
> just need to add a preconditioner which is easy to program. The
> coefficients in my systems matrix are constant, but RHS changes at each
> iteration.
>

Use -pc_type gamg. You have the Laplacian + Identity, so this should work
fine.

  Thanks,

    Matt


> cheers
> Sanjay
>



-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20150421/ebcd9f70/attachment-0001.html>


More information about the petsc-users mailing list