[petsc-users] matrix-free snes with frozen preconditioner
Praveen C
cpraveen at gmail.com
Tue Sep 26 07:59:20 CDT 2017
Thank you. I had to do this
ierr = SNESSetLagJacobian(snes,-2); CHKERRQ(ierr);
ierr = SNESSetLagPreconditioner(snes,-2); CHKERRQ(ierr);
Now I see that my FormJacobian function is called only once. Is this
correct way to use it ?
Best
praveen
On Tue, Sep 26, 2017 at 6:00 PM, Matthew Knepley <knepley at gmail.com> wrote:
> On Tue, Sep 26, 2017 at 8:28 AM, Praveen C <cpraveen at gmail.com> wrote:
>
>> Dear all
>>
>> I am solving a nonlinear problem using matrix-free approach in snes and I
>> give a preconditioner matrix via SNESSetJacobian. My preconditioner is
>> based on a first order scheme which is linear and hence preconditioner
>> matrix will not change. How do I tell snes not to recompute it ?
>>
>
> http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/SNES/
> SNESSetLagPreconditioner.html
>
> Matt
>
>
>> Thanks
>> praveen
>>
>
>
>
> --
> What most experimenters take for granted before they begin their
> experiments is infinitely more interesting than any results to which their
> experiments lead.
> -- Norbert Wiener
>
> https://www.cse.buffalo.edu/~knepley/ <http://www.caam.rice.edu/~mk51/>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20170926/06c75279/attachment.html>
More information about the petsc-users
mailing list