tao-2.1-p0 2012-07-24

TaoLineSearchRegister

Adds a line-search algorithm to the registry Not collective

Input Parameters

sname - name of a new user-defined solver
path - path (either absolute or relative) the library containing this solver
cname - name of routine to Create method context
func - routine to Create method context

Notes

TaoLineSearchRegister() may be called multiple times to add several user-defined solvers.

If dynamic libraries are used, then the fourth input argument (func) is ignored.

Environmental variables such as ${TAO_DIR}, ${PETSC_ARCH}, ${PETSC_DIR}, and others of the form ${any_environmental_variable} occuring in pathname will be replaced with the appropriate values used when PETSc and TAO were compiled.

Sample usage

   TaoLineSearchRegister("my_linesearch","/home/username/mylibraries/${PETSC_ARCH}/mylib.a",
                "MyLinesearchCreate",MyLinesearchCreate);

Then, your solver can be chosen with the procedural interface via

    TaoLineSearchSetType(ls,"my_linesearch")
or at runtime via the option
    -tao_ls_type my_algorithm

See Also

TaoLineSearchRegisterDestroy()

Level:developer
Location:src/linesearch/interface/linesearch.c
TAO Solver Index
Table of Contents