petsc-3.7.3 2016-07-24
Report Typos and Errors

# TaoSetConstraintsRoutine

Sets a function to be used to compute constraints. TAO only handles constraints under certain conditions, see manual for details

### Synopsis

    #include "petsctao.h"
    PetscErrorCode TaoSetConstraintsRoutine(Tao tao, Vec c, PetscErrorCode (*func)(Tao, Vec, Vec, void*), void *ctx)

Logically collective on Tao

### Input Parameters

| tao | - the Tao context
| c | - A vector that will be used to store constraint evaluation
| func | - the bounds computation routine
| ctx | - [optional] user-defined context for private data for the constraints computation (may be NULL)

### Calling sequence of func

         func (Tao tao, Vec x, Vec c, void *ctx);

| tao | - the Tao
| x | - point to evaluate constraints
| c | - vector constraints evaluated at x
| ctx | - the (optional) user-defined function context

### See Also

TaoSetObjectiveRoutine(), TaoSetHessianRoutine() TaoSetObjectiveAndGradientRoutine(), TaoSetVariablevBounds()

Level:intermediate
Location: src/tao/interface/taosolver_bounds.c
Index of all Tao routines
Table of Contents for all manual pages
Index of all manual pages

### Examples

src/tao/complementarity/examples/tutorials/minsurf1.c.html
src/tao/complementarity/examples/tutorials/blackscholes.c.html
src/tao/pde_constrained/examples/tutorials/elliptic.c.html
src/tao/pde_constrained/examples/tutorials/parabolic.c.html
src/tao/pde_constrained/examples/tutorials/hyperbolic.c.html