|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
ilog.cplex.IloCplex
IloCplex
is the class used to create and solve
LP (linear problem) and MIP (mixed integer problem) Mathematical
Programming models. For modeling, this class implements the
IloMPModeler
interface and its base interfaces. See the
CPLEX 7.5 Java User's Manual for more information on modeling.
By extension of interfaces, an IloCplex
object is
an instance of an optimization model, IloModel
. This is the
model to which the optimization methods of IloCplex
will be
applied. For instance, upon invocation of the method solve()
,
the IloCplex
optimizer will solve this model. We will refer
to this model as the model loaded to the IloCplex
object, or simply as the IloCplex
model.
Models that can be solved by IloCplex
must be built only with
the following modeling objects:
IloNumVar
and its extensions
IloIntVar
and IloSemiContVar
IloRange
with
linear expressions
IloLPMatrix
IloObjective
with linear or quadratic expressions
IloConversion
IloSOS1
or
IloSOS2
IloMPModeler
, IloModeler
and
IloCplex
. They are characterized by the
fact that they can all be organized into a math programming formulation of
the form:
Minimize (or Maximize) c'x + x'Qx subject to L <= Ax <= U l <= x <= uplus
SOS
, which is the internal representation of the model
adopted by IloCplex
. Information relating to this
representation can be queried through methods:
IloCplex.getNrows()
for querying the number of rows of A,
IloCplex.getNcols()
for querying the number of columns of
A, IloCplex.getNNZs()
for querying the number of non-zero
elements in A, and IloCplex.getNSOSs()
for querying the
number of SOS
s.
IloCplex
model can be queried in more detail than is
available through the iterator defined for IloModeler
. Special
iterators for each of the supported modeling object types are provided.
SOS
s (special ordered set), the model is referred to
as a mixed integer problem (MIP).
No quadratic terms are allowed in the objective function in this case.
You can query whether the IloCplex
model is a MIP with method
isMIP()
.
IloCplex
uses a branch and cut procedure for solving MIPs.
It starts by temporarily removing all integrality constraints
from the problem to create a linear relaxation of the model. After solving
the relaxation, it checks whether violated cuts should be added.
This is iterated until no more cuts are added.
Then the solution of the
relaxation is checked to see whether it violates one or more of the
integrality constraints which have been removed. If so it picks one of the
variables and creates two new problems, each with more restrictive bounds on
the variables. For example, with binary (or boolean) variables, one problem
will fix the variable at 0
and the other at 1
.
These problems are referred
to as nodes of the branch and cut search tree, where the tree is
the data structure used to maintain the nodes. It is organized in such a
way as to show how each node has been created.
The process of creating the
subproblems is called branching. The branch and cut procedure
picks a node from the tree and proceeds with it in the same way as described
above. When an integer feasible solution has been found, it may be possible
to discard some of the nodes in the tree if it can be proven that their
corresponding problems cannot contain a better solution. This process is
called pruning, and a current solution is known as the
incumbent. Whenever during the branch and cut search a better
solution is found, that solution becomes the new incumbent. The algorithm
terminates when no more nodes are in the tree. The incumbent at this point
has then been proven to be the optimal solution of the IloCplex
model.
If the IloCplex
model is not a MIP, the solution procedure
described above is executed in a degenerate case. Since the linear
relaxation of the model is the model itself, solving the initial node is
equivalent to solving the full IloCplex
model. The initial
node is also called the root node.
Quadratic terms are supported in the objective if the model does not
contain any binary, boolean, or semi-continuous variables and no
SOS
s are part of the model. Such a model is referred to as a
Quadratic Program (QP). You can query whether the IloCplex
model is a QP by calling method isQP()
.
Solving the IloCplex
model is done by calling
solve
. In most cases this is all that is necessary, but if
needed IloCplex
offers much more control over the
solution process. Most importantly, the algorithm for solving the root and
other nodes can be controlled with the parameters
IloCplex.IntParam.RootAlg()
and
setNodeAlg()
. The various algorithm choices defined
in IloCplex.Algorithm
are:
IloCplex.Algorithm.Auto
IloCplex
Automatically select an algorithm default.
IloCplex.Algorithm.Primal
IloCplex.Algorithm.Dual
IloCplex.Algorithm.Network
IloCplex.Algorithm.Barrier
IloCplex.Algorithm.DualBarrier
setParam
. The selection
of a branch can be further controlled using priority orders.
Priority orders allow you to assign priorities to variables in order to
determine at which variables to branch first. Priority orders are set with
methods setDirection()
, setPriority()
,
setDirections()
, and setPriorities()
.
However, the highest level of control is achieved by use of callbacks (see IloCplex.Callback and its extensions).
The solve
method returns a boolean value indicating whether (
true
) or not
(false
) a solution (not necessarily the optimal one) has been found.
Further information about the solution can be queried with the method
getStatus()
. The return code of type
IloCplex.Status
indicates whether the
solution is feasible, bounded, or optimal, or if the model has been proven
to be infeasible or unbounded. See IloCplex.Status
for more information.
In addition, IloCplex.getCplexStatus()
provides more detailed
information about the status of the optimizer after the method
solve()
delivers its return. For example it can tell you that the
optimizer terminated with an infeasible solution because it reached an iteration
limit.
The most important solution information computed by IloCplex
is the solution vector and the objective function. This information can be
queried with methods getValue()
and getObjValue()
,
respectively. However, more solution information is computed by the
IloCplex.solve()
method including slack values, dual values and
reduced cost information.
What solution information is available depends on
the solution algorithm that was used to compute the solution.
In cases where a basis is available, the solution can be further
analyzed by performing sensitivity analysis. This information tells you
how sensitive the solution is with respect to changes in the
variable and constraint bounds of the model, or with respect to the
objective coefficients. The
information is computed and accessed with methods
getBoundSA()
, getRangeSA()
, getRHSSA()
and getObjSA()
.
An important consideration of solution information generated by computer is
quality. Since IloCplex
performs arithmetic operations using
finite precision, any solution is subject to numerical errors. Most of the
time the problem is not numerically challenging, and the numerical errors
are well withing tolerances. However, for numerically difficult models, it is
advised to verify the quality of the solution using method
IloCplex.getQuality()
, which offers a variety of quality
measures.
Inner Class Summary | |
static class |
IloCplex.Algorithm
This class specifies the solution algorithm type to be used by CPLEX. |
static class |
IloCplex.BarrierCallback
The callback class to use when IloCplex uses the barrier
optimizer. |
static class |
IloCplex.BasisStatus
This class provides an the types of basis status. |
static class |
IloCplex.BooleanParam
The symbolic parameter names class for IloCplex parameters with
boolean values. |
static class |
IloCplex.BranchCallback
An instance of this class represents a user-written callback in an application that uses an instance of IloCplex to solve a mixed integer program (MIP). |
static class |
IloCplex.BranchDirection
This class represents branch directions. |
static class |
IloCplex.BranchType
This class identifies the branch type for BranchCallback . |
static class |
IloCplex.Callback
The callback base class. |
static class |
IloCplex.ControlCallback
The control callback class is a base class for other callback classes. |
static interface |
IloCplex.CplexEndedException
Throws an exception when a method is called of an IloCplex
object or any object that has been created with it after the
end() method has been called. |
static class |
IloCplex.CplexStatus
Symbolic names for IloCplex internal altorithm status. |
static class |
IloCplex.CrossoverCallback
The callback class to use when IloCplex uses the barrier
optimizer, with crossover. |
static class |
IloCplex.CutCallback
This class represents a user-written callback in an application that uses an instance of IloCplex to solve a mixed integer programming
problem (a MIP). |
static class |
IloCplex.DeleteMode
This class lists the possible settings for the delete mode of IloCplex as controlled by the methods
setDeleteMode and getDeleteMode . |
static class |
IloCplex.DisjunctiveCutCallback
A user-written callback class. |
static class |
IloCplex.DoubleParam
Symbolic parameter names for double-valued IloCplex parameters. |
static class |
IloCplex.DualPricing
A class which lists values that the dual pricing parameter can assume in IloCplex for use with the dual simplex algorithm. |
static class |
IloCplex.DualSimplexCallback
The callback class to use when IloCplex uses the dual simplex
optimizer. |
static class |
IloCplex.FlowMIRCutCallback
A callback class to use when IloCplex is solving a MIP. |
static class |
IloCplex.FractionalCutCallback
A callback class to use when IloCplex is solving a MIP. |
static class |
IloCplex.HeuristicCallback
A callback class to use when IloCplex is solving a MIP. |
static class |
IloCplex.IIS
Objects of the class IIS represent an irreducibly inconsistent
set (IIS ). |
static class |
IloCplex.IncumbentCallback
This callback class is called whenever a new potential incumbent is found during branch and cut searches. |
static class |
IloCplex.IntegerFeasibilityStatus
This class is used to determine integer feasibility. |
static class |
IloCplex.IntParam
Symbolic parameter names for integer-valued IloCplex parameters. |
static class |
IloCplex.LPCallback
The LP callback class for user-written callbacks. |
static class |
IloCplex.MIPCallback
The class for callbacks when IloCplex is solving a MIP. |
static class |
IloCplex.MIPEmphasis
This class lists the types MIP solution emphasis values. |
static class |
IloCplex.NetworkCallback
The callback class to use when IloCplex uses the network
optimizer. |
static class |
IloCplex.NodeCallback
A class to identify which node will next be selected for branch and cut. |
static class |
IloCplex.NodeId
A class which identifies a MIP node. |
static class |
IloCplex.NodeSelect
This class lists values that the parameter NodeSel can
assume in IloCplex . |
static class |
IloCplex.PresolveCallback
The callback class for user-written callbacks during presolve. |
static class |
IloCplex.PrimalPricing
This class lists values that the primal pricing parameter can assume in IloCplex for use with the primal simplex algorithm. |
static class |
IloCplex.PrimalSimplexCallback
The callback class to use when IloCplex uses the primal
simplex optimizer. |
static class |
IloCplex.ProbingCallback
An instance of the class ProbingCallback represents a
user-written callback in an application that uses an instance of
IloCplex to solve a MIP (mixed integer programming problem). |
static class |
IloCplex.Quality
Objects of the class IloCplex.Quality contain information
computed to measure the quality of a solution. |
static class |
IloCplex.QualityType
This class contains symbolic names for IloCplex
solution qualities. |
static class |
IloCplex.SolveCallback
An instance of this class can be used to solve node LPs during a branch and cut search. |
static class |
IloCplex.Status
Enumeration type for solution statuses. |
static class |
IloCplex.StringParam
The class StringParam lists the parameters of CPLEX that
require a character string as a value. |
static class |
IloCplex.UnknownObjectException
Non- IloCplex object exception class. |
static class |
IloCplex.VariableSelect
The class which defines possible settings for the IloCplex.IntParam.VarSel parameter. |
Constructor Summary | |
IloCplex()
This constructor creates an IloCplex object with an empty
IloCplex model. |
Method Summary | |
IloRange |
addCut(IloRange rng)
Adds rng as a cut to the invoking IloCplex
object. |
IloRange[] |
addCuts(IloRange[] rng)
Adds IloRange[] array rng as a cut to the
invoking IloCplex
object. |
IloRange[] |
addCuts(IloRange[] rng,
int start,
int num)
Adds rng as a user cut to the invoking IloCplex
object. |
IloRange |
addEq(double v,
IloNumExpr e)
See IloMPModeler |
IloRange |
addEq(double v,
IloNumExpr e,
java.lang.String name)
See IloMPModeler |
IloRange |
addEq(IloNumExpr e,
double v)
See IloMPModeler |
IloRange |
addEq(IloNumExpr e,
double v,
java.lang.String name)
See IloMPModeler |
IloRange |
addEq(IloNumExpr e1,
IloNumExpr e2)
See IloMPModeler |
IloRange |
addEq(IloNumExpr e1,
IloNumExpr e2,
java.lang.String name)
See IloMPModeler |
IloRange |
addGe(double v,
IloNumExpr e)
See IloMPModeler |
IloRange |
addGe(double v,
IloNumExpr e,
java.lang.String name)
See IloMPModeler |
IloRange |
addGe(IloNumExpr e,
double v)
See IloMPModeler |
IloRange |
addGe(IloNumExpr e,
double v,
java.lang.String name)
See IloMPModeler |
IloRange |
addGe(IloNumExpr e1,
IloNumExpr e2)
See IloMPModeler |
IloRange |
addGe(IloNumExpr e1,
IloNumExpr e2,
java.lang.String name)
See IloMPModeler |
IloRange |
addLe(double v,
IloNumExpr e)
See IloMPModeler |
IloRange |
addLe(double v,
IloNumExpr e,
java.lang.String name)
See IloMPModeler |
IloRange |
addLe(IloNumExpr e,
double v)
See IloMPModeler |
IloRange |
addLe(IloNumExpr e,
double v,
java.lang.String name)
See IloMPModeler |
IloRange |
addLe(IloNumExpr e1,
IloNumExpr e2)
See IloMPModeler |
IloRange |
addLe(IloNumExpr e1,
IloNumExpr e2,
java.lang.String name)
See IloMPModeler |
IloLPMatrix |
addLPMatrix()
See IloMPModeler |
IloLPMatrix |
addLPMatrix(java.lang.String name)
See IloMPModeler |
IloObjective |
addMaximize()
See IloModeler |
IloObjective |
addMaximize(IloNumExpr expr)
See IloModeler |
IloObjective |
addMaximize(IloNumExpr expr,
java.lang.String name)
See IloModeler |
IloObjective |
addMaximize(java.lang.String name)
See IloModeler |
IloObjective |
addMinimize()
See IloModeler |
IloObjective |
addMinimize(IloNumExpr expr)
See IloModeler |
IloObjective |
addMinimize(IloNumExpr expr,
java.lang.String name)
See IloModeler |
IloObjective |
addMinimize(java.lang.String name)
See IloModeler |
IloObjective |
addObjective(IloObjectiveSense sense)
See IloModeler |
IloObjective |
addObjective(IloObjectiveSense sense,
IloNumExpr expr)
See IloModeler |
IloObjective |
addObjective(IloObjectiveSense sense,
IloNumExpr expr,
java.lang.String name)
See IloModeler |
IloObjective |
addObjective(IloObjectiveSense sense,
java.lang.String name)
See IloModeler |
IloRange |
addRange(double lb,
double ub)
See IloMPModeler |
IloRange |
addRange(double lb,
double ub,
java.lang.String name)
See IloMPModeler |
IloRange |
addRange(double lb,
IloNumExpr expr,
double ub)
See IloMPModeler |
IloRange |
addRange(double lb,
IloNumExpr expr,
double ub,
java.lang.String name)
See IloMPModeler |
IloSOS1 |
addSOS1(IloNumVar[] var,
double[] val)
See IloMPModeler |
IloSOS1 |
addSOS1(IloNumVar[] var,
double[] val,
int start,
int num)
See IloMPModeler |
IloSOS1 |
addSOS1(IloNumVar[] var,
double[] val,
int start,
int num,
java.lang.String name)
See IloMPModeler |
IloSOS1 |
addSOS1(IloNumVar[] var,
double[] val,
java.lang.String name)
See IloMPModeler |
IloSOS2 |
addSOS2(IloNumVar[] var,
double[] val)
See IloMPModeler |
IloSOS2 |
addSOS2(IloNumVar[] var,
double[] val,
int start,
int num)
See IloMPModeler |
IloSOS2 |
addSOS2(IloNumVar[] var,
double[] val,
int start,
int num,
java.lang.String name)
See IloMPModeler |
IloSOS2 |
addSOS2(IloNumVar[] var,
double[] val,
java.lang.String name)
See IloMPModeler |
void |
addToExpr(IloObjective obj,
IloNumExpr expr)
See IloMPModeler |
void |
addToExpr(IloRange obj,
IloNumExpr expr)
See IloMPModeler |
IloIntVar |
boolVar()
See IloModeler |
IloIntVar |
boolVar(IloColumn column)
See IloModeler |
IloIntVar |
boolVar(IloColumn column,
java.lang.String name)
See IloModeler |
IloIntVar |
boolVar(java.lang.String name)
See IloModeler |
IloIntVar[] |
boolVarArray(IloColumnArray cols)
See IloModeler |
IloIntVar[] |
boolVarArray(IloColumnArray cols,
java.lang.String[] name)
See IloModeler |
IloIntVar[] |
boolVarArray(int n)
See IloModeler |
IloIntVar[] |
boolVarArray(int n,
java.lang.String[] name)
See IloModeler |
void |
clearCallbacks()
Removes all callbacks. |
void |
clearCuts()
Deletes all user cuts added to the invoking IloCplex object
with the methods addCut and addCuts . |
void |
clearModel()
Removes objects from the IloCplex model. |
IloColumn |
column(IloLPMatrix lp)
See IloMPModeler |
IloColumn |
column(IloLPMatrix lp,
int[] ind,
double[] val)
See IloMPModeler |
IloColumn |
column(IloLPMatrix lp,
int[] ind,
double[] val,
int start,
int num)
See IloMPModeler |
IloColumn |
column(IloObjective obj,
double val)
See IloMPModeler |
IloColumn |
column(IloRange rng,
double val)
See IloMPModeler |
IloColumnArray |
columnArray(IloLPMatrix lp,
int num)
See IloMPModeler |
IloColumnArray |
columnArray(IloLPMatrix lp,
int num,
int[][] ind,
double[][] val)
See IloMPModeler |
IloColumnArray |
columnArray(IloObjective obj,
double[] val)
See IloMPModeler |
IloColumnArray |
columnArray(IloObjective obj,
double[] val,
int start,
int num)
See IloMPModeler |
IloColumnArray |
columnArray(IloRange rng,
double[] val)
See IloMPModeler |
IloColumnArray |
columnArray(IloRange rng,
double[] val,
int start,
int num)
See IloMPModeler |
IloNumExpr |
constant(double x)
See IloModeler |
IloIntExpr |
constant(int x)
See IloModeler |
IloConversion |
conversion(IloNumVar[] ilovar,
IloNumVarType type)
See IloMPModeler |
IloConversion |
conversion(IloNumVar[] ilovar,
IloNumVarType[] type)
See IloMPModeler |
IloConversion |
conversion(IloNumVar[] ilovar,
IloNumVarType[] type,
java.lang.String name)
See IloMPModeler |
IloConversion |
conversion(IloNumVar[] ilovar,
IloNumVarType type,
java.lang.String name)
See IloMPModeler |
IloConversion |
conversion(IloNumVar var,
IloNumVarType type)
See IloMPModeler |
IloConversion |
conversion(IloNumVar var,
IloNumVarType type,
java.lang.String name)
See IloMPModeler |
java.util.Iterator |
conversionIterator()
Returns an iterator over all IloConversion objects in the
IloCplex model. |
void |
delDirection(IloNumVar var)
Removes any existing branching direction assignments from the variable array var . |
void |
delDirections(IloNumVar[] var)
Removes any existing branching direction assignments from the variable array var . |
void |
delDirections(IloNumVar[] var,
int start,
int num)
Removes any existing branching direction assignments from num
variables in the array var , starting with variable
start . |
void |
delete(IloCopyable obj)
Removes the extractable from the extracted model, and all the extractables in the model. |
void |
delete(IloCopyable[] obj)
See IloMPModeler |
void |
delete(IloCopyable[] obj,
int beg,
int num)
Removes extractables from the extracted model, and all the extractables in the model. |
void |
delPriorities(IloNumVar[] var)
Removes any existing priority order assignments from the array of variables var . |
void |
delPriorities(IloNumVar[] var,
int start,
int num)
Removes any existing priority order assignments from num
variables in the array var , starting with variable
start . |
void |
delPriority(IloNumVar var)
Removes any existing priority order assignment from variable var . |
IloNumExpr |
diff(double v,
IloNumExpr e1)
See IloModeler |
IloIntExpr |
diff(IloIntExpr e1,
IloIntExpr e2)
See IloModeler |
IloIntExpr |
diff(IloIntExpr e,
int v)
See IloModeler |
IloNumExpr |
diff(IloNumExpr e,
double v)
See IloModeler |
IloNumExpr |
diff(IloNumExpr e1,
IloNumExpr e2)
See IloModeler |
IloIntExpr |
diff(int v,
IloIntExpr e1)
See IloModeler |
void |
end()
Releases IloCplex license. |
IloRange |
eq(double v,
IloNumExpr e)
See IloMPModeler |
IloRange |
eq(double v,
IloNumExpr e,
java.lang.String name)
See IloMPModeler |
IloRange |
eq(IloNumExpr e,
double v)
See IloMPModeler |
IloRange |
eq(IloNumExpr e,
double v,
java.lang.String name)
See IloMPModeler |
IloRange |
eq(IloNumExpr e1,
IloNumExpr e2)
See IloMPModeler |
IloRange |
eq(IloNumExpr e1,
IloNumExpr e2,
java.lang.String name)
See IloMPModeler |
void |
exportModel(java.lang.String name)
Writes IloCplex a model to a file. |
IloRange |
ge(double v,
IloNumExpr e)
See IloMPModeler |
IloRange |
ge(double v,
IloNumExpr e,
java.lang.String name)
See IloMPModeler |
IloRange |
ge(IloNumExpr e,
double v)
See IloMPModeler |
IloRange |
ge(IloNumExpr e,
double v,
java.lang.String name)
See IloMPModeler |
IloRange |
ge(IloNumExpr e1,
IloNumExpr e2)
See IloMPModeler |
IloRange |
ge(IloNumExpr e1,
IloNumExpr e2,
java.lang.String name)
See IloMPModeler |
int |
getAlgorithm()
Returns the algorithm that has been used for generating the current solution. |
double[] |
getAX(IloLPMatrix matrix)
Gets the vector of row activity values for the rows of an LP matrix. |
double[] |
getAX(IloLPMatrix matrix,
int first,
int num)
Gets the row activity values for a range of rows of an LP matrix. |
double |
getAX(IloRange rng)
Gets the row activity value for a range constraint. |
double[] |
getAX(IloRange[] irng)
Gets row activity values for an array of range constraints. |
double[] |
getAX(IloRange[] irng,
int first,
int num)
Queries row activity values for a set of range constraints. |
IloCplex.BasisStatus |
getBasisStatus(IloNumVar var)
Gets the basis status for variable var . |
IloCplex.BasisStatus |
getBasisStatus(IloRange rng)
Gets the basis status for constraint rng . |
IloCplex.BasisStatus[] |
getBasisStatuses(IloNumVar[] var)
Gets the basis status for the variables in array var . |
IloCplex.BasisStatus[] |
getBasisStatuses(IloNumVar[] var,
int start,
int num)
Gets the basis status for a set of variables in array var . |
IloCplex.BasisStatus[] |
getBasisStatuses(IloRange[] rng)
Gets the basis status for the constraints in array rng . |
IloCplex.BasisStatus[] |
getBasisStatuses(IloRange[] rng,
int start,
int num)
Gets the basis status for a set of constraints in array rng . |
double |
getBestObjValue()
Gets the objective value of the best active node in the current branch and cut tree. |
void |
getBoundSA(double[] lblower,
double[] lbupper,
double[] ublower,
double[] ubupper,
IloLPMatrix matrix)
Computes and returns sensitivity analysis information. |
void |
getBoundSA(double[] lblower,
double[] lbupper,
double[] ublower,
double[] ubupper,
IloLPMatrix matrix,
int start,
int num)
Computes and returns sensitivity analysis information for the variable bounds for all variables corresponding to the columns of the specified LP matrix. |
void |
getBoundSA(double[] lblower,
double[] lbupper,
double[] ublower,
double[] ubupper,
IloNumVar[] var)
Computes and returns sensitivity analysis information for variable bounds. |
void |
getBoundSA(double[] lblower,
double[] lbupper,
double[] ublower,
double[] ubupper,
IloNumVar[] var,
int start,
int num)
Computes and returns sensitivity analysis information for variable bounds. |
IloCplex.CplexStatus |
getCplexStatus()
Gets the CPLEX algorithmic status code. |
IloCplex.CplexStatus |
getCplexSubStatus()
This method is used to access the solution status of the last node problem solved in the event of an error termination in the previous invocation of solve. |
double |
getCutoff()
Gets the cutoff for the objective value when solving nodes during branch and cut search. |
boolean |
getDefault(IloCplex.BooleanParam which)
Gets the default value of a boolean parameter. |
double |
getDefault(IloCplex.DoubleParam which)
Gets the default value of a double parameter. |
int |
getDefault(IloCplex.IntParam which)
Gets the default value of an integer parameter. |
java.lang.String |
getDefault(IloCplex.StringParam which)
Gets the default value of a string parameter. |
IloCplex.DeleteMode |
getDeleteMode()
Returns the current delete mode of the invoking IloCplex . |
IloCplex.BranchDirection |
getDirection(IloNumVar var)
Returns the branch direction. |
IloCplex.BranchDirection[] |
getDirections(IloNumVar[] var)
Gets the branch directions for an array of variables. |
IloCplex.BranchDirection[] |
getDirections(IloNumVar[] var,
int start,
int num)
Gets the branch directions for a set of variables. |
double |
getDual(IloRange irng)
Gets the dual solution value for a range of constraints. |
double[] |
getDuals(IloLPMatrix matrix)
Gets the dual solution vector for the rows of LP matrix. |
double[] |
getDuals(IloLPMatrix matrix,
int first,
int num)
Gets the dual solution values for a range of rows of LP matrix. |
double[] |
getDuals(IloRange[] irng)
Gets the dual solution values for an array of range constraints. |
double[] |
getDuals(IloRange[] irng,
int first,
int num)
Gets the dual solution values for a set of range constraints. |
IloCplex.IIS |
getIIS()
Computes the IIS (Irreducibly Inconsistent Set) of an infeasible model. |
int |
getIncumbentNode()
Gets the node number of the incumbent. |
double |
getMax(IloCplex.DoubleParam which)
Gets the maximum allowed value for a double parameter. |
int |
getMax(IloCplex.IntParam which)
Gets the maximum allowed value for an integer parameter. |
double |
getMin(IloCplex.DoubleParam which)
Gets the minimum value allowed for a double parameter. |
int |
getMin(IloCplex.IntParam which)
Gets the minimum value allowed for an integer parameter. |
int |
getNbarrierIterations()
Returns the number of barrier iterations from the last solve. |
int |
getNbinVars()
Gets the number of binary variables in the matrix representation of the active model in the invoking IloCplex object. |
int |
getNcliques()
Gets the number of clique cuts added to the problem. |
int |
getNcols()
Gets the number of columns in the matrix representation of the IloCplex
model. |
int |
getNcovers()
Gets the number of cover cuts added to the problem. |
int |
getNcrossDExch()
Gets the number of dual exchange operations in the crossover of the last solve. |
int |
getNcrossDPush()
Gets the number of dual push operations in the crossover of the last solve. |
int |
getNcrossPExch()
Gets the number of primal exchange operations in the crossover of the last solve. |
int |
getNcrossPPush()
Gets the number of primal push operations in the crossover of the last solve. |
int |
getNdualSuperbasics()
Gets the number of dual superbasic variables in the basis. |
int |
getNintVars()
Gets the number of integer variables in the matrix representation of the active model in the invoking IloCplex object. |
int |
getNiterations()
Gets the number of iterations from the last solve. |
int |
getNnodes()
Gets the number of nodes processed in the current solution. |
int |
getNnodesLeft()
Gets the number of nodes that remain to be processed in the current solution. |
int |
getNNZs()
Gets the number of non-zero elements of the matrix representation of the IloCplex model. |
int |
getNphaseOneIterations()
Gets the number of Phase I iterations from the last solve. |
int |
getNprimalSuperbasics()
Gets the number of primal superbasic variables in the basis. |
int |
getNrows()
Gets the number of rows of the matrix representation of the IloCplex
model. |
int |
getNsemiContVars()
Gets the number of semi-continuous variables in the matrix representation of the active model in the invoking IloCplex object. |
int |
getNsemiIntVars()
Gets the number of semi-integer variables in the matrix representation of the active model in the invoking IloCplex object. |
int |
getNSOS1()
Gets the number of SOS s of type 1, in the
IloCplex model. |
int |
getNSOS2()
Gets the number of SOS s of type 2, in the
IloCplex model. |
int |
getNSOSs()
Gets the number of SOS s of both types, 1 and 2, in the
IloCplex model. |
IloObjective |
getObjective()
Gets the IloObjective object of the
IloCplex model, or null if no
IloObject object
is currently in the IloCplex model. |
void |
getObjSA(double[] lower,
double[] upper,
IloLPMatrix matrix)
Computes and returns sensitivity analysis information for objective coefficients. |
void |
getObjSA(double[] lower,
double[] upper,
IloLPMatrix matrix,
int start,
int num)
Computes and returns sensitivity analysis information for objective coefficients. |
void |
getObjSA(double[] lower,
double[] upper,
IloNumVar[] var)
Computes and returns sensitivity analysis information for objective coefficients. |
void |
getObjSA(double[] lower,
double[] upper,
IloNumVar[] var,
int start,
int num)
Computes and returns sensitivity analysis information for objective coefficients. |
double |
getObjValue()
Gets the objective value of the current solution. |
boolean |
getParam(IloCplex.BooleanParam which)
Gets the current value of a boolean parameter. |
double |
getParam(IloCplex.DoubleParam which)
Gets the current value of a double parameter. |
int |
getParam(IloCplex.IntParam which)
Gets the current value of an integer parameter. |
java.lang.String |
getParam(IloCplex.StringParam which)
Gets the current value of a string parameter. |
int[] |
getPriorities(IloNumVar[] var)
Gets the branch priorities for an array of variables. |
int[] |
getPriorities(IloNumVar[] var,
int start,
int num)
Gets the branch priorities for a set of variables. |
int |
getPriority(IloNumVar var)
Gets the branch priority for a variable. |
IloCplex.Quality |
getQuality(IloCplex.QualityType which)
Gets an IloCplex.Quality object that contains the information
for the requested quality measure. |
void |
getRangeSA(double[] lblower,
double[] lbupper,
double[] ublower,
double[] ubupper,
IloLPMatrix lp)
Computes and returns sensitivity analysis information for all rows of the matrix lp constraint bounds. |
void |
getRangeSA(double[] lblower,
double[] lbupper,
double[] ublower,
double[] ubupper,
IloLPMatrix lp,
int start,
int num)
Computes and returns sensitivity analysis information for range for num rows of the LP starting with row start
in LP constraint matrix lp . |
void |
getRangeSA(double[] lblower,
double[] lbupper,
double[] ublower,
double[] ubupper,
IloRange[] rng)
Computes and returns sensitivity analysis information for range constraint bounds. |
void |
getRangeSA(double[] lblower,
double[] lbupper,
double[] ublower,
double[] ubupper,
IloRange[] rng,
int start,
int num)
Computes and returns sensitivity analysis information for range constraint bounds. |
double |
getReducedCost(IloNumVar ivar)
Gets the reduced cost for a variable. |
double[] |
getReducedCosts(IloLPMatrix matrix)
Gets reduced costs for the columns of LP matrix. |
double[] |
getReducedCosts(IloLPMatrix matrix,
int begin,
int num)
Gets reduced costs for a range of columns of LP matrix. |
double[] |
getReducedCosts(IloNumVar[] ivar)
Gets reduced costs for an array of variables. |
double[] |
getReducedCosts(IloNumVar[] ivar,
int begin,
int num)
Gets reduced costs for a set of variables. |
void |
getRHSSA(double[] lower,
double[] upper,
IloLPMatrix lp)
Computes and returns sensitivity analysis information for RHS values of constraints. |
void |
getRHSSA(double[] lower,
double[] upper,
IloLPMatrix lp,
int start,
int num)
Computes and returns sensitivity analysis information for RHS values of constraints. |
void |
getRHSSA(double[] lower,
double[] upper,
IloRange[] rng)
Computes and returns sensitivity analysis information for RHS values of constraints. |
void |
getRHSSA(double[] lower,
double[] upper,
IloRange[] rng,
int start,
int num)
Computes and returns sensitivity analysis information for RHS values of constraints. |
double |
getSlack(IloRange rng)
Gets the slack value for a range constraint. |
double[] |
getSlacks(IloLPMatrix matrix)
Gets the vector of slack values for the rows of an LP matrix. |
double[] |
getSlacks(IloLPMatrix matrix,
int first,
int num)
Gets slack values for a range of rows of an LP matrix. |
double[] |
getSlacks(IloRange[] irng)
Gets slack values for an array of range constraints. |
double[] |
getSlacks(IloRange[] irng,
int first,
int num)
Gets slack values for a set of range constraints. |
IloCplex.Status |
getStatus()
Gets the solution status of the IloCplex model. |
int |
getSubAlgorithm()
Returns the algorithm that has been used for generating the solution of the last branch and cut node that was solved. |
double |
getValue(IloNumExpr expr)
Gets the value that expr takes for the current solution. |
double |
getValue(IloNumVar ivar)
Gets the solution value for a variable. |
double[] |
getValues(IloLPMatrix matrix)
Gets the solution vector for the columns of an LP matrix. |
double[] |
getValues(IloLPMatrix matrix,
int begin,
int num)
Gets the solution vector for a range of columns of an LP matrix. |
double[] |
getValues(IloNumVar[] ivar)
Gets solution values of an array of variables. |
double[] |
getValues(IloNumVar[] ivar,
int first,
int num)
Gets solution values for a set of variables. |
java.lang.String |
getVersion()
Gets the string that indicates the version of CPLEX. |
void |
importModel(java.lang.String name)
Reads a model into IloCplex model. |
IloIntVar |
intVar(IloColumn column,
int lb,
int ub)
See IloModeler |
IloIntVar |
intVar(IloColumn column,
int lb,
int ub,
java.lang.String name)
See IloModeler |
IloIntVar |
intVar(int lb,
int ub)
See IloModeler |
IloIntVar |
intVar(int lb,
int ub,
java.lang.String name)
See IloModeler |
IloIntVar[] |
intVarArray(IloColumnArray cols,
int[] lb,
int[] ub)
See IloModeler |
IloIntVar[] |
intVarArray(IloColumnArray cols,
int[] lb,
int[] ub,
java.lang.String[] name)
See IloModeler |
IloIntVar[] |
intVarArray(IloColumnArray cols,
int lb,
int ub)
See IloModeler |
IloIntVar[] |
intVarArray(IloColumnArray cols,
int lb,
int ub,
java.lang.String[] name)
See IloModeler |
IloIntVar[] |
intVarArray(int n,
int[] lb,
int[] ub)
See IloModeler |
IloIntVar[] |
intVarArray(int n,
int[] lb,
int[] ub,
java.lang.String[] name)
See IloModeler |
IloIntVar[] |
intVarArray(int n,
int lb,
int ub)
See IloModeler |
IloIntVar[] |
intVarArray(int n,
int lb,
int ub,
java.lang.String[] name)
See IloModeler |
boolean |
isMIP()
Returns true if the IloCplex model is a MIP. |
boolean |
isQP()
Returns true if the IloCplex model is a QP. |
IloRange |
le(double v,
IloNumExpr e)
See IloMPModeler |
IloRange |
le(double v,
IloNumExpr e,
java.lang.String name)
See IloMPModeler |
IloRange |
le(IloNumExpr e,
double v)
See IloMPModeler |
IloRange |
le(IloNumExpr e,
double v,
java.lang.String name)
See IloMPModeler |
IloRange |
le(IloNumExpr e1,
IloNumExpr e2)
See IloMPModeler |
IloRange |
le(IloNumExpr e1,
IloNumExpr e2,
java.lang.String name)
See IloMPModeler |
IloLinearIntExpr |
linearIntExpr()
See IloModeler |
IloLinearIntExpr |
linearIntExpr(int val)
See IloModeler |
IloLinearNumExpr |
linearNumExpr()
See IloModeler |
IloLinearNumExpr |
linearNumExpr(double val)
See IloModeler |
IloLPMatrix |
LPMatrix()
See IloMPModeler |
IloLPMatrix |
LPMatrix(java.lang.String name)
See IloMPModeler |
java.util.Iterator |
LPMatrixIterator()
Returns an iterator over all IloLPMatrix objects in the
IloCplex model. |
IloObjective |
maximize()
See IloModeler |
IloObjective |
maximize(IloNumExpr expr)
See IloModeler |
IloObjective |
maximize(IloNumExpr expr,
java.lang.String name)
See IloModeler |
IloObjective |
maximize(java.lang.String name)
See IloModeler |
IloObjective |
minimize()
See IloModeler |
IloObjective |
minimize(IloNumExpr expr)
See IloModeler |
IloObjective |
minimize(IloNumExpr expr,
java.lang.String name)
See IloModeler |
IloObjective |
minimize(java.lang.String name)
See IloModeler |
IloIntExpr |
negative(IloIntExpr e)
See IloModeler |
IloNumExpr |
negative(IloNumExpr e)
See IloModeler |
IloNumVar |
numVar(double lb,
double ub)
See IloModeler |
IloNumVar |
numVar(double lb,
double ub,
IloNumVarType type)
See IloModeler |
IloNumVar |
numVar(double lb,
double ub,
IloNumVarType type,
java.lang.String name)
See IloModeler |
IloNumVar |
numVar(double lb,
double ub,
java.lang.String name)
See IloModeler |
IloNumVar |
numVar(IloColumn column,
double lb,
double ub)
See IloModeler |
IloNumVar |
numVar(IloColumn column,
double lb,
double ub,
IloNumVarType type)
See IloModeler |
IloNumVar |
numVar(IloColumn column,
double lb,
double ub,
IloNumVarType type,
java.lang.String name)
See IloModeler |
IloNumVar |
numVar(IloColumn column,
double lb,
double ub,
java.lang.String name)
See IloModeler |
IloNumVar[] |
numVarArray(IloColumnArray cols,
double[] lb,
double[] ub)
See IloModeler |
IloNumVar[] |
numVarArray(IloColumnArray cols,
double[] lb,
double[] ub,
IloNumVarType[] type)
See IloModeler |
IloNumVar[] |
numVarArray(IloColumnArray cols,
double[] lb,
double[] ub,
IloNumVarType[] type,
java.lang.String[] name)
See IloModeler |
IloNumVar[] |
numVarArray(IloColumnArray cols,
double[] lb,
double[] ub,
java.lang.String[] name)
See IloModeler |
IloNumVar[] |
numVarArray(IloColumnArray cols,
double lb,
double ub)
See IloModeler |
IloNumVar[] |
numVarArray(IloColumnArray cols,
double lb,
double ub,
IloNumVarType type)
See IloModeler |
IloNumVar[] |
numVarArray(IloColumnArray cols,
double lb,
double ub,
IloNumVarType type,
java.lang.String[] name)
See IloModeler |
IloNumVar[] |
numVarArray(IloColumnArray cols,
double lb,
double ub,
java.lang.String[] name)
See IloModeler |
IloNumVar[] |
numVarArray(int n,
double[] lb,
double[] ub)
See IloModeler |
IloNumVar[] |
numVarArray(int n,
double[] lb,
double[] ub,
IloNumVarType[] type)
See IloModeler |
IloNumVar[] |
numVarArray(int n,
double[] lb,
double[] ub,
IloNumVarType[] type,
java.lang.String[] name)
See IloModeler |
IloNumVar[] |
numVarArray(int n,
double[] lb,
double[] ub,
java.lang.String[] name)
See IloModeler |
IloNumVar[] |
numVarArray(int n,
double lb,
double ub)
See IloModeler |
IloNumVar[] |
numVarArray(int n,
double lb,
double ub,
IloNumVarType type)
See IloModeler |
IloNumVar[] |
numVarArray(int n,
double lb,
double ub,
IloNumVarType type,
java.lang.String[] name)
See IloModeler |
IloNumVar[] |
numVarArray(int n,
double lb,
double ub,
java.lang.String[] name)
See IloModeler |
IloObjective |
objective(IloObjectiveSense sense)
See IloModeler |
IloObjective |
objective(IloObjectiveSense sense,
IloNumExpr expr)
See IloModeler |
IloObjective |
objective(IloObjectiveSense sense,
IloNumExpr expr,
java.lang.String name)
See IloModeler |
IloObjective |
objective(IloObjectiveSense sense,
java.lang.String name)
See IloModeler |
java.io.OutputStream |
out()
Gets the output stream of the invoking IloCplex object. |
IloNumExpr |
piecewiseLinear(IloNumExpr base,
double[] points,
double[] slopes,
double a,
double fa)
See IloModeler |
IloNumExpr |
piecewiseLinear(IloNumExpr base,
double[] points,
int startPoints,
int num,
double[] slopes,
int startSlopes,
double a,
double fa)
See IloModeler |
IloNumExpr |
prod(double v,
IloNumExpr e1)
See IloModeler |
IloIntExpr |
prod(IloIntExpr e1,
IloIntExpr e2)
See IloModeler |
IloIntExpr |
prod(IloIntExpr e,
int v)
See IloModeler |
IloNumExpr |
prod(IloNumExpr e,
double v)
See IloModeler |
IloNumExpr |
prod(IloNumExpr e1,
IloNumExpr e2)
See IloModeler |
IloIntExpr |
prod(int v,
IloIntExpr e1)
See IloModeler |
IloRange |
range(double lb,
double ub)
See IloMPModeler |
IloRange |
range(double lb,
double ub,
java.lang.String name)
See IloMPModeler |
IloRange |
range(double lb,
IloNumExpr expr,
double ub)
See IloMPModeler |
IloRange |
range(double lb,
IloNumExpr expr,
double ub,
java.lang.String name)
See IloMPModeler |
java.util.Iterator |
rangeIterator()
Returns an iterator over all IloRange objects in the
IloCplex model. |
IloLinearNumExpr |
scalProd(double[] vals,
IloNumVar[] vars)
See IloModeler |
IloLinearNumExpr |
scalProd(double[] vals,
IloNumVar[] vars,
int start,
int num)
See IloModeler |
IloLinearIntExpr |
scalProd(IloIntVar[] vars,
int[] vals)
See IloModeler |
IloLinearIntExpr |
scalProd(IloIntVar[] vars,
int[] vals,
int start,
int num)
See IloModeler |
IloLinearNumExpr |
scalProd(IloNumVar[] vars,
double[] vals)
See IloModeler |
IloLinearNumExpr |
scalProd(IloNumVar[] vars,
double[] vals,
int start,
int num)
See IloModeler |
IloLinearNumExpr |
scalProd(IloNumVar[] vars,
int[] vals)
See IloModeler |
IloLinearNumExpr |
scalProd(IloNumVar[] vars,
int[] vals,
int start,
int num)
See IloModeler |
IloLinearIntExpr |
scalProd(int[] vals,
IloIntVar[] vars)
See IloModeler |
IloLinearIntExpr |
scalProd(int[] vals,
IloIntVar[] vars,
int start,
int num)
See IloModeler |
IloLinearNumExpr |
scalProd(int[] vals,
IloNumVar[] vars)
See IloModeler |
IloLinearNumExpr |
scalProd(int[] vals,
IloNumVar[] vars,
int start,
int num)
See IloModeler |
IloSemiContVar |
semiContVar(double lb,
double ub,
IloNumVarType type)
See IloMPModeler |
IloSemiContVar |
semiContVar(double lb,
double ub,
IloNumVarType type,
java.lang.String name)
See IloMPModeler |
IloSemiContVar |
semiContVar(IloColumn column,
double lb,
double ub,
IloNumVarType type)
See IloMPModeler |
IloSemiContVar |
semiContVar(IloColumn column,
double lb,
double ub,
IloNumVarType type,
java.lang.String name)
See IloMPModeler |
IloSemiContVar[] |
semiContVarArray(IloColumnArray cols,
double[] lb,
double[] ub,
IloNumVarType[] type)
See IloMPModeler |
IloSemiContVar[] |
semiContVarArray(IloColumnArray cols,
double[] lb,
double[] ub,
IloNumVarType[] type,
java.lang.String[] name)
See IloMPModeler |
IloSemiContVar[] |
semiContVarArray(IloColumnArray cols,
double lb,
double ub,
IloNumVarType type)
See IloMPModeler |
IloSemiContVar[] |
semiContVarArray(IloColumnArray cols,
double lb,
double ub,
IloNumVarType type,
java.lang.String[] name)
See IloMPModeler |
IloSemiContVar[] |
semiContVarArray(int n,
double[] lb,
double[] ub,
IloNumVarType[] type)
See IloMPModeler |
IloSemiContVar[] |
semiContVarArray(int n,
double[] lb,
double[] ub,
IloNumVarType[] type,
java.lang.String[] name)
See IloMPModeler |
IloSemiContVar[] |
semiContVarArray(int n,
double lb,
double ub,
IloNumVarType type)
See IloMPModeler |
IloSemiContVar[] |
semiContVarArray(int n,
double lb,
double ub,
IloNumVarType type,
java.lang.String[] name)
See IloMPModeler |
void |
setBasisStatuses(IloNumVar[] var,
IloCplex.BasisStatus[] cstat,
IloRange[] rng,
IloCplex.BasisStatus[] rstat)
Sets the basis status for variables. |
void |
setBasisStatuses(IloNumVar[] var,
IloCplex.BasisStatus[] cstat,
int cstart,
int cnum,
IloRange[] rng,
IloCplex.BasisStatus[] rstat,
int rstart,
int rnum)
Sets the basis status for variables. |
void |
setDefaults()
Resets all CPLEX parameters to their default values. |
void |
setDeleteMode(IloCplex.DeleteMode mode)
Sets the delete mode. |
void |
setDirection(IloNumVar var,
IloCplex.BranchDirection dir)
Sets the branching direction for a variable. |
void |
setDirections(IloNumVar[] var,
IloCplex.BranchDirection[] brdir)
Sets the branching direction for an array of variables. |
void |
setDirections(IloNumVar[] var,
IloCplex.BranchDirection[] brdir,
int start,
int num)
Sets the branching direction for a set of variables. |
void |
setLinearCoef(IloObjective obj,
double val,
IloNumVar var)
See IloMPModeler |
void |
setLinearCoef(IloObjective obj,
IloNumVar var,
double val)
See IloMPModeler |
void |
setLinearCoef(IloRange obj,
double val,
IloNumVar var)
See IloMPModeler |
void |
setLinearCoef(IloRange obj,
IloNumVar var,
double val)
See IloMPModeler |
void |
setLinearCoefs(IloObjective obj,
double[] val,
IloNumVar[] var)
See IloMPModeler |
void |
setLinearCoefs(IloObjective obj,
double[] val,
IloNumVar[] var,
int start,
int num)
See IloMPModeler |
void |
setLinearCoefs(IloObjective obj,
IloNumVar[] var,
double[] val)
See IloMPModeler |
void |
setLinearCoefs(IloObjective obj,
IloNumVar[] var,
double[] val,
int start,
int num)
See IloMPModeler |
void |
setLinearCoefs(IloRange obj,
double[] val,
IloNumVar[] var)
See IloMPModeler |
void |
setLinearCoefs(IloRange obj,
double[] val,
IloNumVar[] var,
int start,
int num)
See IloMPModeler |
void |
setLinearCoefs(IloRange obj,
IloNumVar[] var,
double[] val)
See IloMPModeler |
void |
setLinearCoefs(IloRange obj,
IloNumVar[] var,
double[] val,
int start,
int num)
See IloMPModeler |
void |
setOut(java.io.OutputStream s)
Sets the default output stream of the invoking IloCplex
object. |
void |
setParam(IloCplex.BooleanParam which,
boolean val)
Sets a boolean parameter to value val . |
void |
setParam(IloCplex.DoubleParam which,
double val)
Sets a double parameter to value val . |
void |
setParam(IloCplex.IntParam which,
int val)
Sets an integer parameter to value val . |
void |
setParam(IloCplex.StringParam which,
java.lang.String val)
Sets a string parameter to value val . |
void |
setPriorities(IloNumVar[] var,
int[] pri)
Sets the branch priority for an array of variables. |
void |
setPriorities(IloNumVar[] var,
int[] pri,
int start,
int num)
Sets the branch priority for a set of variables. |
void |
setPriority(IloNumVar var,
int pri)
Sets the branch priority for variable var . |
void |
setVectors(double[] x,
double[] dj,
IloNumVar[] var,
double[] slack,
double[] pi,
IloRange[] rng)
Specifies an array of starting points for the invocation of method solve() . |
void |
setVectors(double[] x,
double[] dj,
IloNumVar[] var,
int vstart,
int vnum,
double[] slack,
double[] pi,
IloRange[] rng,
int rstart,
int rnum)
Specifiies a starting point for the invocation of method solve() . |
void |
setWarning(java.io.OutputStream s)
Sets the warning stream of the invoking IloCplex object. |
boolean |
solve()
Solves the IloCplex model. |
boolean |
solveFixed()
Solves the fixed IloCplex model. |
boolean |
solveRelaxed()
Solves the LP relaxation IloCplex model. |
boolean |
solveZeroedQP()
Solves the LP part of a QP IloCplex model. |
IloSOS1 |
SOS1(IloNumVar[] var,
double[] val)
See IloMPModeler |
IloSOS1 |
SOS1(IloNumVar[] var,
double[] val,
int start,
int num)
See IloMPModeler |
IloSOS1 |
SOS1(IloNumVar[] var,
double[] val,
int start,
int num,
java.lang.String name)
See IloMPModeler |
IloSOS1 |
SOS1(IloNumVar[] var,
double[] val,
java.lang.String name)
See IloMPModeler |
java.util.Iterator |
SOS1iterator()
Returns an iterator over all IloSOS1 objects in the
IloCplex model. |
IloSOS2 |
SOS2(IloNumVar[] var,
double[] val)
See IloMPModeler |
IloSOS2 |
SOS2(IloNumVar[] var,
double[] val,
int start,
int num)
See IloMPModeler |
IloSOS2 |
SOS2(IloNumVar[] var,
double[] val,
int start,
int num,
java.lang.String name)
See IloMPModeler |
IloSOS2 |
SOS2(IloNumVar[] var,
double[] val,
java.lang.String name)
See IloMPModeler |
java.util.Iterator |
SOS2iterator()
Returns an iterator over all IloSOS2 objects in the
IloCplex model. |
IloIntExpr |
square(IloIntExpr e)
See IloModeler |
IloNumExpr |
square(IloNumExpr e)
See IloModeler |
IloNumExpr |
sum(double v,
IloNumExpr e1)
See IloModeler |
IloIntExpr |
sum(IloIntExpr[] expr)
See IloModeler |
IloIntExpr |
sum(IloIntExpr[] expr,
int start,
int num)
See IloModeler |
IloIntExpr |
sum(IloIntExpr expr1,
IloIntExpr expr2)
See IloModeler |
IloIntExpr |
sum(IloIntExpr expr1,
IloIntExpr expr2,
IloIntExpr expr3)
See IloModeler |
IloIntExpr |
sum(IloIntExpr expr1,
IloIntExpr expr2,
IloIntExpr expr3,
IloIntExpr expr4)
See IloModeler |
IloIntExpr |
sum(IloIntExpr expr1,
IloIntExpr expr2,
IloIntExpr expr3,
IloIntExpr expr4,
IloIntExpr expr5)
See IloModeler |
IloIntExpr |
sum(IloIntExpr expr1,
IloIntExpr expr2,
IloIntExpr expr3,
IloIntExpr expr4,
IloIntExpr expr5,
IloIntExpr expr6)
See IloModeler |
IloIntExpr |
sum(IloIntExpr expr1,
IloIntExpr expr2,
IloIntExpr expr3,
IloIntExpr expr4,
IloIntExpr expr5,
IloIntExpr expr6,
IloIntExpr expr7)
See IloModeler |
IloIntExpr |
sum(IloIntExpr expr1,
IloIntExpr expr2,
IloIntExpr expr3,
IloIntExpr expr4,
IloIntExpr expr5,
IloIntExpr expr6,
IloIntExpr expr7,
IloIntExpr expr8)
See IloModeler |
IloIntExpr |
sum(IloIntExpr e,
int v)
See IloModeler |
IloNumExpr |
sum(IloNumExpr[] expr)
See IloModeler |
IloNumExpr |
sum(IloNumExpr[] expr,
int start,
int num)
See IloModeler |
IloNumExpr |
sum(IloNumExpr e,
double v)
See IloModeler |
IloNumExpr |
sum(IloNumExpr e1,
IloNumExpr e2)
See IloModeler |
IloNumExpr |
sum(IloNumExpr expr1,
IloNumExpr expr2,
IloNumExpr expr3)
See IloModeler |
IloNumExpr |
sum(IloNumExpr expr1,
IloNumExpr expr2,
IloNumExpr expr3,
IloNumExpr expr4)
See IloModeler |
IloNumExpr |
sum(IloNumExpr expr1,
IloNumExpr expr2,
IloNumExpr expr3,
IloNumExpr expr4,
IloNumExpr expr5)
See IloModeler |
IloNumExpr |
sum(IloNumExpr expr1,
IloNumExpr expr2,
IloNumExpr expr3,
IloNumExpr expr4,
IloNumExpr expr5,
IloNumExpr expr6)
See IloModeler |
IloNumExpr |
sum(IloNumExpr expr1,
IloNumExpr expr2,
IloNumExpr expr3,
IloNumExpr expr4,
IloNumExpr expr5,
IloNumExpr expr6,
IloNumExpr expr7)
See IloModeler |
IloNumExpr |
sum(IloNumExpr expr1,
IloNumExpr expr2,
IloNumExpr expr3,
IloNumExpr expr4,
IloNumExpr expr5,
IloNumExpr expr6,
IloNumExpr expr7,
IloNumExpr expr8)
See IloModeler |
IloIntExpr |
sum(int v,
IloIntExpr e1)
See IloModeler |
void |
use(IloCplex.Callback cb)
Sets a callback. |
java.io.OutputStream |
warning()
Gets the warning output stream of the invoking IloCplex
object. |
void |
writeOrder(java.lang.String name)
Write priority order file name. |
Constructor Detail |
public IloCplex() throws IloException
IloCplex
object with an empty
IloCplex
model.Method Detail |
public IloNumVar numVar(double lb, double ub, IloNumVarType type) throws IloException
IloModeler
public IloNumVar numVar(double lb, double ub, IloNumVarType type, java.lang.String name) throws IloException
IloModeler
public IloNumVar numVar(IloColumn column, double lb, double ub, IloNumVarType type) throws IloException
IloModeler
public IloNumVar numVar(IloColumn column, double lb, double ub, IloNumVarType type, java.lang.String name) throws IloException
IloModeler
public IloNumVar[] numVarArray(int n, double lb, double ub, IloNumVarType type) throws IloException
IloModeler
public IloNumVar[] numVarArray(int n, double lb, double ub, IloNumVarType type, java.lang.String[] name) throws IloException
IloModeler
public IloNumVar[] numVarArray(int n, double[] lb, double[] ub, IloNumVarType[] type) throws IloException
IloModeler
public IloNumVar[] numVarArray(int n, double[] lb, double[] ub, IloNumVarType[] type, java.lang.String[] name) throws IloException
IloModeler
public IloNumVar[] numVarArray(IloColumnArray cols, double lb, double ub, IloNumVarType type) throws IloException
IloModeler
public IloNumVar[] numVarArray(IloColumnArray cols, double lb, double ub, IloNumVarType type, java.lang.String[] name) throws IloException
IloModeler
public IloNumVar[] numVarArray(IloColumnArray cols, double[] lb, double[] ub, IloNumVarType[] type) throws IloException
IloModeler
public IloNumVar[] numVarArray(IloColumnArray cols, double[] lb, double[] ub, IloNumVarType[] type, java.lang.String[] name) throws IloException
IloModeler
public IloNumVar numVar(double lb, double ub, java.lang.String name) throws IloException
IloModeler
public IloNumVar numVar(double lb, double ub) throws IloException
IloModeler
public IloNumVar numVar(IloColumn column, double lb, double ub, java.lang.String name) throws IloException
IloModeler
public IloNumVar numVar(IloColumn column, double lb, double ub) throws IloException
IloModeler
public IloNumVar[] numVarArray(int n, double lb, double ub) throws IloException
IloModeler
public IloNumVar[] numVarArray(int n, double[] lb, double[] ub) throws IloException
IloModeler
public IloNumVar[] numVarArray(int n, double lb, double ub, java.lang.String[] name) throws IloException
IloModeler
public IloNumVar[] numVarArray(int n, double[] lb, double[] ub, java.lang.String[] name) throws IloException
IloModeler
public IloNumVar[] numVarArray(IloColumnArray cols, double lb, double ub) throws IloException
IloModeler
public IloNumVar[] numVarArray(IloColumnArray cols, double[] lb, double[] ub) throws IloException
IloModeler
public IloNumVar[] numVarArray(IloColumnArray cols, double lb, double ub, java.lang.String[] name) throws IloException
IloModeler
public IloNumVar[] numVarArray(IloColumnArray cols, double[] lb, double[] ub, java.lang.String[] name) throws IloException
IloModeler
public IloIntVar intVar(int lb, int ub, java.lang.String name) throws IloException
IloModeler
public IloIntVar intVar(int lb, int ub) throws IloException
IloModeler
public IloIntVar intVar(IloColumn column, int lb, int ub) throws IloException
IloModeler
public IloIntVar intVar(IloColumn column, int lb, int ub, java.lang.String name) throws IloException
IloModeler
public IloIntVar[] intVarArray(int n, int lb, int ub) throws IloException
IloModeler
public IloIntVar[] intVarArray(int n, int[] lb, int[] ub) throws IloException
IloModeler
public IloIntVar[] intVarArray(int n, int lb, int ub, java.lang.String[] name) throws IloException
IloModeler
public IloIntVar[] intVarArray(int n, int[] lb, int[] ub, java.lang.String[] name) throws IloException
IloModeler
public IloIntVar[] intVarArray(IloColumnArray cols, int lb, int ub, java.lang.String[] name) throws IloException
IloModeler
public IloIntVar[] intVarArray(IloColumnArray cols, int[] lb, int[] ub, java.lang.String[] name) throws IloException
IloModeler
public IloIntVar[] intVarArray(IloColumnArray cols, int lb, int ub) throws IloException
IloModeler
public IloIntVar[] intVarArray(IloColumnArray cols, int[] lb, int[] ub) throws IloException
IloModeler
public IloIntVar boolVar(java.lang.String name) throws IloException
IloModeler
public IloIntVar boolVar() throws IloException
IloModeler
public IloIntVar boolVar(IloColumn column, java.lang.String name) throws IloException
IloModeler
public IloIntVar boolVar(IloColumn column) throws IloException
IloModeler
public IloIntVar[] boolVarArray(int n) throws IloException
IloModeler
public IloIntVar[] boolVarArray(int n, java.lang.String[] name) throws IloException
IloModeler
public IloIntVar[] boolVarArray(IloColumnArray cols) throws IloException
IloModeler
public IloIntVar[] boolVarArray(IloColumnArray cols, java.lang.String[] name) throws IloException
IloModeler
public IloObjective minimize(IloNumExpr expr, java.lang.String name) throws IloException
IloModeler
public IloObjective maximize(IloNumExpr expr, java.lang.String name) throws IloException
IloModeler
public IloObjective objective(IloObjectiveSense sense, IloNumExpr expr, java.lang.String name) throws IloException
IloModeler
public IloObjective minimize() throws IloException
IloModeler
public IloObjective maximize() throws IloException
IloModeler
public IloObjective objective(IloObjectiveSense sense) throws IloException
IloModeler
public IloObjective minimize(java.lang.String name) throws IloException
IloModeler
public IloObjective maximize(java.lang.String name) throws IloException
IloModeler
public IloObjective objective(IloObjectiveSense sense, java.lang.String name) throws IloException
IloModeler
public IloObjective minimize(IloNumExpr expr) throws IloException
IloModeler
public IloObjective maximize(IloNumExpr expr) throws IloException
IloModeler
public IloObjective objective(IloObjectiveSense sense, IloNumExpr expr) throws IloException
IloModeler
public IloObjective addMinimize(IloNumExpr expr, java.lang.String name) throws IloException
IloModeler
public IloObjective addMaximize(IloNumExpr expr, java.lang.String name) throws IloException
IloModeler
public IloObjective addObjective(IloObjectiveSense sense, IloNumExpr expr, java.lang.String name) throws IloException
IloModeler
public IloObjective addMinimize() throws IloException
IloModeler
public IloObjective addMaximize() throws IloException
IloModeler
public IloObjective addObjective(IloObjectiveSense sense) throws IloException
IloModeler
public IloObjective addMinimize(java.lang.String name) throws IloException
IloModeler
public IloObjective addMaximize(java.lang.String name) throws IloException
IloModeler
public IloObjective addObjective(IloObjectiveSense sense, java.lang.String name) throws IloException
IloModeler
public IloObjective addMinimize(IloNumExpr expr) throws IloException
IloModeler
public IloObjective addMaximize(IloNumExpr expr) throws IloException
IloModeler
public IloObjective addObjective(IloObjectiveSense sense, IloNumExpr expr) throws IloException
IloModeler
public IloLinearNumExpr linearNumExpr() throws IloException
IloModeler
public IloLinearNumExpr linearNumExpr(double val) throws IloException
IloModeler
public IloLinearNumExpr scalProd(double[] vals, IloNumVar[] vars) throws IloException
IloModeler
public IloLinearNumExpr scalProd(IloNumVar[] vars, double[] vals) throws IloException
IloModeler
public IloLinearNumExpr scalProd(double[] vals, IloNumVar[] vars, int start, int num) throws IloException
IloModeler
public IloLinearNumExpr scalProd(IloNumVar[] vars, double[] vals, int start, int num) throws IloException
IloModeler
public IloLinearNumExpr scalProd(int[] vals, IloNumVar[] vars) throws IloException
IloModeler
public IloLinearNumExpr scalProd(IloNumVar[] vars, int[] vals) throws IloException
IloModeler
public IloLinearNumExpr scalProd(int[] vals, IloNumVar[] vars, int start, int num) throws IloException
IloModeler
public IloLinearNumExpr scalProd(IloNumVar[] vars, int[] vals, int start, int num) throws IloException
IloModeler
public IloLinearIntExpr linearIntExpr() throws IloException
IloModeler
public IloLinearIntExpr linearIntExpr(int val) throws IloException
IloModeler
public IloLinearIntExpr scalProd(int[] vals, IloIntVar[] vars) throws IloException
IloModeler
public IloLinearIntExpr scalProd(IloIntVar[] vars, int[] vals) throws IloException
IloModeler
public IloLinearIntExpr scalProd(int[] vals, IloIntVar[] vars, int start, int num) throws IloException
IloModeler
public IloLinearIntExpr scalProd(IloIntVar[] vars, int[] vals, int start, int num) throws IloException
IloModeler
public IloNumExpr piecewiseLinear(IloNumExpr base, double[] points, double[] slopes, double a, double fa) throws IloException
IloModeler
public IloNumExpr piecewiseLinear(IloNumExpr base, double[] points, int startPoints, int num, double[] slopes, int startSlopes, double a, double fa) throws IloException
IloModeler
public IloNumExpr negative(IloNumExpr e) throws IloException
IloModeler
public IloNumExpr sum(IloNumExpr e, double v) throws IloException
IloModeler
public IloNumExpr sum(IloNumExpr e1, IloNumExpr e2) throws IloException
IloModeler
public IloNumExpr sum(double v, IloNumExpr e1) throws IloException
IloModeler
public IloNumExpr sum(IloNumExpr[] expr, int start, int num) throws IloException
IloModeler
public IloNumExpr sum(IloNumExpr[] expr) throws IloException
IloModeler
public IloNumExpr sum(IloNumExpr expr1, IloNumExpr expr2, IloNumExpr expr3) throws IloException
IloModeler
public IloNumExpr sum(IloNumExpr expr1, IloNumExpr expr2, IloNumExpr expr3, IloNumExpr expr4) throws IloException
IloModeler
public IloNumExpr sum(IloNumExpr expr1, IloNumExpr expr2, IloNumExpr expr3, IloNumExpr expr4, IloNumExpr expr5) throws IloException
IloModeler
public IloNumExpr sum(IloNumExpr expr1, IloNumExpr expr2, IloNumExpr expr3, IloNumExpr expr4, IloNumExpr expr5, IloNumExpr expr6) throws IloException
IloModeler
public IloNumExpr sum(IloNumExpr expr1, IloNumExpr expr2, IloNumExpr expr3, IloNumExpr expr4, IloNumExpr expr5, IloNumExpr expr6, IloNumExpr expr7) throws IloException
IloModeler
public IloNumExpr sum(IloNumExpr expr1, IloNumExpr expr2, IloNumExpr expr3, IloNumExpr expr4, IloNumExpr expr5, IloNumExpr expr6, IloNumExpr expr7, IloNumExpr expr8) throws IloException
IloModeler
public IloNumExpr diff(IloNumExpr e, double v) throws IloException
IloModeler
public IloNumExpr diff(IloNumExpr e1, IloNumExpr e2) throws IloException
IloModeler
public IloNumExpr diff(double v, IloNumExpr e1) throws IloException
IloModeler
public IloNumExpr prod(IloNumExpr e, double v) throws IloException
IloModeler
public IloNumExpr prod(IloNumExpr e1, IloNumExpr e2) throws IloException
IloModeler
public IloNumExpr prod(double v, IloNumExpr e1) throws IloException
IloModeler
public IloNumExpr square(IloNumExpr e) throws IloException
IloModeler
public IloNumExpr constant(double x) throws IloException
IloModeler
public IloIntExpr negative(IloIntExpr e) throws IloException
IloModeler
public IloIntExpr sum(IloIntExpr e, int v) throws IloException
IloModeler
public IloIntExpr sum(int v, IloIntExpr e1) throws IloException
IloModeler
public IloIntExpr sum(IloIntExpr expr1, IloIntExpr expr2) throws IloException
IloModeler
public IloIntExpr sum(IloIntExpr expr1, IloIntExpr expr2, IloIntExpr expr3) throws IloException
IloModeler
public IloIntExpr sum(IloIntExpr expr1, IloIntExpr expr2, IloIntExpr expr3, IloIntExpr expr4) throws IloException
IloModeler
public IloIntExpr sum(IloIntExpr expr1, IloIntExpr expr2, IloIntExpr expr3, IloIntExpr expr4, IloIntExpr expr5) throws IloException
IloModeler
public IloIntExpr sum(IloIntExpr expr1, IloIntExpr expr2, IloIntExpr expr3, IloIntExpr expr4, IloIntExpr expr5, IloIntExpr expr6) throws IloException
IloModeler
public IloIntExpr sum(IloIntExpr expr1, IloIntExpr expr2, IloIntExpr expr3, IloIntExpr expr4, IloIntExpr expr5, IloIntExpr expr6, IloIntExpr expr7) throws IloException
IloModeler
public IloIntExpr sum(IloIntExpr expr1, IloIntExpr expr2, IloIntExpr expr3, IloIntExpr expr4, IloIntExpr expr5, IloIntExpr expr6, IloIntExpr expr7, IloIntExpr expr8) throws IloException
IloModeler
public IloIntExpr sum(IloIntExpr[] expr, int start, int num) throws IloException
IloModeler
public IloIntExpr sum(IloIntExpr[] expr) throws IloException
IloModeler
public IloIntExpr diff(IloIntExpr e, int v) throws IloException
IloModeler
public IloIntExpr diff(IloIntExpr e1, IloIntExpr e2) throws IloException
IloModeler
public IloIntExpr diff(int v, IloIntExpr e1) throws IloException
IloModeler
public IloIntExpr prod(IloIntExpr e, int v) throws IloException
IloModeler
public IloIntExpr prod(IloIntExpr e1, IloIntExpr e2) throws IloException
IloModeler
public IloIntExpr prod(int v, IloIntExpr e1) throws IloException
IloModeler
public IloIntExpr square(IloIntExpr e) throws IloException
IloModeler
public IloIntExpr constant(int x) throws IloException
IloModeler
public void addToExpr(IloObjective obj, IloNumExpr expr) throws IloException
IloMPModeler
public void setLinearCoef(IloObjective obj, double val, IloNumVar var) throws IloException
IloMPModeler
public void setLinearCoef(IloObjective obj, IloNumVar var, double val) throws IloException
IloMPModeler
public void setLinearCoefs(IloObjective obj, double[] val, IloNumVar[] var) throws IloException
IloMPModeler
public void setLinearCoefs(IloObjective obj, IloNumVar[] var, double[] val) throws IloException
IloMPModeler
public void setLinearCoefs(IloObjective obj, double[] val, IloNumVar[] var, int start, int num) throws IloException
IloMPModeler
public void setLinearCoefs(IloObjective obj, IloNumVar[] var, double[] val, int start, int num) throws IloException
IloMPModeler
public IloSemiContVar semiContVar(double lb, double ub, IloNumVarType type, java.lang.String name) throws IloException
IloMPModeler
public IloSemiContVar semiContVar(double lb, double ub, IloNumVarType type) throws IloException
IloMPModeler
public IloSemiContVar semiContVar(IloColumn column, double lb, double ub, IloNumVarType type, java.lang.String name) throws IloException
IloMPModeler
public IloSemiContVar semiContVar(IloColumn column, double lb, double ub, IloNumVarType type) throws IloException
IloMPModeler
public IloSemiContVar[] semiContVarArray(int n, double lb, double ub, IloNumVarType type) throws IloException
IloMPModeler
public IloSemiContVar[] semiContVarArray(int n, double[] lb, double[] ub, IloNumVarType[] type) throws IloException
IloMPModeler
public IloSemiContVar[] semiContVarArray(int n, double lb, double ub, IloNumVarType type, java.lang.String[] name) throws IloException
IloMPModeler
public IloSemiContVar[] semiContVarArray(int n, double[] lb, double[] ub, IloNumVarType[] type, java.lang.String[] name) throws IloException
IloMPModeler
public IloSemiContVar[] semiContVarArray(IloColumnArray cols, double lb, double ub, IloNumVarType type) throws IloException
IloMPModeler
public IloSemiContVar[] semiContVarArray(IloColumnArray cols, double[] lb, double[] ub, IloNumVarType[] type) throws IloException
IloMPModeler
public IloSemiContVar[] semiContVarArray(IloColumnArray cols, double lb, double ub, IloNumVarType type, java.lang.String[] name) throws IloException
IloMPModeler
public IloSemiContVar[] semiContVarArray(IloColumnArray cols, double[] lb, double[] ub, IloNumVarType[] type, java.lang.String[] name) throws IloException
IloMPModeler
public IloConversion conversion(IloNumVar var, IloNumVarType type, java.lang.String name) throws IloException
IloMPModeler
public IloConversion conversion(IloNumVar var, IloNumVarType type) throws IloException
IloMPModeler
public IloConversion conversion(IloNumVar[] ilovar, IloNumVarType type, java.lang.String name) throws IloException
IloMPModeler
public IloConversion conversion(IloNumVar[] ilovar, IloNumVarType type) throws IloException
IloMPModeler
public IloConversion conversion(IloNumVar[] ilovar, IloNumVarType[] type, java.lang.String name) throws IloException
IloMPModeler
public IloConversion conversion(IloNumVar[] ilovar, IloNumVarType[] type) throws IloException
IloMPModeler
public IloLPMatrix addLPMatrix(java.lang.String name) throws IloException
IloMPModeler
public IloLPMatrix addLPMatrix() throws IloException
IloMPModeler
public IloLPMatrix LPMatrix(java.lang.String name) throws IloException
IloMPModeler
public IloLPMatrix LPMatrix() throws IloException
IloMPModeler
public IloRange addRange(double lb, IloNumExpr expr, double ub, java.lang.String name) throws IloException
IloMPModeler
public IloRange addRange(double lb, IloNumExpr expr, double ub) throws IloException
IloMPModeler
public IloRange addRange(double lb, double ub, java.lang.String name) throws IloException
IloMPModeler
public IloRange addRange(double lb, double ub) throws IloException
IloMPModeler
public IloRange addEq(IloNumExpr e, double v) throws IloException
IloMPModeler
public IloRange addEq(IloNumExpr e, double v, java.lang.String name) throws IloException
IloMPModeler
public IloRange addEq(IloNumExpr e1, IloNumExpr e2) throws IloException
IloMPModeler
public IloRange addEq(IloNumExpr e1, IloNumExpr e2, java.lang.String name) throws IloException
IloMPModeler
public IloRange addEq(double v, IloNumExpr e) throws IloException
IloMPModeler
public IloRange addEq(double v, IloNumExpr e, java.lang.String name) throws IloException
IloMPModeler
public IloRange addGe(IloNumExpr e, double v) throws IloException
IloMPModeler
public IloRange addGe(IloNumExpr e, double v, java.lang.String name) throws IloException
IloMPModeler
public IloRange addGe(IloNumExpr e1, IloNumExpr e2) throws IloException
IloMPModeler
public IloRange addGe(IloNumExpr e1, IloNumExpr e2, java.lang.String name) throws IloException
IloMPModeler
public IloRange addGe(double v, IloNumExpr e) throws IloException
IloMPModeler
public IloRange addGe(double v, IloNumExpr e, java.lang.String name) throws IloException
IloMPModeler
public IloRange addLe(IloNumExpr e, double v) throws IloException
IloMPModeler
public IloRange addLe(IloNumExpr e, double v, java.lang.String name) throws IloException
IloMPModeler
public IloRange addLe(IloNumExpr e1, IloNumExpr e2) throws IloException
IloMPModeler
public IloRange addLe(IloNumExpr e1, IloNumExpr e2, java.lang.String name) throws IloException
IloMPModeler
public IloRange addLe(double v, IloNumExpr e) throws IloException
IloMPModeler
public IloRange addLe(double v, IloNumExpr e, java.lang.String name) throws IloException
IloMPModeler
public IloRange range(double lb, IloNumExpr expr, double ub, java.lang.String name) throws IloException
IloMPModeler
public IloRange range(double lb, IloNumExpr expr, double ub) throws IloException
IloMPModeler
public IloRange range(double lb, double ub, java.lang.String name) throws IloException
IloMPModeler
public IloRange range(double lb, double ub) throws IloException
IloMPModeler
public IloRange eq(IloNumExpr e, double v) throws IloException
IloMPModeler
public IloRange eq(IloNumExpr e, double v, java.lang.String name) throws IloException
IloMPModeler
public IloRange eq(IloNumExpr e1, IloNumExpr e2) throws IloException
IloMPModeler
public IloRange eq(IloNumExpr e1, IloNumExpr e2, java.lang.String name) throws IloException
IloMPModeler
public IloRange eq(double v, IloNumExpr e) throws IloException
IloMPModeler
public IloRange eq(double v, IloNumExpr e, java.lang.String name) throws IloException
IloMPModeler
public IloRange ge(IloNumExpr e, double v) throws IloException
IloMPModeler
public IloRange ge(IloNumExpr e, double v, java.lang.String name) throws IloException
IloMPModeler
public IloRange ge(IloNumExpr e1, IloNumExpr e2) throws IloException
IloMPModeler
public IloRange ge(IloNumExpr e1, IloNumExpr e2, java.lang.String name) throws IloException
IloMPModeler
public IloRange ge(double v, IloNumExpr e) throws IloException
IloMPModeler
public IloRange ge(double v, IloNumExpr e, java.lang.String name) throws IloException
IloMPModeler
public IloRange le(IloNumExpr e, double v) throws IloException
IloMPModeler
public IloRange le(IloNumExpr e, double v, java.lang.String name) throws IloException
IloMPModeler
public IloRange le(IloNumExpr e1, IloNumExpr e2) throws IloException
IloMPModeler
public IloRange le(IloNumExpr e1, IloNumExpr e2, java.lang.String name) throws IloException
IloMPModeler
public IloRange le(double v, IloNumExpr e) throws IloException
IloMPModeler
public IloRange le(double v, IloNumExpr e, java.lang.String name) throws IloException
IloMPModeler
public void addToExpr(IloRange obj, IloNumExpr expr) throws IloException
IloMPModeler
public void setLinearCoef(IloRange obj, double val, IloNumVar var) throws IloException
IloMPModeler
public void setLinearCoef(IloRange obj, IloNumVar var, double val) throws IloException
IloMPModeler
public void setLinearCoefs(IloRange obj, double[] val, IloNumVar[] var) throws IloException
IloMPModeler
public void setLinearCoefs(IloRange obj, IloNumVar[] var, double[] val) throws IloException
IloMPModeler
public void setLinearCoefs(IloRange obj, double[] val, IloNumVar[] var, int start, int num) throws IloException
IloMPModeler
public void setLinearCoefs(IloRange obj, IloNumVar[] var, double[] val, int start, int num) throws IloException
IloMPModeler
public IloSOS1 addSOS1(IloNumVar[] var, double[] val) throws IloException
IloMPModeler
public IloSOS1 addSOS1(IloNumVar[] var, double[] val, int start, int num) throws IloException
IloMPModeler
public IloSOS1 addSOS1(IloNumVar[] var, double[] val, java.lang.String name) throws IloException
IloMPModeler
public IloSOS1 addSOS1(IloNumVar[] var, double[] val, int start, int num, java.lang.String name) throws IloException
IloMPModeler
public IloSOS1 SOS1(IloNumVar[] var, double[] val) throws IloException
IloMPModeler
public IloSOS1 SOS1(IloNumVar[] var, double[] val, int start, int num) throws IloException
IloMPModeler
public IloSOS1 SOS1(IloNumVar[] var, double[] val, java.lang.String name) throws IloException
IloMPModeler
public IloSOS1 SOS1(IloNumVar[] var, double[] val, int start, int num, java.lang.String name) throws IloException
IloMPModeler
public IloSOS2 addSOS2(IloNumVar[] var, double[] val) throws IloException
IloMPModeler
public IloSOS2 addSOS2(IloNumVar[] var, double[] val, int start, int num) throws IloException
IloMPModeler
public IloSOS2 addSOS2(IloNumVar[] var, double[] val, java.lang.String name) throws IloException
IloMPModeler
public IloSOS2 addSOS2(IloNumVar[] var, double[] val, int start, int num, java.lang.String name) throws IloException
IloMPModeler
public IloSOS2 SOS2(IloNumVar[] var, double[] val) throws IloException
IloMPModeler
public IloSOS2 SOS2(IloNumVar[] var, double[] val, int start, int num) throws IloException
IloMPModeler
public IloSOS2 SOS2(IloNumVar[] var, double[] val, java.lang.String name) throws IloException
IloMPModeler
public IloSOS2 SOS2(IloNumVar[] var, double[] val, int start, int num, java.lang.String name) throws IloException
IloMPModeler
public void delete(IloCopyable obj) throws IloException
obj
- extractable to removepublic IloColumn column(IloRange rng, double val) throws IloException
IloMPModeler
public IloColumnArray columnArray(IloRange rng, double[] val) throws IloException
IloMPModeler
public IloColumnArray columnArray(IloRange rng, double[] val, int start, int num) throws IloException
IloMPModeler
public IloColumn column(IloObjective obj, double val) throws IloException
IloMPModeler
public IloColumnArray columnArray(IloObjective obj, double[] val) throws IloException
IloMPModeler
public IloColumnArray columnArray(IloObjective obj, double[] val, int start, int num) throws IloException
IloMPModeler
public IloColumn column(IloLPMatrix lp) throws IloException
IloMPModeler
public IloColumn column(IloLPMatrix lp, int[] ind, double[] val) throws IloException
IloMPModeler
public IloColumn column(IloLPMatrix lp, int[] ind, double[] val, int start, int num) throws IloException
IloMPModeler
public IloColumnArray columnArray(IloLPMatrix lp, int num, int[][] ind, double[][] val) throws IloException
IloMPModeler
public IloColumnArray columnArray(IloLPMatrix lp, int num) throws IloException
IloMPModeler
public void delete(IloCopyable[] obj) throws IloException
IloMPModeler
public void delete(IloCopyable[] obj, int beg, int num) throws IloException
obj
- the array containing extractables to be removed.start
- the index the of first extractable in obj
to be removed.num
- the number of extractables in obj
to be
removed.public IloRange addCut(IloRange rng) throws IloException
rng
as a cut to the invoking IloCplex
object. The cut is not extracted as the range in a model, but is
copied only when invoking method addCut
. Thus,
rng
may be deleted or modified after addCut
has
been called, and the change will not be notified to the invoking
IloCplex
object.
When columns are deleted from the extracted model, all cuts are
deleted as well and need to be re-extracted if they should be considered.
Cuts are not part of the root problem, but are considered on an
as-needed basis. A solution computed by IloCplex
is
guaranteed to satisfy all cuts.
rng
- The range constraints to add as a cut.public IloRange[] addCuts(IloRange[] rng) throws IloException
IloRange[]
array rng
as a cut to the
invoking IloCplex
object. Cuts are not extracted as the ranges in a model, but are
copied only when invoking method addCut
. Thus,
rng
may be deleted or modified after addCut
has
been called, and the change will not be notified to the invoking
IloCplex
object.
When columns are deleted from the extracted model, all cuts are
deleted as well and need to be re-extracted if they should be considered.
Cuts are not part of the root problem, but are considered on an
as-needed basis. A solution computed by IloCplex
is
guaranteed to satisfy all cuts.
rng
- An IloRange[]
array range constraints to add as
a cut.IloRange[]
array range constraints to add as
a cut.public IloRange[] addCuts(IloRange[] rng, int start, int num) throws IloException
rng
as a user cut to the invoking IloCplex
object. User cuts are not extracted as the ranges in a model, but are
copied only when invoking the method addCut
. Thus,
rng
may be deleted or modified after addCut
has
been called and the change will not be notified to the invoking
IloCplex
object.
When columns are deleted from the extracted
model, all user cuts are deleted as well and need to be re-extracted if
they should be considered. User cuts are not part of the root problem,
but are considered on an as-needed basis. A solution computed by
IloCplex
is guaranteed to satisfy all user cuts.
rng
- An IloRange[]
array containing constraints to add
as a cut.start
- The index of the first constraint in rng
to be
added as a cut.num
- The number of constraints in rng
to be added as a
cut.rng
, start
and num
of
constraints to be added as cuts.public void clearCuts() throws IloException
IloCplex
object
with the methods addCut
and addCuts
.public void exportModel(java.lang.String name) throws IloException
IloCplex
a model to a file.
The file format is determined by the extension of the filename. The
following extensions are recognized:
getName()
returns null
(that is no name has been assigned by the user to the
variable/range), then IloCplex
uses default names when
writing a model or in the optimization log. These names are
IloXj for variables and IloCi where i and
j are internal indices of IloCplex
.name
- The name of the file to which the model is written.
The extension of the filename determines the format in
which to write the model file.public void importModel(java.lang.String name) throws IloException
IloCplex
model.
The format of the file is determined by the extension of the
filename. The following extensions are recognized:
IloCplex
model is first
cleaned out and then new modeling objects, as required by the input file,
are added to it.
In particular, one IloObjective
object and one
IloLPMatrix
object is always added to the
IloCplex
model. The IloLPMatrix
object will
contain all the constraints of the imported model. IloSOS1
and IloSOS2
objects are added as needed.name
- The name of the file from which the model is read.
The extension of the filename determines the format in
which to read the model file.public void clearModel() throws IloException
IloCplex
model. All modeling
objects are removed from the IloCplex
models, leaving behind
an empty model.public int getNcols()
IloCplex
model. Note that this does not necessarily correspond to the number of
variables in the IloCplex
model, as some mapping of modeling
objects may neccessitate the introduction of added matrix columns.IloCplex
model.public int getNrows()
IloCplex
model. Note that this does not necessarily correspond to the number of
constraints in the IloCplex
model, as some mapping of
modeling objects may require the introduction of added matrix rows.IloCplex
model.public int getNSOS1()
SOS
s of type 1, in the
IloCplex
model.SOS
s of type 1 in the
IloCplex
model.public int getNSOS2()
SOS
s of type 2, in the
IloCplex
model.SOS
s of type 2 in the
IloCplex
model.public int getNSOSs()
SOS
s of both types, 1 and 2, in the
IloCplex
model.SOS
s in the IloCplex
model.public int getNNZs()
IloCplex
model.IloCplex
model.public int getNintVars()
IloCplex
object.IloCplex
object.public int getNbinVars()
IloCplex
object.IloCplex
object.public int getNsemiContVars()
IloCplex
object.IloCplex
object.public int getNsemiIntVars()
IloCplex
object.IloCplex
model.public boolean isMIP()
true
if the IloCplex
model is a MIP.true
if the IloCplex
model is a MIP.public boolean isQP()
true
if the IloCplex
model is a QP.true
if the IloCplex
model is a QP.public java.util.Iterator LPMatrixIterator()
IloLPMatrix
objects in the
IloCplex
model.IloLPMatrix
objects in the
IloCplex
model.public java.util.Iterator rangeIterator()
IloRange
objects in the
IloCplex
model.
This iterator only accounts for the IloRange
objects directly
added to the IloCplex
model and not the objects that may be in
an IloLPMatrix
and have been added indirectly.IloRange
objects in the
IloCplex
model.public java.util.Iterator conversionIterator()
IloConversion
objects in the
IloCplex
model.IloConversion
objects in the
IloCplex
model.public java.util.Iterator SOS1iterator()
IloSOS1
objects in the
IloCplex
model.IloSOS1
objects in the
IloCplex
model.public java.util.Iterator SOS2iterator()
IloSOS2
objects in the
IloCplex
model.IloSOS2
objects in the
IloCplex
model.public IloObjective getObjective()
IloObjective
object of the
IloCplex
model, or null
if no
IloObject
object
is currently in the IloCplex
model.IloObjective
object in the IloCplex
model, or null
if there is no IloObjective
public IloCplex.Status getStatus() throws IloException
IloCplex
model.IloCplex
model.IloCplex.Status
public void setParam(IloCplex.IntParam which, int val) throws IloException
val
.which
- The identifier to set for the integer parameter.val
- The new value for the integer parameter.IloException
, or
one of its derived classes, is thrown.public int getParam(IloCplex.IntParam which) throws IloException
which
- The identifier to be queried for the integer parameter.IloException
, or
one of its derived classes is thrown.public int getMin(IloCplex.IntParam which) throws IloException
which
- The identifier of the integer parameter to be queried.IloException
, or
one of its derived classes is thrown.public int getMax(IloCplex.IntParam which) throws IloException
which
- The identifier of the integer parameter to be queried.IloException
, or
one of its derived classes is thrown.public int getDefault(IloCplex.IntParam which) throws IloException
which
- The identifier of the integer parameter to be queried.IloException
, or
one of its derived classes is thrown.public void setParam(IloCplex.BooleanParam which, boolean val) throws IloException
val
.which
- The identifier to set for the boolean parameter.val
- The new value for the boolean parameter.IloException
, or
one of its derived classes is thrown.public boolean getParam(IloCplex.BooleanParam which) throws IloException
which
- The identifier of the boolean parameter to be queried.IloException
, or
one of its derived classes is thrown.public boolean getDefault(IloCplex.BooleanParam which) throws IloException
which
- The identifier of the boolean parameter to be queried.IloException
, or
one of its derived classes is thrown.public void setParam(IloCplex.DoubleParam which, double val) throws IloException
val
.which
- The identifier of the double parameter to be set.val
- The new value for the double parameterIloException
, or
one of its derived classes is thrown.public double getParam(IloCplex.DoubleParam which) throws IloException
which
- The identifier to be queried for the double parameter.IloException
, or
one of its derived classes is thrown.public double getMin(IloCplex.DoubleParam which) throws IloException
which
- The identifier of the double parameter to be queried.IloException
, or
one of its derived classes is thrown.public double getMax(IloCplex.DoubleParam which) throws IloException
which
- The identifier of the double parameter to be queried.IloException
, or
one of its derived classes is thrown.public double getDefault(IloCplex.DoubleParam which) throws IloException
which
- The identifier of the double parameter to be queried.IloException
, or
one of its derived classes is thrown.public void setParam(IloCplex.StringParam which, java.lang.String val) throws IloException
val
.which
- The identifier of the string parameter to set.val
- The new value for the string parameter.IloException
, or
one of its derived classes is thrown.public java.lang.String getParam(IloCplex.StringParam which) throws IloException
which
- The identifier of the string parameter to be queried.IloException
, or
one of its derived classes is thrown.public java.lang.String getDefault(IloCplex.StringParam which) throws IloException
which
- The identifier of the string parameter to be queried.IloException
, or
one of its derived classes is thrown.public void setDefaults() throws IloException
IloException
, or
one of its derived classes is thrown.public java.lang.String getVersion() throws IloException
IloException
, or
one of its derived classes is thrown.public void setDeleteMode(IloCplex.DeleteMode mode)
IloCplex
object to
mode
.mode
- The delete mode to be set, FixBasis
or
LeaveBasis
.public IloCplex.DeleteMode getDeleteMode()
IloCplex
.
object.public IloCplex.CplexStatus getCplexStatus() throws IloException
IloException
, or
one of its derived classes is thrown.public IloCplex.CplexStatus getCplexSubStatus() throws IloException
getCplexSubStatus
returns a
0
in the event of a normal termination.
CPLEX algorithmic statuses give
you more information about the optimizer's status. See the CPLEX
Reference Manual for a list of possible return codes.IloException
, or
one of its derived classes is thrown.public int getAlgorithm() throws IloException
public int getSubAlgorithm() throws IloException
public double getObjValue() throws IloException
IloException
, or
one of its derived classes is thrown.public double getBestObjValue() throws IloException
IloException
, or
one of its derived classes is thrown.public double getCutoff() throws IloException
IloException
, or
one of its derived classes is thrown.public double[] getValues(IloLPMatrix matrix) throws IloCplex.UnknownObjectException, IloException
matrix
- The LP matrix for which to query the solution values.
This LP matrix must be in the IloCplex
model.x
is the array returned by this method,
x[j]
will be the solution value for the variable
corresponding to column j
of the
IloLPMatrix
matrix.IloCplex
.IloException
, or
one of its derived classes is thrown.public double[] getValues(IloLPMatrix matrix, int begin, int num) throws IloException
matrix
- The LP matrix for which to query the solution values.
This LP matrix must be in the IloCplex
model.begin
- The index of the first column for which to query the
solution value.num
- The number of columns for which to query the
solution value.x
is the array returned by this method, x[j]
will be
the solution value for the variable corresponding to column
j+begin
of the IloLPMatrix
matrix.public double getValue(IloNumVar ivar) throws IloCplex.UnknownObjectException, IloException
ivar
- The variable for which to query the solution value.
This variable must be in the IloCplex
model.ivar
.ivar
is unknown in
IloCplex
.IloException
, or
one of its derived classes is thrown.public double[] getValues(IloNumVar[] ivar) throws IloCplex.UnknownObjectException, IloException
ivar
- An array containing the
variables for which to query the solution value.
These variables must be in the IloCplex
model.ivar
.
If x
is the array returned by this method,
x[j]
will be the solution value for the variable
var[j]
.ivar
is unknown in
IloCplex
.public double[] getValues(IloNumVar[] ivar, int first, int num) throws IloCplex.UnknownObjectException, IloException
ivar
- An array containing the variables for which to query
the solution value. These variables must be in the
IloCplex
model.first
- The index of the first variable in ivar
for
which to query the solution value.num
- The number of variables in ivar
for which
to query the solution value.x
is the array returned by this method,
x[j]
will be the solution value for the
variable var[j+first]
.ivar
is unknown in
IloCplex
.public double[] getReducedCosts(IloLPMatrix matrix) throws IloCplex.UnknownObjectException, IloException
matrix
- The LP matrix for which to query the reduced costs.
This LP matrix must be in the IloCplex
model.dj
is the array returned by this method, dj[j]
will
be the reduced cost for the variable corresponding to column
j
of the IloLPMatrix
matrix.matrix
is unknown in
IloCplex
.public double[] getReducedCosts(IloLPMatrix matrix, int begin, int num) throws IloException
matrix
- The LP matrix for which to query the reduced costs.
This LP matrix must be in the IloCplex
model.begin
- The index of the first column for which to query the
reduced cost.num
- The number of columns for which to query the
reduced cost.dj
is the array returned by this method,
dj[j]
will be the reduced cost
for the variable corresponding to column j+begin
of the IloLPMatrix
matrix.public double getReducedCost(IloNumVar ivar) throws IloCplex.UnknownObjectException, IloException
var
- The variable for which to query the reduced cost.
This variable must be in the IloCplex
model.var
.var
is unknown in
IloCplex
.public double[] getReducedCosts(IloNumVar[] ivar) throws IloCplex.UnknownObjectException, IloException
var
- The array of variables for which to query the reduced cost.
This array must be in the IloCplex
model.ivar
. If
dj
is the
array returned by this method, dj[j]
will be the
reduced cost for the variable corresponding to variable
var[j]
.var
is unknown in
IloCplex
.public double[] getReducedCosts(IloNumVar[] ivar, int begin, int num) throws IloCplex.UnknownObjectException, IloException
ivar
- An array containing the variables for which to query
the reduced cost. These variables must be in the
IloCplex
model.first
- The index of the first variable in ivar
for
which to query the reduced cost.num
- The number of variables in ivar
for which to
query the reduced cost.dj
is the array returned by this method,
dj[j]
will be the reduced cost for the variable
corresponding to variable var[j+first]
.ivar
is unknown in
IloCplex
.public double[] getDuals(IloLPMatrix matrix) throws IloCplex.UnknownObjectException, IloException
matrix
- The LP matrix for which to query the dual solution
values. This LP matrix must be in the
IloCplex
model.pi
is the array returned by this method,
pi[i]
will be the dual solution value for the range
constraint corresponding to row i
of the
IloLPMatrix
matrix.matrix
is unknown in
IloCplex
.public double[] getDuals(IloLPMatrix matrix, int first, int num) throws IloException
matrix
- The LP matrix for which to query the dual solution
values. This LP matrix must be in the
IloCplex
model.first
- The index of the first row for which to query the
dual solution value.num
- The number of rows for which to query the
dual solution value.pi
is the array returned by this method,
pi[i]
will be the dual solution value for the range
constraint corresponding to row i+first
of the
IloLPMatrix
matrix.public double getDual(IloRange irng) throws IloCplex.UnknownObjectException, IloException
irng
- The range constraint for which to query the dual
solution value. This range constraint must be in the
IloCplex
model, either directly or though
an IloLPMatrix
object.irng
is unknown in
IloCplex
.public double[] getDuals(IloRange[] irng) throws IloCplex.UnknownObjectException, IloException
irng
- The array of range constraints for which to query the dual
solution values. This range constraints must be in the
IloCplex
model, either directly or though
an IloLPMatrix
object.irng
. If pi
is the array returned by
this method, pi[j]
will be the dual solution value
for the range constraint irng[j]
.irng
is unknown in
IloCplex
.public double[] getDuals(IloRange[] irng, int first, int num) throws IloCplex.UnknownObjectException, IloException
irng
- An array containing the range constraints for which to
query the dual solution values. These range constraints
must be in the IloCplex
model, either
directly or
though an IloLPMatrix
object.first
- The index of the first range constraint in
irng
for
which to query the dual solution value.num
- The number of range constraints in irng
for which to
query the dual solution value.pi
is the array returned by this method,
pi[j]
will be the dual solution value for the range
constraint var[j+first]
.irng
is unknown in
IloCplex
.public double[] getSlacks(IloLPMatrix matrix) throws IloCplex.UnknownObjectException, IloException
matrix
- The LP matrix for which to query the slack
values. This LP matrix must be in the
IloCplex
model.s
is the array returned by this method,
s[i]
will be the slack value for the range
constraint corresponding to row i
of the
IloLPMatrix
matrix.matrix
is unknown in
IloCplex
.public double[] getSlacks(IloLPMatrix matrix, int first, int num) throws IloException
matrix
- The LP matrix for which to query the slack
values. This LP matrix must be in the
IloCplex
model.first
- The index of the first rows for which to query the
slack value.num
- The number of rows for which to query the
slack value.s
is
the array returned by this method, s[i]
will be the
slack value for the range constraint corresponding to row
i+first
of the IloLPMatrix
matrix.public double getSlack(IloRange rng) throws IloCplex.UnknownObjectException, IloException
rng
- The range constraint for which to query the slack
value. This range constraint must be in the
IloCplex
model, either directly or though
an IloLPMatrix
object.rng
is unknown in
IloCplex
.public double[] getSlacks(IloRange[] irng) throws IloCplex.UnknownObjectException, IloException
irng
- The range constraints for which to query the slack
values. These range constraints must be in the
IloCplex
model, either directly or though
an IloLPMatrix
object.irng
.
If s
is the array returned by this method,
s[j]
will be the slack value for the range
constraint irng[j]
.irng
is unknown in
IloCplex
.public double[] getSlacks(IloRange[] irng, int first, int num) throws IloCplex.UnknownObjectException, IloException
irng
- An array containing the range constraints for which to
query the slack values. These range constraints
must be in the IloCplex
model, either
directly or through an IloLPMatrix
object.first
- The index of the first range constraint in
irng
for which to query the slack value.num
- The number of range constraints in irng
for
which to query the slack value.s
is the array returned by this method,
s[j]
will be the slack value for the range
constraint irng[j+first]
.irng
is unknown in
IloCplex
.public double getValue(IloNumExpr expr) throws IloException
expr
takes for the current solution.expr
- The expression for which to evaluate the current solution.expr
takes for the current
solution.public double[] getAX(IloLPMatrix matrix) throws IloCplex.UnknownObjectException, IloException
matrix
- The LP matrix for which to query the row activity
values. This LP matrix must be in the
IloCplex
model.matrix
.
If ax
is the array returned by this method,
ax[i]
will be the row activity value for the range
constraint corresponding to row i
of the
IloLPMatrix
matrix.matrix
is unknown in
IloCplex
.public double[] getAX(IloLPMatrix matrix, int first, int num) throws IloException
matrix
- The LP matrix for which to query the row activity
values. This LP matrix must be in the
IloCplex
model.first
- The index of the first row for which to query the
row activity value.num
- The number of rows for which to query the
row activity value.ax
is the
array returned by this method, ax[i]
will be the
row activity value for the range constraint corresponding to row
i+first
of the IloLPMatrix
matrix.public double getAX(IloRange rng) throws IloCplex.UnknownObjectException, IloException
rng
- The range constraint for which to query the row
activity value. This range constraint must be in the
IloCplex
model, either directly or though
an IloLPMatrix
object.matrix
is unknown in
IloCplex
.public double[] getAX(IloRange[] irng) throws IloCplex.UnknownObjectException, IloException
irng
- The range constraints for which to query the row
activity values. These range constraints must be in
the IloCplex
model, either directly or
though an IloLPMatrix
object.irng
. If s
is the array returned by
this method, s[j]
will be the row activity value
for the range constraint irng[j]
.matrix
is unknown in
IloCplex
.public double[] getAX(IloRange[] irng, int first, int num) throws IloCplex.UnknownObjectException, IloException
irng
- An array containing the range constraints for which to
query the row activity values. These range constraints
must be in the IloCplex
model, either
directly or through an IloLPMatrix
object.first
- The index of the first range constraint in
irng
for which to query the row activity
value.num
- The number of range constraints in irng
for
which to query the row activity value.s
is the array returned by this method,
s[j]
will be the row activity value for the range
constraint irng[j+first]
.matrix
is unknown in
IloCplex
.public IloCplex.BasisStatus getBasisStatus(IloNumVar var) throws IloException
var
. This function only
succeeds if a basic solution is available in the invoking
IloCplex
optimizer.var
- The variable for which to return the basis status.var
.public IloCplex.BasisStatus[] getBasisStatuses(IloNumVar[] var) throws IloException
var
.
This function only succeeds if a basic solution is available in the
invoking IloCplex
optimizer.var
- The array of variables for which to return basis
statuses.var
. If
b
is the returned array, b[j]
will be the basis status for variable var[j]
.public IloCplex.BasisStatus[] getBasisStatuses(IloNumVar[] var, int start, int num) throws IloException
var
.
This function only succeeds if a basic solution is available in the
invoking IloCplex
optimizer.var
- An array containing the variables for which to return
basis statuses.start
- The index of the first variable in array
var
for which
to return the basis status.num
- The number of variables in array var
for
which to return the basis status.var
. If
b
is the returned array, b[j]
will be the basis status for variable
var[j+start]
.public IloCplex.BasisStatus getBasisStatus(IloRange rng) throws IloException
rng
. This function
only succeeds if a basic solution is available in the invoking
IloCplex
optimizer.rng
- Constraint for which to return basis status.rng
.public IloCplex.BasisStatus[] getBasisStatuses(IloRange[] rng) throws IloException
rng
.
This function only succeeds if a basic solution is available in the
invoking IloCplex
optimizer.rng
- The array of constraints for which to return basis
statuses.rng
. If
b
is the returned array, b[i]
will be the basis status for constraints
rng[i]
.public IloCplex.BasisStatus[] getBasisStatuses(IloRange[] rng, int start, int num) throws IloException
rng
.
This function only succeeds if a basic solution is available in the
invoking IloCplex
optimizer.rng
- An array containing the constraints for which to return
basis statuses.start
- The index of the first constraint in array
rng
for which to return the basis status.num
- The number of constraint in array rng
for
which to return the basis status.rng
. If
b
is the returned array, b[i]
will be the basis status for constraint
rng[i+start]
.public void setBasisStatuses(IloNumVar[] var, IloCplex.BasisStatus[] cstat, IloRange[] rng, IloCplex.BasisStatus[] rstat) throws IloException
var
- The array of variables for which to set basis statuses.cstat
- The new basis statuses for variables in var
.rng
- The array of range constraints for which to set basis
statuses.rstat
- The new basis statuses for ranges in rng
.public void setBasisStatuses(IloNumVar[] var, IloCplex.BasisStatus[] cstat, int cstart, int cnum, IloRange[] rng, IloCplex.BasisStatus[] rstat, int rstart, int rnum) throws IloException
var
- The array of variables for which to set basis statuses.cstat
- The corresponding new array of basis statuses for
variables in var
.cstart
- The first element in var
and cstat
to consider.cnum
- The number of column statuses to set.rng
- array of range constraints for which to set basis
statuses.rstat
- The new basis statuses for ranges in rng
.rstart
- The first element in var
and rstat
to consider.rnum
- The number of range statuses to set.public void setVectors(double[] x, double[] dj, IloNumVar[] var, double[] slack, double[] pi, IloRange[] rng) throws IloException
solve()
. Zero can be passed for any of
the parameters. However if x
or dj
are not
0
, var
must not be 0
. Similarly, if
slack
or pi
are not 0
,
rng
must not be 0
.
For all variables given in var
, x[i]
specifies
the starting value for variable var[i]
. Similarly,
dj[i]
specifies the starting reduced cost for variable
var[i]
. For all ranges specified in rng
,
slack[i]
specifies the starting slack value for
rng[i]
. Similarly, pi[i]
specifies the starting
dual value for rng[i]
.
This information is exploited at the next call to solve, to construct a starting point for the algorithm. In particular, if the extracted model is an LP, and the root algorithm is Dual, Primal, BarrierDual, or BarrierPrimal, the information is used to construct a starting basis for the Simplex method.
If the extracted model is a MIP, only x
values can be used,
and a value must be specified for all variables of type
ILOINT
. If the provided values are compatible with an
integer feasible solution, that solution becomes the incumbent for the
next search, otherwise the starting information is ignored. Parameter
MIPStart
must be turned on (set to IloTrue
)
for the starting point to take effect.
x
- The array of starting values for var
.dj
- The array of starting reduced costs for var
.var
- The array of variables at the starting point.slack
- The array of starting slack values for rng
.pi
- The array of starting dual values for rng
.rng
- The array of ranges of values for var
.public void setVectors(double[] x, double[] dj, IloNumVar[] var, int vstart, int vnum, double[] slack, double[] pi, IloRange[] rng, int rstart, int rnum) throws IloException
solve()
. Zero can be passed for any of
the parameters. However if x
or dj
are not
0
, var
must not be 0
. Similarly, if
slack
or pi
are not 0
,
rng
must not be 0
.
For all variables given in var
, x[i]
specifies
the starting value for variable var[i]
. Similarly,
dj[i]
specifies the starting reduced cost for variable
var[i]
. For all ranges specified in rng
,
slack[i]
specifies the starting slack value for
rng[i]
. Similarly, pi[i]
specifies the starting
dual value for rng[i]
.
This information is exploited at the next call to solve, to construct a starting point for the algorithm. In particular, if the extracted model is an LP, and the root algorithm is Dual, Primal, BarrierDual, or BarrierPrimal, the information is used to construct a starting basis for the Simplex method.
If the extracted model is a MIP, only x
values can be used,
and a value must be specified for all variables of type
ILOINT
. If the provided values are compatible with an
integer feasible solution, that solution becomes the incumbent for the
next search, otherwise the starting information is ignored. Parameter
MIPStart
must be turned on (set to IloTrue
)
for the starting point to take effect.
x
- The array of starting values for var
.dj
- The array of starting reduced costs for var
.vstart
- The index number of the first variable in the array
var
to set as a starting point.vnum
- The number of variables in the array var
to be
set as starting points.var
- The array of variables at the starting point.slack
- The array of starting slack values for rng
.pi
- The array of starting dual values for rng
.rng
- The array of ranges of values for var
.rstart
- The index of the first range value in rng
which
corresponds to the first variable in var
.rnum
- The number of range values in rng
which
correspond to the variables in var
.public IloCplex.IIS getIIS() throws IloException
public void getBoundSA(double[] lblower, double[] lbupper, double[] ublower, double[] ubupper, IloLPMatrix matrix) throws IloException
lblower
- lblower[i]
will contain the lowest value
that the lower bound of variable matrix[i]
can be set to without affecting the optimality of the
basis. If this information is not required
null
may be passed. Otherwise, the length
of the array must be at least the number of columns in
the matrix.lbupper
- lbupper[i]
will contain the highest value
that the
lower bound of variable matrix[i]
can be set
to without affecting the optimality of the basis.
If this information is not required null
may be passed. Otherwise, the length of the array must
be at least the number of columns in the matrix.ublower
- ublower[i]
will contain the lowest value
that the
upper bound of variable matrix[i]
can be set
to without affecting the optimality of the basis. If
this information is not required null
may
be passed. Otherwise, the length of the array must be
at least the number of columns in the matrix.ubupper
- ubupper[i]
will contain the highest value
that the
upper bound of variable matrix[i]
can be set
to without affecting the optimality of the basis. If
this information is not required null
may
be passed. Otherwise, the length of the array must be
at least the number of columns in the matrix.matrix
- The LP matrix of the columns for which the bound
sensitivity analysis information is to be computed.public void getBoundSA(double[] lblower, double[] lbupper, double[] ublower, double[] ubupper, IloLPMatrix matrix, int start, int num) throws IloException
j >= start
the SA value for the variable
corresponding to column matrix[j]
will be returned in
{lb/ub}{lower/upper}[j-start]
.lblower
- lblower[i]
will contain the lowest value
that the
lower bound of variable matrix[i]
can be set
to without affecting the optimality of the basis. If
this information is not required, null
may
be passed. Otherwise, the length of the array must be at
least num
.lbupper
- lbupper[i]
will contain the highest value
that the
lower bound of variable matrix[i]
can be set
to without affecting the optimality of the basis. If
this information is not required null
may
be passed. Otherwise, the length of the array must be at
least num
.ublower
- ublower[i]
will contain the lowest value
that the
upper bound of variable matrix[i]
can be set
to without affecting the optimality of the basis. If
this information is not required null
may
be passed. Otherwise, the length of the array must be
at least num
.ubupper
- ubupper[i]
will contain the highest value
that the
upper bound of variable matrix[i]
can be set
to without affecting the optimality of the basis. If
this information is not required null
may
be passed. Otherwise, the length of the array must be
at least num
.matrix
- The column matrix for which bound sensitivity
analysis information is returned.start
- The index of the first column of the matrix for which
bound sensitivity analysis information is returned.num
- The number of columns in matrix for which to return
bound sensitivity analysis information.public void getBoundSA(double[] lblower, double[] lbupper, double[] ublower, double[] ubupper, IloNumVar[] var) throws IloException
lblower
- lblower[i]
will contain the lowest value of
the
lower bound to which variable var[i]
can
be set without affecting the optimality of the basis.
If this information is not required null
may be passed. Otherwise, the array must have at least
the same length as var
.lbupper
- lbupper[i]
will contain the highest value
of the
lower bound to which variable var[i]
can be
set without affecting the optimality of the basis. If
this information is not required null
may
be passed. Otherwise, the array must have at least the
same length as var
.ublower
- ublower[i
] will contain the lowest value
of the
upper bound to which variable var[i]
can
be set without affecting the optimality of the basis.
If this information is not required null
may be passed. Otherwise, the array must have at least
the same length as var
.ubupper
- ubupper[i]
will contain the highest value of
the upper bound to which variable var[i]
can be set without affecting the optimality of the
basis. If this information is not required
null
may be passed. Otherwise, the array
must have at least the same length as var
.var
- An array containing the variables for which to return
bound sensitivity analysis information.public void getBoundSA(double[] lblower, double[] lbupper, double[] ublower, double[] ubupper, IloNumVar[] var, int start, int num) throws IloException
lblower
- lblower[i]
will contain the lowest value
of the
lower bound to which variable var[i+start]
can be set without affecting the optimality of the
basis. If this information is not required
null
may be passed. Otherwise, the array
must have at least length num
.lbupper
- lbupper[i]
will contain the highest value
of the
lower bound to which variable var[i+start]
can be set without affecting the optimality of the
basis. If this information is not required
null
may be passed. Otherwise, the array
must have at least length num
.ublower
- ublower[i]
will contain the lowest value
of of
the upper bound to which variable
var[i+start]
can be set without affecting
the optimality of the basis. If this information is
not required null
may be passed. Otherwise,
the array must have at least length num
.ubupper
- ubupper[i]
will contain the highest value
of the
upper bound to which variable var[i+start]
can be set without affecting the optimality of the
basis. If this information is not required
null
may be passed. Otherwise, the array
must have at least length num
.var
- An array containing the variables for which
bound sensitivity analysis information is returned.start
- The index of first variable in var
for
which to return
bound sensitivity analysis information.num
- The number of variables in var
for which
to return
bound sensitivity analysis information.public void getObjSA(double[] lower, double[] upper, IloLPMatrix matrix) throws IloException
lower
- lower[i]
is the lowest value to which the
objective coefficient of the variable corresponding to
column i
of the matrix can be set without
affecting the optimality of the basis. If this
information is not required null
may be
passed. Otherwise, the array must have a length at least
equal to the number of columns in the matrix.upper
- upper[i]
is the highest value to which the
objective coefficient of the variable corresponding to
of column i
of matrix that can be set
without affecting the optimality of the basis. If this
information is not required null
may be
passed. Otherwise, the array must have a length at least
equal to the number of columns in the matrix.matrix
- The LP matrix which contains the column for which
objective sensitivity analysis information will be
returned.public void getObjSA(double[] lower, double[] upper, IloLPMatrix matrix, int start, int num) throws IloException
lower
- lower[i]
will contain the lowest value to
which the objective coefficient of the variable
corresponding to column i+start
of the
matrix that can be set, without affecting the optimality
of the basis. If this information is not required
null
may be passed. Otherwise, the array
must have at least length num
.upper
- upper[i]
will contain the highest value to
which the objective coefficient of the variable
corresponding to column i+start
of the
matrix that can be set, without affecting the
optimality of the basis. If this information is not
required null
may be passed. Otherwise,
the array must have at least length num
.matrix
- The LP matrix which contains the column for which
objective sensitivity analysis information is to be
returned.start
- The index of the first variable in var
for
which to return objective sensitivity analysis
information.num
- The number of variables in var
for which to
return objective sensitivity analysis information.public void getObjSA(double[] lower, double[] upper, IloNumVar[] var) throws IloException
lower
- lower[i]
will contain the lowest value to
which the objective coefficient of the variable
var[i]
can be set without affecting the
optimality of the basis. If this information is not
required null
may be passed. Otherwise, the
array must have a length at least equal to the length
of the array var
.upper
- upper[i]
will contain the highest value to
which the objective coefficient of the variable
var[i]
can be set without affecting the
optimality of the basis. If this information is not
required null
may be passed. Otherwise,
the array must have a length at least equal to the length
of the array var
.var
- An array containing the variables for which objective
sensitivity analysis information will be returned.public void getObjSA(double[] lower, double[] upper, IloNumVar[] var, int start, int num) throws IloException
lower
- lower[i]
will contain the lowest value to
which the objective coefficient of the variable
var[i+start]
can be set without affecting
the optimality of the basis. If this information is not
required, null
may be passed. Otherwise,
the array must have at least length num
.upper
- uppper[i]
will contain the highest value to
which the objective coefficient of the variable
var[i+start]
can be set without affecting
the optimality of the basis. If this information is not
required, null
may be passed. Otherwise,
the array must have at least length num
.var
- An array containing the variables for which objective
sensitivity analysis information will be returned.start
- The index of first variable in var for which objective
sensitivity analysis information will be returned.num
- The number of variables in var for which objective
sensitivity analysis information will be returned.public void getRangeSA(double[] lblower, double[] lbupper, double[] ublower, double[] ubupper, IloRange[] rng) throws IloException
lblower
- lblower[i]
will contain the lowest value to
which the lower bound of range rng[i]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as rng
.lbupper
- lbupper[i]
will contain the highest value to
which the lower bound of range rng[i]
can
be set without affecting the optimality of the basis.
If this information is not required, null may be passed.
Otherwise, the array must have at least the same length
as rng
.ublower
- ublower[i]
will contain the lowest value to
which the upper bound of range rng[i]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as rng
.ubupper
- ubupper[i]
will contain the highest value to
which the upper bound of range rng[i]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as rng
.rng
- The IloRange
for which the sensitivity
analysis is being computed.public void getRangeSA(double[] lblower, double[] lbupper, double[] ublower, double[] ubupper, IloRange[] rng, int start, int num) throws IloException
lblower
- lblower[i]
will contain the lowest value to
which the lower bound of range
rng[i+start]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as rng
.lbupper
- lbupper[i]
will contain the highest value to
which the lower bound of range
rng[i+start]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as rng
.ublower
- ublower[i]
will contain the lowest value to
which the upper bound of range
rng[i+start]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as rng
.ubupper
- ubupper[i]
will contain the highest value to
which the upper bound of range
rng[i+start]
can
be set to without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as rng
.start
- The index of the first element in rng
.rng
- The range of constraint bounds for which the sensitivity
analysis information is required.num
- The number of elements in rng
for which the
sensitivity information is required.public void getRangeSA(double[] lblower, double[] lbupper, double[] ublower, double[] ubupper, IloLPMatrix lp, int start, int num) throws IloException
num
rows of the LP starting with row start
in LP constraint matrix lp
.lblower
- lblower[i]
will contain the lowest value to
which the lower bound of range rng[i]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as num
.lbupper
- lbupper[i]
will contain the highest value to
which the lower bound of range rng[i]
can
be set without affecting the optimality of the basis. If
this information is not required, null
may
be passed. Otherwise, the array must have at least the
same length as num
.ublower
- ublower[i]
will contain the lowest value the
upper bound of range rng[i]
can be set to
without affecting the optimality of the basis. If this
information is not required null may be passed.
Otherwise, the array must have at least the same length
as num
.ubupper
- ubupper[i]
will contain the highest value to
which the upper bound of range rng[i]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as num
.lp
- The LP constraint matrix for which sensitivity analysis
information is to be computed.start
- The first row in the matrix lp
for which
sensitivity analysis information is to be computed.num
- The number of rows in the matrix lp
for
which sensitivity analysis information is to be computed.public void getRangeSA(double[] lblower, double[] lbupper, double[] ublower, double[] ubupper, IloLPMatrix lp) throws IloException
lp
constraint bounds.lblower
- lblower[i]
will contain the lowest value to
which the lower bound of range rng[i]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as the number of rows in lp
.lbupper
- lbupper[i]
will contain the highest value to
which the lower bound of range rng[i]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as the number of rows in lp
.ublower
- lblower[i]
will contain the lowest value to
which the upper bound of range rng[i]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as the number of rows in lp
.ubupper
- lbupper[i]
will contain the highest value to
which the upper bound of range rng[i]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as the number of rows in lp
.lp
- The constraint matrix for which sensitivity analysis
information is to be computed.public void getRHSSA(double[] lower, double[] upper, IloRange[] rng) throws IloException
getRangeSA
, since both bounds are moved independently.lower
- lower[i]
will contain the lowest value to
which the lower bound of range rng[i]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as rng
.upper
- upper[i]
will contain the highest value to
which the lower bound of range rng[i]
can
be set without affecting the optimality of the basis.
If this information is not required, null may be passed.
Otherwise, the array must have at least the same length
as rng
.rng
- The IloRange
for which the sensitivity
analysis is being computed.public void getRHSSA(double[] lower, double[] upper, IloRange[] rng, int start, int num) throws IloException
getRangeSA
, since both bounds are moved independently.lower
- lower[i]
will contain the lowest value to
which the lower bound of range
rng[i+start]
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as num
.upper
- upper[i]
will contain the highest value to
which the lower bound of range
rng[i+start]
can
be set without affecting the optimality of the basis.
If this information is not required, null may be passed.
Otherwise, the array must have at least the same length
as num
.rng
- The IloRange
for which the sensitivity
analysis is being computed.start
- The first element of rng
for which the
sensitivity analysis is being computed.num
- The number of elements in rng
for which to
compute the sensitivity analysis values.public void getRHSSA(double[] lower, double[] upper, IloLPMatrix lp) throws IloException
getRangeSA
, since both bounds are moved independently.lower
- lower[i]
will contain the lowest value to
which the lower bound of the range corresponding to row
i
of lp
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as rng
.upper
- upper[i]
will contain the highest value to
which the lower bound of the range corresponding to row
i
of lp
can
be set without affecting the optimality of the basis.
If this information is not required, null may be passed.
Otherwise, the array must have at least the same length
as rng
.lp
- The matrix with RHS values for which sensitivity
analysis is to be computed.public void getRHSSA(double[] lower, double[] upper, IloLPMatrix lp, int start, int num) throws IloException
getRangeSA
, since both bounds are moved independently.lower
- lower[i]
will contain the lowest value to
which the lower bound of the range corresponding to row
i+start
of lp
can
be set without affecting the optimality of the basis.
If this information is not required, null
may be passed. Otherwise, the array must have at least
the same length as rng
.upper
- upper[i]
will contain the highest value to
which the lower bound of the range corresponding to row
i+start
of lp
can
be set without affecting the optimality of the basis.
If this information is not required, null may be passed.
Otherwise, the array must have at least the same length
as rng
.lp
- The matrix with RHS values for which sensitivity
analysis is being computed.start
- The first element of lp
for which the
sensitivity analysis is being computed.num
- The number of elements in lp
for which to
sensitivity analysis is being computed.public IloCplex.Quality getQuality(IloCplex.QualityType which) throws IloException
IloCplex.Quality
object that contains the information
for the requested quality measure.which
- The IloCplex.QualityType
which should be
computed.IloCplex.Quality
object for the requested quality
measure.IloCplex.Quality
,
IloCplex.QualityType
public java.io.OutputStream out()
IloCplex
object.
This stream is used by IloCplex
for printing logged
information. It can be set with method setOut()
.IloCplex
object.setOut(java.io.OutputStream)
public java.io.OutputStream warning()
IloCplex
object. This stream is used by IloCplex
for printing
warnings. It can be set with method setWarning()
.IloCplex
object.setWarning(java.io.OutputStream)
public void setOut(java.io.OutputStream s)
IloCplex
object. After this call, all logging output will be output via the new
stream. Passing null
as the new output stream will turn off
the output.s
- The new default output stream.public void setWarning(java.io.OutputStream s)
IloCplex
object.
After this call, all warnings will be output via the new stream. Passing
null
as the new output stream will turn off warnings.s
- The new warnings output stream.public boolean solve() throws IloException
IloCplex
model.public boolean solveRelaxed() throws IloException
IloCplex
model.public boolean solveFixed() throws IloException
IloCplex
model.
The fixed model is generated from a MIP problem, and a solution to it, by
fixing all integer variables to their solution values.public boolean solveZeroedQP() throws IloException
IloCplex
model.
The LP part of a QP is generated from a QP by setting the matrix of
quadratic terms Q
to 0
.public int getNiterations()
public int getNbarrierIterations()
public int getNphaseOneIterations()
public int getNcrossDExch()
public int getNcrossDPush()
public int getNcrossPExch()
public int getNcrossPPush()
public int getNdualSuperbasics()
public int getNprimalSuperbasics()
public int getNcliques()
public int getNcovers()
public int getNnodes()
public int getNnodesLeft()
public int getIncumbentNode()
public void setPriority(IloNumVar var, int pri) throws IloException
var
.
Branching priorities must be positive integers or 0
to reset
the default priority.var
- The variable for which to set a priority value.pri
- The priority value to set for variable var
.public void setPriorities(IloNumVar[] var, int[] pri) throws IloException
0
to reset
the default priority.var
- The array of variable for which to set priority values.pri
- The array priority value to use. The priority for
variable var[i]
will be set to
pri[i]
.public void setPriorities(IloNumVar[] var, int[] pri, int start, int num) throws IloException
0
to reset
the default priority.var
- The array containing the variable for which to set priority
values.pri
- The array containing the priority value to use. The
priority for variable var[i]
will be set to
pri[i]
, for
i = start, ..., start+num-1
.start
- The first elements in var
and
pri
to consider.num
- The number of elements in var
and
pri
to consider.public void setDirection(IloNumVar var, IloCplex.BranchDirection dir) throws IloException
var
- The variable for which to set the branching direction.dir
- The branching direction to set for variable
var
.IloCplex.BranchDirection
public void setDirections(IloNumVar[] var, IloCplex.BranchDirection[] brdir) throws IloException
var
- The array of variables for which to set the branching
directions.brdir
- The array of branching directions to use. The branching
direction of variable var[i]
will be set
to brdir[i]
.IloCplex.BranchDirection
public void setDirections(IloNumVar[] var, IloCplex.BranchDirection[] brdir, int start, int num) throws IloException
var
- The array containing the variables for which to set
the branching directions.brdir
- The array containing the branching directions to use.
The branching direction of variable
var[i]
will be set to brdir[i]
for
i = start, ..., start+num-1
.start
- The first elements in var
and
brdir
to consider.num
- The number of elements in var
and
brdir
to consider.IloCplex.BranchDirection
public void delPriority(IloNumVar var) throws IloException
var
.var
- The variable from which the priority order assignment is to be
removed.public void delPriorities(IloNumVar[] var) throws IloException
var
.var
- The variable array from which the priority order assignments
are to be removed.public void delPriorities(IloNumVar[] var, int start, int num) throws IloException
num
variables in the array var
, starting with variable
start
.var
- The variable array from which the priority order assignment is
to be removed.num
- The number of variables in var
from which the
priority order assignments are to be removed.start
- The index of the first variable in var
from
which the priority order assignment is to be removed.public void delDirection(IloNumVar var) throws IloException
var
.var
- The variable array from which the branching direction
assignments are to be removed.public void delDirections(IloNumVar[] var) throws IloException
var
.var
- The variable array from which the branching direction
assignments are to be removed.public void delDirections(IloNumVar[] var, int start, int num) throws IloException
num
variables in the array var
, starting with variable
start
.var
- The variable array from which the branching direction
assignments are to be removed.num
- The number of variables in var
from which the
branching direction assignments are to be removed.start
- The index of the first variable in var
from
which the branching direction assignment is to be removed.public int getPriority(IloNumVar var) throws IloException
var
- The variable for which to query the branch priority.var
. A value of
0
indicates the IloCplex
default.public IloCplex.BranchDirection getDirection(IloNumVar var) throws IloException
var
with the method
setDirection()
or setDirections()
.var
- The variable for which to return the assigned branch direction.public int[] getPriorities(IloNumVar[] var) throws IloException
var
- The array of variables for which to query the branch
priorities.var
.
A value of 0
indicates the IloCplex
default.public IloCplex.BranchDirection[] getDirections(IloNumVar[] var) throws IloException
var
- The array of variables for which to query the branch
directions.var
.public int[] getPriorities(IloNumVar[] var, int start, int num) throws IloException
var
- The array containing the variables for which to query the
branch priorities.start
- The index of the first variable in var
for
which to query the branch priority.num
- The number of variables in var
for which to
query the branch priorities.0
indicates the IloCplex
default.public IloCplex.BranchDirection[] getDirections(IloNumVar[] var, int start, int num) throws IloException
var
- The array containing the variables for which to query the
branch directions.start
- The index of the first variable in var
for
which to query the branch directions.num
- The number of variables in var
for which to
query the branch directions.public void writeOrder(java.lang.String name) throws IloException
name
- The name of the file in which write priority order is written.public void use(IloCplex.Callback cb) throws IloException
main()
that
is called regularly during the optimization of the IloCplex
model. This object must be implemented as a class derived from an
IloCplex.Callback
class, and define the abstract method
main()
.
IloCplex
algorithms call
a callback, and each of these callbacks is related to a seperate callback
type. The callback type is determined by the base class used for
implementing callbacks, which is IloCplex.Callback
.cb
- The callback to be used from now on. The type of the callback
object being passed determines which callback is being set.
If a callback of the same type has previously been set, the new
callback will replace the old one.IloCplex.Callback
public void clearCallbacks() throws IloException
public void end()
IloCplex
license.
When done using a Concert model created with and IloCplex
object and the
IloCplex
object itself, the method end()
should be
called to release the license. After a call of method end()
the invoking IloCplex
object and
all objects that have been created with it (such as variables and
constraints) may no longer be used. Doing so will cause
exception IloCplex.CplexEndedException
to be thrown.
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |