[petsc-users] Fail function evaluation with SNES
Merson, Jacob Simon
mersoj2 at rpi.edu
Mon Jun 27 00:20:37 CDT 2022
Hi All,
I’m attempting to use the SNES solver with the finite element method. When I use the trust region or line search algorithms I’m not currently running into any problems and the solution matches a hand-coded newton solver. However, when I use other methods like quasi-newton, or newton-conjugate-graduent I end up with a guess that makes the element Jacobian negative causing issues with the residual (and Jacobian) evaluation.
For this circumstance is it possible to set an error code that specifies that the function evaluation has failed and have SNES try a different step?
Thanks for the help!
Jacob
More information about the petsc-users
mailing list