ampl_eval_spst_w_val AMPL Toolbox ampl_evalg

AMPL Toolbox >> AMPL Toolbox > ampl_evalf

ampl_evalf

evaluate the objective function and the constraints value of a given AMPL problem

Calling Sequence

[f, c] = ampl_evalf(asl, x)

Parameters

x

the point where we evaluate the objective function and the constraints

asl

a structure which handles the pointer to the problem

f

the value of the objective function

c

a vector which contains the value of the constraints

Description

Evaluate the objective function and the constraints value of a given AMPL problem.

Examples

[asl, x0, bl, bu, v, cl, cu] = ampl_init('demos/data/ASL/ch03.nl');

[f, c] = ampl_evalf(asl, x0);

ampl_free(asl); // free the memory

See Also

Authors

ampl_eval_spst_w_val AMPL Toolbox ampl_evalg