[petsc-dev] can we get rid of SNESCreate_Test() now?
Jed Brown
jedbrown at mcs.anl.gov
Thu Mar 7 09:00:39 CST 2013
On Thu, Mar 7, 2013 at 8:44 AM, Barry Smith <bsmith at mcs.anl.gov> wrote:
> And merged with the SNESUpdateCheckJacobian() which is not as
> extensive as the "compare" test but far better designed and much prettier
> code :-) Also could all that code be pulled out of SNESComputeJacobian()
> and put in a separate private routine called by SNESComputeJacobian()?
>
I see snes->ops->update in all the solvers, including those that do not
compute Jacobians. Can those calls be moved inside SNESComputeJacobian()?
If SNESUpdateCheckJacobian continues to be called before computing the
Jacobian, then it should finish by re-evaluating the residual at the
original point. Why? Because we allow people to cache part of the Jacobian
internally and (especially for non-smooth problems) we need to ask the user
for the Jacobian at exactly the same place we evaluated the residual.
Do we need this SNESSetUpdate() system for anything else?
> I object to -snes_compare because it sounds like you are comparing
> SNESes, which you are not. Maybe -snes_jacobian_compare ?
>
I'm happy to use -snes_jacobian_check (or -snes_check_jacobian, depending
on our endianness).
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20130307/0281ab73/attachment.html>
More information about the petsc-dev
mailing list