/** \page ConstraintsDoc How to create constrained objects
a constraint has finite lower and upper bounds, OPT++ treats it as two separate constraints. In the computation of the residuals and gradients constraints with finite lower bounds appear first followed by those with finte upper bounds. Consequently, in the optimization summary, you will see the constraint count is double the original number of constraints.
Now, we are ready to build an constrained nonlinear program. Let's consider the two-dimensional Rosenbrock problem with bound constraints. minimize \f[100(x_2 - x_{1}^2)^2 + (1 - x_1)^2 \f] subject to \f[ -2.0 \le x \le 2.0\f] Step 1: Build your compound constraint. \code int ndim = 2; ColumnVector lower(ndim), upper(ndim); lower = -2.0; upper = 2.0; Constraint bc = new BoundConstraint(ndim, lower, upper); CompoundConstraint* rosen_constraints = new CompoundConstraint(bc); \endcode Step 2: Create a nonlinear function with analytic derivatives.Next Section: Examples of test fragments | Back to Main Page
*/