[petsc-users] How to get total subsnes iterations

Takahashi, Tadanaga tt73 at njit.edu
Wed Oct 12 10:03:27 CDT 2022


Hi. I am using the snes nasm for the global solver and snes newtonls for
the local subdomain solver. I am trying to get the total number of Newton
iterations for just one subdomain. I've tried:

SNESNASMGetSNES(snes,0,&subsnes);
SNESSolve(snes,NULL,u_initial);
SNESGetNumberFunctionEvals(subsnes,&Newt_its);

but this just gets me the number of Newton iterations just on the final
nasm iteration. If I understand correctly, the information in the subsnes
is repeatedly destroyed while the SNESSolve is running. Is there any way to
extract the total subsnes iterations after the SNESSolve? If not, how would
I extract the information?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20221012/b6938750/attachment.html>


More information about the petsc-users mailing list