#include "petsctao.h" PetscErrorCode TaoGetGradient(Tao tao, Vec *g, PetscErrorCode (**func)(Tao, Vec, Vec, void*),void **ctx)Not collective
tao | - the Tao context |
g | - the vector to internally hold the gradient computation | |
func | - the gradient function | |
ctx | - user-defined context for private data for the gradient evaluation routine |
func (Tao tao, Vec x, Vec g, void *ctx);
x | - input vector | |
g | - gradient value (output) | |
ctx | - [optional] user-defined function context |