[petsc-dev] SNES, Coloring, DM, and TS

Dmitry Karpeev karpeev at mcs.anl.gov
Mon Feb 27 11:23:10 CST 2012


On Mon, Feb 27, 2012 at 11:11 AM, Jed Brown <jedbrown at mcs.anl.gov> wrote:

> On Mon, Feb 27, 2012 at 10:55, Dmitry Karpeev <karpeev at mcs.anl.gov> wrote:
>
>> Why is a nonlinear problem not part of the DM interface?  In my mind a DM
>> encapsulates a problem, that also knows
>> how to linearize/split/coarsen/refine itself by returning the
>> corresponding subDMs.
>>
>
> SNES depends on DM, not the other way around.
>
> In some cases, the callback needs access to the TS or SNES because it is
> doing some configuration or wants to hack in some logic. The DM callbacks
> don't pass that parameter on. If they did pass it on, that part of the
> interface could not sit in src/dm.
>

I agree that DM shouldn't depend on SNES or TS -- there is some awkwardness
of a similar kind in libMesh.
One way around this ould be to have SNESSetUp proess the (possibly changed)
DM settings before every solve.

Dmitry.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20120227/046c7bee/attachment.html>


More information about the petsc-dev mailing list