#include "petsctaolinesearch.h" PetscErrorCode TaoLineSearchGetSolution(TaoLineSearch ls, Vec x, PetscReal *f, Vec g, PetscReal *steplength, TaoLineSearchConvergedReason *reason)Collective on TaoLineSearch
ls | - the TaoLineSearch context |
x | - the new solution | |
f | - the objective function value at x | |
g | - the gradient at x | |
steplength | - the multiple of the step direction taken by the line search | |
reason | - the reason why the line search terminated |
TAOLINESEARCH_FAILED_INFORNAN | - function evaluation gives Inf or Nan value | |
TAOLINESEARCH_FAILED_BADPARAMETER | - negative value set as parameter | |
TAOLINESEARCH_FAILED_ASCENT | - initial line search step * g is not descent direction | |
TAOLINESEARCH_HALTED_MAXFCN | - maximum number of function evaluation reached | |
TAOLINESEARCH_HALTED_UPPERBOUND | - step is at upper bound | |
TAOLINESEARCH_HALTED_LOWERBOUND | - step is at lower bound | |
TAOLINESEARCH_HALTED_RTOL | - range of uncertainty is smaller than given tolerance | |
TAOLINESEARCH_HALTED_USER | - user can set this reason to stop line search | |
TAOLINESEARCH_HALTED_OTHER | - any other reason | |
TAOLINESEARCH_SUCCESS | - successful line search |