Skip to content

Add SNESAdjointSolve() and needed API plus example to demonstrate its use

Barry Smith requested to merge barry/2024-02-02/snesjacobianp into main

I would like to discuss this MR at the Tuesday Feb 20th developers meeting at 2 pm Eastern. I hope everyone can look at it before then, thanks.

A very conservative approach to the API imitating the style of TSAdjoint as much as possible. Including names of routines. I think some routines can have better more informative names.

I try to separate the handling of the f() optimization function from SNES as much as possible. I do not see an API that clearly separates the two since computing the gradient of f() hooks into details of both SNES and TS. But f() is really not the business of SNES so ....

Edited by Barry Smith

Merge request reports