Overview | Group | Tree | Graph | Index | Concepts |
Instances of the class IloBox
are multidimensional boxes that appear
in multidimensional placement problems. To solve packing or placement problems, you
may need to be able to place boxes within a given container. In such a situation,
both the boxes to place and the container to hold them are instances of the class
IloBox
.
To specify the containment relation that a given container holds a given box, use
the member function IloBox::contains
.
See Also:
IlcBox documented in the ILOG Solver Reference Manual , IlcFilterLevelConstraint documented in the ILOG Solver Reference Manual
Constructor Summary | |
---|---|
public | IloBox() |
public | IloBox(IloBox::ImplClass *) |
public | IloBox(const IloEnv, IloInt, const IloIntVarArray, const IloIntArray) |
Method Summary | |
---|---|
public IloConstraint | contains(IloBox) |
public IloInt | getDimensions() |
public IloBox::ImplClass * | getImpl() |
public IloConstraint | getNotOverlapConstraint() |
public IloIntVar | getOrigin(IloInt) |
public IloInt | getSize(IloInt) |
public IloConstraint | notOverlapInDimension(IloBox, IloBox, IloInt) |
public IloConstraint | overlapInDimension(IloBox, IloBox, IloInt) |
public IloConstraint | precedenceInDimension(IloBox, IloBox, IloInt) |
Inherited Methods from IloConstraint |
---|
getImpl |
Inherited Methods from IloIntExprArg |
---|
getImpl |
Inherited Methods from IloNumExprArg |
---|
getImpl |
Inherited Methods from IloExtractable |
---|
end, getEnv, getId, getImpl, getName, getObject, setName, setObject |
Constructor Detail |
---|
This constructor creates a box according to the specifications passed in the
parameters. The parameter dimensions
indicates the number of dimensions
the box has. The arrays origin
and size
must contain the
same number of elements as the number of dimensions of the box. In dimension
i, the box extends from origin[
i]
to
origin[
i]
+ size[
i]
. For example, the statement
IloBox(env, 2, IloNumVarArray (env, 2, 3, 0), IloNumArray(env, 2, 8, 4));
creates a box as shown in this illustration.
Method Detail |
---|
This member function creates a constraint that requires the invoking box to contain
box
. The parameter box
should have the same number of
dimensions as the invoking box.
This member function returns the number of dimensions of the invoking box.
This member function returns a constraint that specifies that none of the boxes contained in the invoking box can overlap along any of their dimensions.
The filter level of this constraint can be set using
IloSolver::setFilterLevel
. Currently two filter levels are allowed,
IlcBasic
, the default, and IlcMedium
, which is slower but
propagates more. You can specify the default filter level of this constraint using the
method IloSolver::setDefaultFilterLevel
. Refer to the ILOG Solver
Reference Manual for details about these methods.
This member function returns the origin of the invoking box along the dimension
indicated by dimension
.
This member function returns the length of the invoking box along the dimension
indicated by dimension
.
This member function returns a constraint that specifies that if box1
and box2
are contained in the invoking box, then they do not overlap
along the dimension indicated by dimension
.
This member function returns a constraint that specifies that if box1
and box2
are contained in the invoking box, then they must overlap along
the dimension indicated by dimension
.
If box1
and box2
are contained in the invoking box, then
this member function returns a constraint that specifies the precedence of
box1
over box2
along the dimension indicated by
dimension
.