[petsc-users] example on manually setup matrix coloring for finite difference Jacobian?
Matthew Knepley
knepley at gmail.com
Wed Jul 17 18:17:13 CDT 2013
On Wed, Jul 17, 2013 at 6:15 PM, Zou (Non-US), Ling <ling.zou at inl.gov>wrote:
> (meant to send to the list)
>
> Thanks Matt for you reply.
>
> In my case, 2-d problem with unstructured mesh, what would be a
> practical way to move forward?
> 1, using fully analytical Jacobian, it however will be very difficult
> to make everything right eventually
>
This is, of course, preferable is preconditioning is difficult.
> 2, using finite differencing Jacobian, but use keyword
> SNESDefaultComputeJacobian, which is very slow
>
This is not really practical for anything but toy problems.
> 3, using matrix free operation to avoid the Jacobian calculation
>
What I was suggesting is that you use MF FD action for the action of the
Jacobian,
which is generally an accurate operation, and then assemble a simplified
operator
to use for constructing the preconditioner.
Matt
> Any suggestion?
>
> On Wed, Jul 17, 2013 at 5:06 PM, Matthew Knepley <knepley at gmail.com>
> wrote:
> > On Wed, Jul 17, 2013 at 6:02 PM, Zou (Non-US), Ling <ling.zou at inl.gov>
> > wrote:
> >>
> >> Hi All,
> >>
> >> If I have a 2-d problem with unstructured triangle mesh, I suppose I
> >> need handle the coloring manually in case I need the finite
> >> differencing Jacobian. Also I guess it is doable as I know the mesh
> >> connectivity. I noticed there are several examples handling structured
> >> mesh case. Is there any example to setup the matrix coloring for this
> >> kind of case?
> >
> >
> > We have no examples of this, and have not pushed it in our development. I
> > would also consider forming a simplified operator for preconditioning
> while
> > using the finite difference approximation for the action.
> >
> > Matt
> >
> >>
> >> Best,
> >>
> >> Ling
> >
> >
> >
> >
> > --
> > 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
>
--
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/20130717/bf7adf78/attachment.html>
More information about the petsc-users
mailing list