TaoSetRecycleHistory#

Sets the boolean flag to enable/disable re-using iterate information from the previous TaoSolve(). This feature is disabled by default.

Synopsis#

#include "petsctao.h" 
PetscErrorCode TaoSetRecycleHistory(Tao tao, PetscBool recycle)

Logically Collective

Input Parameters#

  • tao - the Tao context

  • recycle - boolean flag

Options Database Key#

  • -tao_recycle_history <true,false> - reuse the history

Notes#

For conjugate gradient methods (TAOBNCG), this re-uses the latest search direction from the previous TaoSolve() call when computing the first search direction in a new solution. By default, CG methods set the first search direction to the negative gradient.

For quasi-Newton family of methods (TAOBQNLS, TAOBQNKLS, TAOBQNKTR, TAOBQNKTL), this re-uses the accumulated quasi-Newton Hessian approximation from the previous TaoSolve() call. By default, QN family of methods reset the initial Hessian approximation to the identity matrix.

For any other algorithm, this setting has no effect.

See Also#

TAO: Optimization Solvers, Tao, TaoGetRecycleHistory(), TAOBNCG, TAOBQNLS, TAOBQNKLS, TAOBQNKTR, TAOBQNKTL

Level#

intermediate

Location#

src/tao/interface/taosolver.c

Examples#

src/tao/unconstrained/tutorials/rosenbrock3.c


Index of all Tao routines
Table of Contents for all manual pages
Index of all manual pages