GRBModel.AddRanges()

Add new range constraints to a model. A range constraint states that the value of the input expression must be between the specified lower and upper bounds in any solution.

GRBConstr[] AddRanges ( GRBLinExpr[] exprs,
    double[] lower,
    double[] upper,
    string[] names )
    Arguments:

    exprs: Linear expressions for the new range constraints.

    lower: Lower bounds for linear expressions.

    upper: Upper bounds for linear expressions.

    name: Names for new range constraints.

    count: Number of range constraints to add.

    Return value:

    Array of new constraint objects.