>
|
|
Minimize the objective function with constraints and over the region .
The objective function is a procedure taking as input a Vector containing the and values.
>
|
p := proc (V)
(V[1]-1)^2+(V[2]-2)^2
end proc:
|
The constraints are specified as a procedure that accepts a Vector containing the and values as input and returns a Vector containing the constraint values.
>
|
nlc := proc(V, W)
W[1] := V[1]^2-1:
W[2] := V[1]+V[2]-1/2
end proc:
|
The bounds are specified as Vectors of dimension 2.
>
|
|
>
|
|
>
|
|
Find the global solution to the problem.
>
|
|
| (1) |