[petsc-users] Examples on solving linear systems using GMRES and/or matrix-free method
Matthew Knepley
knepley at gmail.com
Wed Jun 8 06:38:34 CDT 2011
On Tue, Jun 7, 2011 at 10:20 PM, Xiang Hao <haoxiang at yahoo.cn> wrote:
> Hi all,
>
> I need to solve a PDE ( basically a Poisson's equation with Neumann
> boundary condition ), and I solved it using a steepest descent method, which
> is very slow. Now I want to solve the PDE using GMRES. In addition, I do
> have the matrix A, but I have a function which computes Ax, so I also need
> to use the matrix free method.
>
> I am very new to PETSc, so I am looking for examples on solving linear
> systems using GMRES and/or matrix-free method.
>
You can look at SNES ex5 for the Poisson equation (after setting lambda =
0.0). SNES ex19 also shows how to use geometric Multigrid.
Its not hard to do this for Poisson.
Thanks,
Matt
> Thanks,
> Xiang
>
>
>
--
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/20110608/1fdf5836/attachment.htm>
More information about the petsc-users
mailing list