[petsc-users] Problems with the null-space removal

Matthew Knepley knepley at gmail.com
Mon May 5 14:43:39 CDT 2025


On Mon, May 5, 2025 at 2:08 PM MIGUEL MOLINOS PEREZ <mmolinos at us.es> wrote:

> Hi Matt, thank you for your response!
>
> The most likely thing is that the nullspace is slightly wrong, or the
> convergence test is not accounting for the nullspace somehow.
>
> However, since so many equations are inactive, I would consider projecting
> the problem. I might either
>
> 1) Select a subset of the mesh to phrase the problem on. In you use
> DMPlex, you could use DMPlexFilter().
>
>
> I’am using a DMSwarm mesh so I can’t use this function.
>

Oh, so you want to turn off some Swarm nodes? Joe has a
DMSwarmCreatreSubswarm() function somewhere. This might work.


> 2) Use a constraint to get a subsystem for Newton using SNESVI. The
> SNESVIRS will project the linear system onto a subspace without the
> constraints.
>
>
> I assume you meant *SNESVINEWTONRSLS (former SNESVI)*.
>

This is a subtype of SNESVI as it is a particular implementation.


> I’ve been digging on this approach. However,I don’t think this fits my
> problem since I can not define the list of active nodes using upper and
> lower limits like in:
>

The way I am thinking, you must have some test to determine what nodes are
active. I was supposing that test depending on the solution at those nodes.
If that is true, you can use that test as the constraint.

  Thanks,

     Matt


>
> petsc.org <https://urldefense.us/v3/__https://petsc.org/release/src/snes/tutorials/ex9.c.html__;!!G_uCfscf7eWS!ezvVIFtMgyEOMIRv8YEwgp7LXjHr2RxGixxJ5mO6iKk1tUEbvE5XyAUc3DcQzPkbbby5AcQBnFG79U9jYfcL$ >
> <https://urldefense.us/v3/__https://petsc.org/release/src/snes/tutorials/ex9.c.html__;!!G_uCfscf7eWS!ezvVIFtMgyEOMIRv8YEwgp7LXjHr2RxGixxJ5mO6iKk1tUEbvE5XyAUc3DcQzPkbbby5AcQBnFG79U9jYfcL$ >
> <https://urldefense.us/v3/__https://petsc.org/release/src/snes/tutorials/ex9.c.html__;!!G_uCfscf7eWS!ezvVIFtMgyEOMIRv8YEwgp7LXjHr2RxGixxJ5mO6iKk1tUEbvE5XyAUc3DcQzPkbbby5AcQBnFG79U9jYfcL$ >
>
>
> Thanks,
> Miguel
>
>

-- 
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

https://urldefense.us/v3/__https://www.cse.buffalo.edu/*knepley/__;fg!!G_uCfscf7eWS!ezvVIFtMgyEOMIRv8YEwgp7LXjHr2RxGixxJ5mO6iKk1tUEbvE5XyAUc3DcQzPkbbby5AcQBnFG79ZOkRSWY$  <https://urldefense.us/v3/__http://www.cse.buffalo.edu/*knepley/__;fg!!G_uCfscf7eWS!ezvVIFtMgyEOMIRv8YEwgp7LXjHr2RxGixxJ5mO6iKk1tUEbvE5XyAUc3DcQzPkbbby5AcQBnFG79YI3nCj0$ >
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20250505/ce80aa68/attachment-0001.html>


More information about the petsc-users mailing list