[petsc-users] Equivalent of DMGetRefineLevel and DMGetCoarsenLevel for FAS

zakaryah zakaryah at gmail.com
Tue Jul 10 16:10:42 CDT 2018


I'm trying to incorporate auxiliary fields (in a DMDA) in a problem in
nonlinear elasticity, in a way which is compatible with multi-grid
techniques.  The advice I got previously was to use DMCoarsenHookAdd and
DMRefineHookAdd.  I finally managed to make sense of the example that Jed
pointed out (SNES ex48.c), which was helpful.  However, I thought that
since the same coarsening and refinement would be used repeatedly, I could
just keep everything around at all times, like example KSP ex42.c, using
DMRefineHierarchy.  I managed to get that working with grid sequencing.
However, I can't seem to generalize to FAS, because in my FormFunction
routine, I need to be able to determine which of the auxiliary DMs from the
hierarchy corresponds to the current scale.  With grid sequencing, I could
use DMGetRefineLevel.  Is it possible to do something similar with FAS?  Is
it completely stupid to try to do it this way?  Thanks for any help.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20180710/9f5489dc/attachment-0001.html>


More information about the petsc-users mailing list