Cbc
2.9.9

Go to the source code of this file.
Functions  
Getting and setting model data  
Note that problem access and modification methods, such as getColLower and setColLower, are not valid after calling Cbc_solve(). Therefore it is not recommended to reuse a Cbc_Model object for multiple solves. A workaround is to call Cbc_clone() before solving.  
COINLIBAPI void COINLINKAGE  Cbc_loadProblem (Cbc_Model *model, const int numcols, const int numrows, const CoinBigIndex *start, const int *index, const double *value, const double *collb, const double *colub, const double *obj, const double *rowlb, const double *rowub) 
Loads a problem (the constraints on the rows are given by lower and upper bounds). More...  
COINLIBAPI void COINLINKAGE  Cbc_addSOS (Cbc_Model *model, int numRows, const int *rowStarts, const int *colIndices, const double *weights, const int type) 
Add SOS constraints to the model using roworder matrix. More...  
Message handling. Call backs are handled by ONE function  
COINLIBAPI void COINLINKAGE  Cbc_registerCallBack (Cbc_Model *model, cbc_callback userCallBack) 
Pass in Callback function. More...  
Constructors and destructor  
This is a "C" interface to Cbc. The user does not need to know structure of Cbc_Model.  
COINLIBAPI Cbc_Model *  COINLINKAGE 
Default Cbc_Model constructor. More...  
COINLIBAPI const char *COINLINKAGE  Cbc_getVersion (void) 
Current version of Cbc. More...  
COINLIBAPI const char* COINLINKAGE Cbc_getVersion  (  void  ) 
Current version of Cbc.
COINLIBAPI void COINLINKAGE Cbc_loadProblem  (  Cbc_Model *  model, 
const int  numcols,  
const int  numrows,  
const CoinBigIndex *  start,  
const int *  index,  
const double *  value,  
const double *  collb,  
const double *  colub,  
const double *  obj,  
const double *  rowlb,  
const double *  rowub  
) 
Loads a problem (the constraints on the rows are given by lower and upper bounds).
If a pointer is NULL then the following values are the default:
colub
: all columns have upper bound infinity collb
: all columns have lower bound 0 rowub
: all rows have upper bound infinity rowlb
: all rows have lower bound infinity obj
: all variables have 0 objective coefficient The constraint matrix is given in standard compressed sparse column (without gaps).
start[i]
stores the starting index of the ith column index[k]
stores the row index of the kth nonzero element value[k]
stores the coefficient of the kth nonzero element COINLIBAPI void COINLINKAGE Cbc_addSOS  (  Cbc_Model *  model, 
int  numRows,  
const int *  rowStarts,  
const int *  colIndices,  
const double *  weights,  
const int  type  
) 
Add SOS constraints to the model using roworder matrix.
COINLIBAPI void COINLINKAGE Cbc_registerCallBack  (  Cbc_Model *  model, 
cbc_callback  userCallBack  
) 
Pass in Callback function.
Message numbers up to 1000000 are Clp, Coin ones have 1000000 added
COINLIBAPI int COINLINKAGE 
Default Cbc_Model constructor.
Secondary status of problem 1 unset (status_ will also be 1) 0 search completed with solution 1 linear relaxation not feasible (or worse than cutoff) 2 stopped on gap 3 stopped on nodes 4 stopped on time 5 stopped on user event 6 stopped on solutions 7 linear relaxation unbounded 8 stopped on iteration limit.
Final status of problem Some of these can be found out by is......
Print the solution.
Number of nodes explored in B&B tree.
Best known bound on the optimal objective value.
Objective value of best feasible solution.
Best feasible solution vector.
"row" solution This is the vector A*x, where A is the constraint matrix and x is the current solution.
Is primal infeasiblity proven (for initialSolve) ?
Is optimality proven (for initialSolve) ?
Are there numerical difficulties (for initialSolve) ?
Solution limit reached?
Time limit reached?
Node limit reached?
Was continuous solution unbounded?
Is infeasiblity proven (or none better than cutoff)?
Is optimality proven?
Are there a numerical difficulties?
Number of iterations.
Just check solution (for external use)  sets sum of infeasibilities etc.
Number of primal infeasibilities.
Sum of primal infeasibilities.
Unset Callback function.
Set parameter "name" to value "value".
Return a copy of this model.
Print the model.
Set this variable to be integer.
Set this variable to be continuous.
Determine whether the ith variable is integer restricted.
Set the upper bound of a single variable.
Variable upper bounds.
Set the lower bound of a single variable.
Variable lower bounds.
Set the objective coefficient of a single variable.
Objective vector.
Set the upper bound of a single constraint.
Constraint upper bounds.
Set the lower bound of a single constraint.
Constraint lower bounds.
Direction of optimization (1  minimize, 1  maximize, 0  ignore)
Number of variables in the model.
Number of constraints in the model.
Set the name of a row.
Set the name of a column.
Fill in first maxLength bytes of name array with a column name.
Fill in first maxLength bytes of name array with a row name.
Maximum lenght of a row or column name.
Coefficient vector of constraint matrix.
"Row index" vector of constraint matrix
"Column start" vector of constraint matrix.
Number of nonzero elements in constraint matrix.
Sets problem name.
Fills in array with problem name.
Provide an initial feasible solution to accelerate branchandbound Note that feasibility of the solution is not verified.
Write an mps file from the given filename.
Read an mps file from the given filename.
Cbc_Model Destructor.
array
must be a nullterminated string.
Same format as Cbc_loadProblem()
Note that this translates directly to using "name value" as a commandline argument to Cbc.
functions 1 before branchAndBound 0 finished  check isProvenOptimal or isProvenInfeasible to see if solution found (or check value of best solution) 1 stopped  on maxnodes, maxsols, maxtime 2 difficulties so run was abandoned (5 event user programmed event occurred)
Definition at line 34 of file Cbc_C_Interface.h.