Overview | Group | Tree | Graph | Index | Concepts |
For each basic type, Concert Technology defines a corresponding array
class. IloNumVarArray
is the array class of the numeric
variable class for a model.
Instances of IloNumVarArray
are extensible. That is, you can
add more elements to such an array. References to an array change whenever
an element is added to or removed from the array.
Most member functions in this class contain assert
statements. For an explanation of the macro NDEBUG
(a way to
turn on or turn off these assert
statements), see the concept
Assert and NDEBUG.
See Also:
IloAllDiff, IloModel, IloNumVar, operator>>, operator<<
Constructor Summary | |
---|---|
public | IloNumVarArray(IloDefaultArrayI *) |
public | IloNumVarArray(const IloEnv, IloInt) |
public | IloNumVarArray(const IloEnv, const IloNumArray, const IloNumArray, IloNumVar::Type) |
public | IloNumVarArray(const IloEnv, IloNum, const IloNumArray, IloNumVar::Type) |
public | IloNumVarArray(const IloEnv, const IloNumArray, IloNum, IloNumVar::Type) |
public | IloNumVarArray(const IloEnv, IloInt, IloNum, IloNum, IloNumVar::Type) |
public | IloNumVarArray(const IloEnv, const IloNumColumnArray, IloNumVar::Type) |
public | IloNumVarArray(const IloEnv, const IloNumColumnArray, const IloNumArray, const IloNumArray, IloNumVar::Type) |
Method Summary | |
---|---|
public void | add(IloInt, const IloNumVar) |
public void | add(const IloNumVar) |
public void | add(const IloNumVarArray) |
public IloNumExprArg | operator()(IloNumExprArg) |
public void | setBounds(const IloNumArray, const IloNumArray) |
public IloIntExprArray | toIntExprArray() |
public IloIntVarArray | toIntVarArray() |
public IloNumExprArray | toNumExprArray() |
Inherited Methods from IloNumExprArray |
---|
add, add, add, operator() |
Inherited Methods from IloExtractableArray |
---|
add, add, add, endElements |
Constructor Detail |
---|
This constructor creates an empty extensible array of numeric
variables. You cannot create instances of the undocumented class
IloDefaultArrayI
. As a parameter in this default constructor,
it allows you to pass 0 (zero) optionally or to use 0 (zero) as a default
value of a parameter in a constructor.
This constructor creates an extensible array of n
numeric
variables in env
. Initially, the n
elements are
empty handles.
This constructor creates an extensible array of numeric variables in
env
with lower and upper bounds and type as indicated. The
instances of IloNumVar
to fill this array
are constructed at the same time. The length of the array lb
must be the same as the length of the array ub
. In other words,
lb.getSize == ub.getSize
. This constructor will construct an
array with the number of elements in the array ub
.
This constructor creates an extensible array of numeric variables in
env
with lower and upper bounds and type as indicated. The
instances of IloNumVar
to fill this array
are constructed at the same time. The length of the new array will be the
same as the length of the array ub
.
This constructor creates an extensible array of numeric variables in
env
with lower and upper bounds and type as indicated. The
instances of IloNumVar
to fill this array
are constructed at the same time.
This constructor creates an extensible array of n
numeric
variables in env
with lower and upper bounds and type as
indicated. The instances of IloNumVar
to
fill this array are constructed at the same time.
This constructor creates an extensible array of numeric variables with
type as indicated. The instances of IloNumVar
to fill this array are constructed at the same
time.
This constructor creates an extensible array of numeric variables with
lower and upper bounds and type as indicated. The instances of
IloNumVar
to fill this array are constructed
at the same time.
Method Detail |
---|
This member function appends x
to the invoking array
multiple times. The parameter more
indicates how many
times.
This member function appends x
to the invoking array.
This member function appends the elements in array
to the
invoking array.
This subscripting operator returns an expression argument for use in a
constraint or expression. For clarity, let's call A
the
invoking array. When anIntegerVariable
is bound to the value
i
, the domain of the expression is the domain of
A[i]
. More generally, the domain of the expression is the union
of the domains of the expressions A[i]
where the i
are in the domain of anIntegerVariable
.
For each element in the invoking array, this member function sets
lb
as the lower bound and ub
as the upper bound of
the corresponding numeric variable in the invoking array.
setBounds
notifies Concert
Technology algorithms about this change of bounds in this array of numeric
variables. This member function copies the invoking array to a new
IloIntExprArray
, checking the type of the variables during the
copy.
This member function copies the invoking array to a new
IloIntVarArray
, checking the type of the variables during the
copy.
This member function copies the invoking array to a new
IloNumExprArray
, checking the type of the variables during the
copy.