[petsc-users] Rigid body nullspace for Stokes operator

Mark Adams mfadams at lbl.gov
Tue Oct 29 08:28:32 CDT 2024


This coordinate interface is just a shortcut for vertex based
discretizations with 3 dof per vertex, etc. (maybe works in 2D).
You will need to construct the null space vectors manually and attach it to
the matrix. Used by GAMG.

Note, for hypre you want to use the "nodal" options and it does not use
these null space vectors. That is probably the way you want to go.
eg: -pc_hypre_boomeramg_nodal_coarsen

I would run with hypre boomerang and -help and grep on nodal to see all the
"nodal" options and use them.

Thanks,
Mark


On Mon, Oct 28, 2024 at 8:06 PM Amneet Bhalla <mail2amneet at gmail.com> wrote:

> Hi Folks,
>
> I am trying to solve the momentum equation in a projection preconditioner
> using GAMG or Hypre solver. The equation looks like for velocity variable
> *v* looks like:
>
>
>  [image: Screenshot 2024-10-28 at 4.15.17 PM.png]
>
> Here, μ is spatially varying dynamic viscosity and λ is spatially varying
> bulk viscosity. I understand that I need to specify rigid body nullspace
> modes to the multigrid solver in order to accelerate its convergence.
> Looking into this routine MatNullSpaceCreateRigidBody() (
> https://urldefense.us/v3/__https://petsc.org/release/manualpages/Mat/MatNullSpaceCreateRigidBody/__;!!G_uCfscf7eWS!dV9NK_u6h8vxc8z14I3rAhKas06pBwOaFzCouvxeqW6uBZzjyiAz-uZwk8AQFRvQM8s_OIv76NJ6eA7dXf6NylY$ 
> <https://urldefense.us/v3/__https://petsc.org/release/manualpages/Mat/MatNullSpaceCreateRigidBody/__;!!G_uCfscf7eWS!eKqgIJjCdMzIU76f7X65AmGxrU_-lC7W02BMWafJ77DNf_IuQk6O1X3qU1x9Ez8NJ20vZEL-mF6T1yNmDnwv0eWa2w$>),
> I see that I need to provide the coordinates of each node. I am using
> staggered grid discretization. Do I need to provide coordinates of
> staggered grid locations?
>
> Thanks,
> --
> --Amneet
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20241029/689792f2/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Screenshot 2024-10-28 at 4.15.17 PM.png
Type: image/png
Size: 17171 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20241029/689792f2/attachment-0001.png>


More information about the petsc-users mailing list