Ignore:
Timestamp:
Nov 9, 2009 6:33:07 PM (10 years ago)
Author:
EdwinStraver
Message:

Changed formatting using AStyle -A4 -p

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/sandbox/Cbc/src/Cbc_C_Interface.h

    r1271 r1286  
    1414
    1515#ifdef __cplusplus
    16   extern "C"{
     16extern "C" {
    1717#endif
    18  
    19   /**@name Constructors and destructor
    20      These do not have an exact analogue in C++.
    21      The user does not need to know structure of Cbc_Model.
    22      
    23      For all functions outside this group there is an exact C++
    24      analogue created by taking the first parameter out, removing the Cbc_
    25      from name and applying the method to an object of type ClpSimplex.
    26   */
    27   /*@{*/
    28 
    29   /** Version */
    30   COINLIBAPI double COINLINKAGE Cbc_getVersion()
    31   ;
    32   /** Default Cbc_Model constructor */
    33   COINLIBAPI Cbc_Model * COINLINKAGE
    34   Cbc_newModel()
    35   ;
    36   /** Cbc_Model Destructor */
    37   COINLIBAPI void COINLINKAGE
    38   Cbc_deleteModel(Cbc_Model * model)
    39   ;
    40   /*@}*/
    41 
    42   /**@name Load model - loads some stuff and initializes others */
    43   /*@{*/
    44   /* Loads a problem (the constraints on the
    45       rows are given by lower and upper bounds). If a pointer is NULL then the
    46       following values are the default:
    47       <ul>
    48       <li> <code>colub</code>: all columns have upper bound infinity
    49       <li> <code>collb</code>: all columns have lower bound 0
    50       <li> <code>rowub</code>: all rows have upper bound infinity
    51       <li> <code>rowlb</code>: all rows have lower bound -infinity
    52       <li> <code>obj</code>: all variables have 0 objective coefficient
    53       </ul>
    54 
    55    Just like the other loadProblem() method except that the matrix is
    56    given in a standard column major ordered format (without gaps).
    57 */
    58   COINLIBAPI void COINLINKAGE
    59   Cbc_loadProblem (Cbc_Model * model,  const int numcols, const int numrows,
    60           const CoinBigIndex * start, const int* index,
    61           const double* value,
    62           const double* collb, const double* colub,   
    63           const double* obj,
    64           const double* rowlb, const double* rowub)
    65   ;
    66   /** Read an mps file from the given filename */
    67   COINLIBAPI int COINLINKAGE
    68   Cbc_readMps(Cbc_Model * model,const char *filename)
    69   ;
    70   /** Write an mps file from the given filename */
    71   COINLIBAPI void COINLINKAGE
    72   Cbc_writeMps(Cbc_Model * model,const char *filename)
    73   ;
    74   /** Integer information */
    75   COINLIBAPI char * COINLINKAGE
    76   Cbc_integerInformation(Cbc_Model * model)
    77   ;
    78   /** Copy in integer information */
    79   COINLIBAPI void COINLINKAGE
    80   Cbc_copyInIntegerInformation(Cbc_Model * model,const char * information)
    81   ;
    82   /** Drop integer informations */
    83   COINLIBAPI void COINLINKAGE
    84   Cbc_deleteIntegerInformation(Cbc_Model * model)
    85   ;
    86   /** Resizes rim part of model  */
    87   COINLIBAPI void COINLINKAGE
    88   Cbc_resize (Cbc_Model * model, int newNumberRows, int newNumberColumns)
    89   ;
    90   /** Deletes rows */
    91   COINLIBAPI void COINLINKAGE
    92   Cbc_deleteRows(Cbc_Model * model, int number, const int * which)
    93   ;
    94   /** Add rows */
    95   COINLIBAPI void COINLINKAGE
    96   Cbc_addRows(Cbc_Model * model, const int number, const double * rowLower,
    97          const double * rowUpper,
    98          const int * rowStarts, const int * columns,
    99          const double * elements)
    100          ;
    101 
    102   /** Deletes columns */
    103   COINLIBAPI void COINLINKAGE
    104   Cbc_deleteColumns(Cbc_Model * model, int number, const int * which)
    105   ;
    106   /** Add columns */
    107   COINLIBAPI void COINLINKAGE
    108   Cbc_addColumns(Cbc_Model * model, int number, const double * columnLower,
    109       const double * columnUpper,
    110       const double * objective,
    111       const int * columnStarts, const int * rows,
    112       const double * elements);
    113   /** Drops names - makes lengthnames 0 and names empty */
    114   COINLIBAPI void COINLINKAGE
    115   Cbc_dropNames(Cbc_Model * model)
    116   ;
    117   /** Copies in names */
    118   COINLIBAPI void COINLINKAGE
    119   Cbc_copyNames(Cbc_Model * model, const char * const * rowNamesIn,
    120      const char * const * columnNamesIn)
    121   ;
    122  
    123   /*@}*/
    124   /**@name gets and sets - you will find some synonyms at the end of this file */
    125   /*@{*/
    126   /** Number of rows */
    127   COINLIBAPI int COINLINKAGE
    128   Cbc_numberRows(Cbc_Model * model)
    129   ;
    130   /** Number of columns */
    131   COINLIBAPI int COINLINKAGE
    132   Cbc_numberColumns(Cbc_Model * model)
    133   ;
    134   /** Primal tolerance to use */
    135   COINLIBAPI double COINLINKAGE
    136   Cbc_primalTolerance(Cbc_Model * model)
    137   ;
    138   COINLIBAPI void COINLINKAGE
    139   Cbc_setPrimalTolerance(Cbc_Model * model,  double value)
    140   ;
    141   /** Dual tolerance to use */
    142   COINLIBAPI double COINLINKAGE
    143   Cbc_dualTolerance(Cbc_Model * model)
    144   ;
    145   COINLIBAPI void COINLINKAGE
    146   Cbc_setDualTolerance(Cbc_Model * model,  double value)
    147   ;
    148   /* Integer tolerance to use */
    149   COINLIBAPI double COINLINKAGE
    150   Cbc_integerTolerance(Cbc_Model * model)
    151   ;
    152   COINLIBAPI void COINLINKAGE
    153   Cbc_setIntegerTolerance(Cbc_Model * model,  double value)
    154   ;
    155   /** Dual objective limit */
    156   COINLIBAPI double COINLINKAGE
    157   Cbc_dualObjectiveLimit(Cbc_Model * model)
    158   ;
    159   COINLIBAPI void COINLINKAGE
    160   Cbc_setDualObjectiveLimit(Cbc_Model * model, double value)
    161   ;
    162   /** Objective offset */
    163   COINLIBAPI double COINLINKAGE
    164   Cbc_objectiveOffset(Cbc_Model * model)
    165   ;
    166   COINLIBAPI void COINLINKAGE
    167   Cbc_setObjectiveOffset(Cbc_Model * model, double value)
    168   ;
    169   /** Fills in array with problem name  */
    170   COINLIBAPI void COINLINKAGE
    171   Cbc_problemName(Cbc_Model * model, int maxNumberCharacters, char * array)
    172   ;
    173   /** Sets problem name.  Must have \0 at end.  */
    174   COINLIBAPI int COINLINKAGE
    175   Cbc_setProblemName(Cbc_Model * model, int maxNumberCharacters, char * array)
    176   ;
    177   /** Number of iterations */
    178   COINLIBAPI int COINLINKAGE
    179   Cbc_numberIterations(Cbc_Model * model)
    180   ;
    181   COINLIBAPI void COINLINKAGE
    182   Cbc_setNumberIterations(Cbc_Model * model, int numberIterations)
    183   ;
    184   /** Maximum number of iterations */
    185   COINLIBAPI int COINLINKAGE
    186   Cbc_maximumIterations(Cbc_Model * model)
    187   ;
    188   COINLIBAPI void COINLINKAGE
    189   Cbc_setMaximumIterations(Cbc_Model * model, int value)
    190   ;
    191   /** Maximum number of nodes */
    192   COINLIBAPI int COINLINKAGE
    193   Cbc_maxNumNode(Cbc_Model * model)
    194   ;
    195   COINLIBAPI void COINLINKAGE
    196   Cbc_setMaxNumNode(Cbc_Model * model, int value)
    197   ;
    198   /* Maximum number of solutions */
    199   COINLIBAPI int COINLINKAGE
    200   Cbc_maxNumSol(Cbc_Model * model)
    201   ;
    202   COINLIBAPI void COINLINKAGE
    203   Cbc_setMaxNumSol(Cbc_Model * model, int value)
    204   ;
    205   /** Maximum time in seconds (from when set called) */
    206   COINLIBAPI double COINLINKAGE
    207   Cbc_maximumSeconds(Cbc_Model * model)
    208   ;
    209   COINLIBAPI void COINLINKAGE
    210   Cbc_setMaximumSeconds(Cbc_Model * model, double value)
    211   ;
    212   /** Returns true if hit maximum iterations (or time) */
    213   COINLIBAPI int COINLINKAGE
    214   Cbc_hitMaximumIterations(Cbc_Model * model)
    215   ;
    216   /** Status of problem:
    217       0 - optimal
    218       1 - primal infeasible
    219       2 - dual infeasible
    220       3 - stopped on iterations etc
    221       4 - stopped due to errors
    222   */
    223   COINLIBAPI int COINLINKAGE
    224   Cbc_status(Cbc_Model * model)
    225   ;
    226   /** Set problem status */
    227   COINLIBAPI void COINLINKAGE
    228   Cbc_setProblemStatus(Cbc_Model * model, int problemStatus)
    229   ;
    230   /** Secondary status of problem - may get extended
    231       0 - none
    232       1 - primal infeasible because dual limit reached
    233       2 - scaled problem optimal - unscaled has primal infeasibilities
    234       3 - scaled problem optimal - unscaled has dual infeasibilities
    235       4 - scaled problem optimal - unscaled has both dual and primal infeasibilities
    236   */
    237   COINLIBAPI int COINLINKAGE
    238   Cbc_secondaryStatus(Cbc_Model * model)
    239   ;
    240   COINLIBAPI void COINLINKAGE
    241   Cbc_setSecondaryStatus(Cbc_Model * model, int status)
    242   ;
    243   /** Direction of optimization (1 - minimize, -1 - maximize, 0 - ignore */
    244   COINLIBAPI double COINLINKAGE
    245   Cbc_optimizationDirection(Cbc_Model * model)
    246   ;
    247   COINLIBAPI void COINLINKAGE
    248   Cbc_setOptimizationDirection(Cbc_Model * model, double value)
    249   ;
    250   /** Primal row solution */
    251   COINLIBAPI double * COINLINKAGE
    252   Cbc_primalRowSolution(Cbc_Model * model)
    253   ;
    254   /** Primal column solution */
    255   COINLIBAPI double * COINLINKAGE
    256   Cbc_primalColumnSolution(Cbc_Model * model)
    257   ;
    258   /** Dual row solution */
    259   COINLIBAPI double * COINLINKAGE
    260   Cbc_dualRowSolution(Cbc_Model * model)
    261   ;
    262   /** Reduced costs */
    263   COINLIBAPI double * COINLINKAGE
    264   Cbc_dualColumnSolution(Cbc_Model * model)
    265   ;
    266   /** Row lower */
    267   COINLIBAPI double* COINLINKAGE
    268   Cbc_rowLower(Cbc_Model * model)
    269   ;
    270   /** Row upper  */
    271   COINLIBAPI double* COINLINKAGE
    272   Cbc_rowUpper(Cbc_Model * model)
    273   ;
    274   /** Objective */
    275   COINLIBAPI double * COINLINKAGE
    276   Cbc_objective(Cbc_Model * model)
    277   ;           
    278   /** Column Lower */
    279   COINLIBAPI double * COINLINKAGE
    280   Cbc_columnLower(Cbc_Model * model)
    281   ;
    282   /** Column Upper */
    283   COINLIBAPI double * COINLINKAGE
    284   Cbc_columnUpper(Cbc_Model * model)
    285   ;
    286   /** Number of elements in matrix */
    287   COINLIBAPI int COINLINKAGE
    288   Cbc_getNumElements(Cbc_Model * model)
    289   ;
    290   /** Column starts in matrix */
    291   COINLIBAPI const CoinBigIndex * COINLINKAGE
    292   Cbc_getVectorStarts(Cbc_Model * model)
    293   ;
    294   /** Row indices in matrix */
    295   COINLIBAPI const int * COINLINKAGE
    296   Cbc_getIndices(Cbc_Model * model)
    297   ;
    298   /** Column vector lengths in matrix */
    299   COINLIBAPI const int * COINLINKAGE
    300   Cbc_getVectorLengths(Cbc_Model * model)
    301   ;
    302   /** Element values in matrix */
    303   COINLIBAPI const double * COINLINKAGE
    304   Cbc_getElements(Cbc_Model * model)
    305   ;
    306   /** Objective value */
    307   COINLIBAPI double COINLINKAGE
    308   Cbc_objectiveValue(Cbc_Model * model)
    309   ;
    310   /** Infeasibility/unbounded ray (NULL returned if none/wrong)
    311       Up to user to use delete [] on these arrays.  */
    312   COINLIBAPI double * COINLINKAGE
    313   Cbc_infeasibilityRay(Cbc_Model * model)
    314   ;
    315   COINLIBAPI double * COINLINKAGE
    316   Cbc_unboundedRay(Cbc_Model * model)
    317   ;
    318   /** See if status array exists (partly for OsiClp) */
    319   COINLIBAPI int COINLINKAGE
    320   Cbc_statusExists(Cbc_Model * model)
    321   ;
    322   /** Return address of status array (char[numberRows+numberColumns]) */
    323   COINLIBAPI void  COINLINKAGE
    324   Cbc_getBasisStatus(Cbc_Model * model, int * cstat, int * rstat)
    325   ;
    326   /** Copy in status vector */
    327   COINLIBAPI void COINLINKAGE
    328   Cbc_setBasisStatus(Cbc_Model * model, int * cstat, int * rstat)
    329   ;
    330  
    331   /** User pointer for whatever reason */
    332   COINLIBAPI void COINLINKAGE
    333   Cbc_setUserPointer (Cbc_Model * model, void * pointer)
    334   ;
    335   COINLIBAPI void * COINLINKAGE
    336   Cbc_getUserPointer (Cbc_Model * model)
    337   ;
    338   /*@}*/
    339   /**@name Message handling.  Call backs are handled by ONE function */
    340   /*@{*/
    341   /** Pass in Callback function.
    342    Message numbers up to 1000000 are Clp, Coin ones have 1000000 added */
    343   COINLIBAPI void COINLINKAGE
    344   Cbc_registerCallBack(Cbc_Model * model,
    345                cbc_callback userCallBack)
    346   ;
    347   /** Unset Callback function */
    348   COINLIBAPI void COINLINKAGE
    349   Cbc_clearCallBack(Cbc_Model * model)
    350   ;
    351   /** Amount of print out:
    352       0 - none
    353       1 - just final
    354       2 - just factorizations
    355       3 - as 2 plus a bit more
    356       4 - verbose
    357       above that 8,16,32 etc just for selective debug
    358   */
    359   COINLIBAPI void COINLINKAGE
    360   Cbc_setLogLevel(Cbc_Model * model, int value)
    361   ;
    362   COINLIBAPI int COINLINKAGE
    363   Cbc_logLevel(Cbc_Model * model)
    364   ;
    365   /** length of names (0 means no names0 */
    366   COINLIBAPI int COINLINKAGE
    367   Cbc_lengthNames(Cbc_Model * model)
    368   ;
    369   /** Fill in array (at least lengthNames+1 long) with a row name */
    370   COINLIBAPI void COINLINKAGE
    371   Cbc_rowName(Cbc_Model * model, int iRow, char * name)
    372   ;
    373   /** Fill in array (at least lengthNames+1 long) with a column name */
    374   COINLIBAPI void COINLINKAGE
    375   Cbc_columnName(Cbc_Model * model, int iColumn, char * name)
    376   ;
    377 
    378   /*@}*/
    379 
    380 
    381   /**@name Functions most useful to user */
    382   /*@{*/
    383   /** General solve algorithm which can do presolve.
    384       See  ClpSolve.hpp for options
    385    */
    386   COINLIBAPI int COINLINKAGE
    387   Cbc_initialSolve(Cbc_Model * model)
    388   ;
    389   /* General solve algorithm which can do presolve.
    390      See  CbcModel.hpp for options
    391   */
    392   COINLIBAPI int COINLINKAGE
    393   Cbc_branchAndBound(Cbc_Model * model)
    394   ;
    395   /** Sets or unsets scaling, 0 -off, 1 equilibrium, 2 geometric, 3, auto, 4 dynamic(later) */
    396   COINLIBAPI void COINLINKAGE
    397   Cbc_scaling(Cbc_Model * model, int mode)
    398   ;
    399   /** Gets scalingFlag */
    400   COINLIBAPI int COINLINKAGE
    401   Cbc_scalingFlag(Cbc_Model * model)
    402   ;
    403   /** Crash - at present just aimed at dual, returns
    404       -2 if dual preferred and crash basis created
    405       -1 if dual preferred and all slack basis preferred
    406        0 if basis going in was not all slack
    407        1 if primal preferred and all slack basis preferred
    408        2 if primal preferred and crash basis created.
    409        
    410        if gap between bounds <="gap" variables can be flipped
    411 
    412        If "pivot" is
    413        0 No pivoting (so will just be choice of algorithm)
    414        1 Simple pivoting e.g. gub
    415        2 Mini iterations
    416   */
    417   COINLIBAPI int COINLINKAGE
    418   Cbc_crash(Cbc_Model * model, double gap,int pivot)
    419   ;
    420   /*@}*/
    421 
    422 
    423   /**@name most useful gets and sets */
    424   /*@{*/
    425   /** If problem is primal feasible */
    426   COINLIBAPI int COINLINKAGE
    427   Cbc_primalFeasible(Cbc_Model * model)
    428   ;
    429   /** If problem is dual feasible */
    430   COINLIBAPI int COINLINKAGE
    431   Cbc_dualFeasible(Cbc_Model * model)
    432   ;
    433   /** Dual bound */
    434   COINLIBAPI double COINLINKAGE
    435   Cbc_dualBound(Cbc_Model * model)
    436   ;
    437   COINLIBAPI void COINLINKAGE
    438   Cbc_setDualBound(Cbc_Model * model, double value)
    439   ;
    440   /** Infeasibility cost */
    441   COINLIBAPI double COINLINKAGE
    442   Cbc_infeasibilityCost(Cbc_Model * model)
    443   ;
    444   COINLIBAPI void COINLINKAGE
    445   Cbc_setInfeasibilityCost(Cbc_Model * model, double value)
    446   ;
    447   /** Perturbation:
    448       50  - switch on perturbation
    449       100 - auto perturb if takes too long (1.0e-6 largest nonzero)
    450       101 - we are perturbed
    451       102 - don't try perturbing again
    452       default is 100
    453       others are for playing
    454   */
    455   COINLIBAPI int COINLINKAGE
    456   Cbc_perturbation(Cbc_Model * model)
    457   ;
    458   COINLIBAPI void COINLINKAGE
    459   Cbc_setPerturbation(Cbc_Model * model, int value)
    460   ;
    461   /** Current (or last) algorithm */
    462   COINLIBAPI int COINLINKAGE
    463   Cbc_algorithm(Cbc_Model * model)
    464   ;
    465   /** Set algorithm */
    466   COINLIBAPI void COINLINKAGE
    467   Cbc_setAlgorithm(Cbc_Model * model, int value)
    468   ;
    469   /** Sum of dual infeasibilities */
    470   COINLIBAPI double COINLINKAGE
    471   Cbc_sumDualInfeasibilities(Cbc_Model * model)
    472   ;
    473   /** Number of dual infeasibilities */
    474   COINLIBAPI int COINLINKAGE
    475   Cbc_numberDualInfeasibilities(Cbc_Model * model)
    476   ;
    477   /** Sum of primal infeasibilities */
    478   COINLIBAPI double COINLINKAGE
    479   Cbc_sumPrimalInfeasibilities(Cbc_Model * model)
    480   ;
    481   /** Number of primal infeasibilities */
    482   COINLIBAPI int COINLINKAGE
    483   Cbc_numberPrimalInfeasibilities(Cbc_Model * model)
    484   ;
    485   /** Save model to file, returns 0 if success.  This is designed for
    486       use outside algorithms so does not save iterating arrays etc.
    487   It does not save any messaging information.
    488   Does not save scaling values.
    489   It does not know about all types of virtual functions.
    490   */
    491   COINLIBAPI int COINLINKAGE
    492   Cbc_saveModel(Cbc_Model * model, const char * fileName)
    493   ;
    494   /** Restore model from file, returns 0 if success,
    495       deletes current model */
    496   COINLIBAPI int COINLINKAGE
    497   Cbc_restoreModel(Cbc_Model * model, const char * fileName)
    498   ;
    499  
    500   /** Just check solution (for external use) - sets sum of
    501       infeasibilities etc */
    502   COINLIBAPI void COINLINKAGE
    503   Cbc_checkSolution(Cbc_Model * model)
    504   ;
    505   /*@}*/
    506 
    507   /******************** End of most useful part **************/
    508   /**@name gets and sets - some synonyms */
    509   /*@{*/
    510   /** Number of rows */
    511   COINLIBAPI int COINLINKAGE
    512   Cbc_getNumRows(Cbc_Model * model)
    513   ;
    514   /** Number of columns */
    515   COINLIBAPI int COINLINKAGE
    516   Cbc_getNumCols(Cbc_Model * model)
    517   ;
    518   /** Number of iterations */
    519   COINLIBAPI int COINLINKAGE
    520   Cbc_getIterationCount(Cbc_Model * model)
    521   ;
    522   /** Are there a numerical difficulties? */
    523   COINLIBAPI int COINLINKAGE
    524   Cbc_isAbandoned(Cbc_Model * model)
    525   ;
    526   /** Is optimality proven? */
    527   COINLIBAPI int COINLINKAGE
    528   Cbc_isProvenOptimal(Cbc_Model * model)
    529   ;
    530   /** Is primal infeasiblity proven? */
    531   COINLIBAPI int COINLINKAGE
    532   Cbc_isProvenPrimalInfeasible(Cbc_Model * model)
    533   ;
    534   /** Is dual infeasiblity proven? */
    535   COINLIBAPI int COINLINKAGE
    536   Cbc_isProvenDualInfeasible(Cbc_Model * model)
    537   ;
    538   /** Is the given primal objective limit reached? */
    539   COINLIBAPI int COINLINKAGE
    540   Cbc_isPrimalObjectiveLimitReached(Cbc_Model * model)
    541   ;
    542   /** Is the given dual objective limit reached? */
    543   COINLIBAPI int COINLINKAGE
    544   Cbc_isDualObjectiveLimitReached(Cbc_Model * model)
    545   ;
    546   /** Iteration limit reached? */
    547   COINLIBAPI int COINLINKAGE
    548   Cbc_isIterationLimitReached(Cbc_Model * model)
    549   ;
    550   /** Direction of optimization (1 - minimize, -1 - maximize, 0 - ignore */
    551   COINLIBAPI double COINLINKAGE
    552   Cbc_getObjSense(Cbc_Model * model)
    553   ;
    554   /** Primal row solution */
    555   COINLIBAPI const double * COINLINKAGE
    556   Cbc_getRowActivity(Cbc_Model * model)
    557   ;
    558   /** Primal column solution */
    559   COINLIBAPI const double * COINLINKAGE
    560   Cbc_getColSolution(Cbc_Model * model)
    561   ;
    562   COINLIBAPI void COINLINKAGE
    563   Cbc_setColSolution(Cbc_Model * model, const double * input)
    564   ;
    565   /** Dual row solution */
    566   COINLIBAPI const double * COINLINKAGE
    567   Cbc_getRowPrice(Cbc_Model * model)
    568   ;
    569   /** Reduced costs */
    570   COINLIBAPI const double * COINLINKAGE
    571   Cbc_getReducedCost(Cbc_Model * model)
    572   ;
    573   /** Row lower */
    574   COINLIBAPI const double* COINLINKAGE
    575   Cbc_getRowLower(Cbc_Model * model)
    576   ;
    577   /** Row upper  */
    578   COINLIBAPI const double* COINLINKAGE
    579   Cbc_getRowUpper(Cbc_Model * model)
    580   ;
    581   /** Objective */
    582   COINLIBAPI const double * COINLINKAGE
    583   Cbc_getObjCoefficients(Cbc_Model * model)
    584   ;
    585   /** Column Lower */
    586   COINLIBAPI const double * COINLINKAGE
    587   Cbc_getColLower(Cbc_Model * model)
    588   ;
    589   /** Column Upper */
    590   COINLIBAPI const double * COINLINKAGE
    591   Cbc_getColUpper(Cbc_Model * model)
    592   ;
    593   /** Objective value */
    594   COINLIBAPI double COINLINKAGE
    595   Cbc_getObjValue(Cbc_Model * model)
    596   ;
    597   /** Print the model */
    598   COINLIBAPI void COINLINKAGE
    599   Cbc_printModel(Cbc_Model * model, const char * argPrefix)
    600   ;
    601   /** Determine whether the variable at location i is integer restricted */
    602   COINLIBAPI int COINLINKAGE
    603   Cbc_isInteger(Cbc_Model * model, int i)
    604   ;
    605   /** Return CPU time */
    606   COINLIBAPI double COINLINKAGE
    607   Cbc_cpuTime(Cbc_Model * model)
    608   ;
    609   /** Number of nodes explored in B&B tree */
    610   COINLIBAPI int COINLINKAGE
    611   Cbc_getNodeCount(Cbc_Model * model)
    612   ;
    613   /** Return a copy of this model */
    614   COINLIBAPI Cbc_Model * COINLINKAGE
    615   Cbc_clone(Cbc_Model * model)
    616   ;
    617   /** Set this the variable to be continuous */
    618   COINLIBAPI Cbc_Model * COINLINKAGE
    619   Cbc_setContinuous(Cbc_Model * model, int iColumn)
    620   ;
    621   /** Add SOS constraints to the model using dense matrix */
    622   COINLIBAPI void  COINLINKAGE
    623   Cbc_addSOS_Dense(Cbc_Model * model, int numObjects, const int * len,
    624              const int ** which, const double * weights, const int type)
    625   ;
    626   /** Add SOS constraints to the model using row-order matrix */
    627   COINLIBAPI void  COINLINKAGE
    628   Cbc_addSOS_Sparse(Cbc_Model * model, const int * rowStarts,
    629              const int * rowIndices, const double * weights, const int type)
    630   ;
    631   /** Delete all object information */
    632   COINLIBAPI void  COINLINKAGE
    633   Cbc_deleteObjects(Cbc_Model * model)
    634   ;
    635   /** Print the solution */
    636   COINLIBAPI void  COINLINKAGE
    637   Cbc_printSolution(Cbc_Model * model)
    638   ;
    639   /** Dual initial solve */
    640   COINLIBAPI int COINLINKAGE
    641   Cbc_initialDualSolve(Cbc_Model * model)
    642   ;
    643   /** Primal initial solve */
    644   COINLIBAPI int COINLINKAGE
    645   Cbc_initialPrimalSolve(Cbc_Model * model)
    646   ;
    647   /** Dual algorithm - see ClpSimplexDual.hpp for method */
    648   COINLIBAPI int COINLINKAGE
    649   Cbc_dual(Cbc_Model * model, int ifValuesPass)
    650   ;
    651   /** Primal algorithm - see ClpSimplexPrimal.hpp for method */
    652   COINLIBAPI int COINLINKAGE
    653   Cbc_primal(Cbc_Model * model, int ifValuesPass)
    654   ;
    655   /*@}*/
     18
     19    /**@name Constructors and destructor
     20       These do not have an exact analogue in C++.
     21       The user does not need to know structure of Cbc_Model.
     22
     23       For all functions outside this group there is an exact C++
     24       analogue created by taking the first parameter out, removing the Cbc_
     25       from name and applying the method to an object of type ClpSimplex.
     26    */
     27    /*@{*/
     28
     29    /** Version */
     30    COINLIBAPI double COINLINKAGE Cbc_getVersion()
     31    ;
     32    /** Default Cbc_Model constructor */
     33    COINLIBAPI Cbc_Model * COINLINKAGE
     34    Cbc_newModel()
     35    ;
     36    /** Cbc_Model Destructor */
     37    COINLIBAPI void COINLINKAGE
     38    Cbc_deleteModel(Cbc_Model * model)
     39    ;
     40    /*@}*/
     41
     42    /**@name Load model - loads some stuff and initializes others */
     43    /*@{*/
     44    /* Loads a problem (the constraints on the
     45        rows are given by lower and upper bounds). If a pointer is NULL then the
     46        following values are the default:
     47        <ul>
     48        <li> <code>colub</code>: all columns have upper bound infinity
     49        <li> <code>collb</code>: all columns have lower bound 0
     50        <li> <code>rowub</code>: all rows have upper bound infinity
     51        <li> <code>rowlb</code>: all rows have lower bound -infinity
     52        <li> <code>obj</code>: all variables have 0 objective coefficient
     53        </ul>
     54
     55     Just like the other loadProblem() method except that the matrix is
     56     given in a standard column major ordered format (without gaps).
     57    */
     58    COINLIBAPI void COINLINKAGE
     59    Cbc_loadProblem (Cbc_Model * model,  const int numcols, const int numrows,
     60                     const CoinBigIndex * start, const int* index,
     61                     const double* value,
     62                     const double* collb, const double* colub,
     63                     const double* obj,
     64                     const double* rowlb, const double* rowub)
     65    ;
     66    /** Read an mps file from the given filename */
     67    COINLIBAPI int COINLINKAGE
     68    Cbc_readMps(Cbc_Model * model, const char *filename)
     69    ;
     70    /** Write an mps file from the given filename */
     71    COINLIBAPI void COINLINKAGE
     72    Cbc_writeMps(Cbc_Model * model, const char *filename)
     73    ;
     74    /** Integer information */
     75    COINLIBAPI char * COINLINKAGE
     76    Cbc_integerInformation(Cbc_Model * model)
     77    ;
     78    /** Copy in integer information */
     79    COINLIBAPI void COINLINKAGE
     80    Cbc_copyInIntegerInformation(Cbc_Model * model, const char * information)
     81    ;
     82    /** Drop integer informations */
     83    COINLIBAPI void COINLINKAGE
     84    Cbc_deleteIntegerInformation(Cbc_Model * model)
     85    ;
     86    /** Resizes rim part of model  */
     87    COINLIBAPI void COINLINKAGE
     88    Cbc_resize (Cbc_Model * model, int newNumberRows, int newNumberColumns)
     89    ;
     90    /** Deletes rows */
     91    COINLIBAPI void COINLINKAGE
     92    Cbc_deleteRows(Cbc_Model * model, int number, const int * which)
     93    ;
     94    /** Add rows */
     95    COINLIBAPI void COINLINKAGE
     96    Cbc_addRows(Cbc_Model * model, const int number, const double * rowLower,
     97                const double * rowUpper,
     98                const int * rowStarts, const int * columns,
     99                const double * elements)
     100    ;
     101
     102    /** Deletes columns */
     103    COINLIBAPI void COINLINKAGE
     104    Cbc_deleteColumns(Cbc_Model * model, int number, const int * which)
     105    ;
     106    /** Add columns */
     107    COINLIBAPI void COINLINKAGE
     108    Cbc_addColumns(Cbc_Model * model, int number, const double * columnLower,
     109                   const double * columnUpper,
     110                   const double * objective,
     111                   const int * columnStarts, const int * rows,
     112                   const double * elements);
     113    /** Drops names - makes lengthnames 0 and names empty */
     114    COINLIBAPI void COINLINKAGE
     115    Cbc_dropNames(Cbc_Model * model)
     116    ;
     117    /** Copies in names */
     118    COINLIBAPI void COINLINKAGE
     119    Cbc_copyNames(Cbc_Model * model, const char * const * rowNamesIn,
     120                  const char * const * columnNamesIn)
     121    ;
     122
     123    /*@}*/
     124    /**@name gets and sets - you will find some synonyms at the end of this file */
     125    /*@{*/
     126    /** Number of rows */
     127    COINLIBAPI int COINLINKAGE
     128    Cbc_numberRows(Cbc_Model * model)
     129    ;
     130    /** Number of columns */
     131    COINLIBAPI int COINLINKAGE
     132    Cbc_numberColumns(Cbc_Model * model)
     133    ;
     134    /** Primal tolerance to use */
     135    COINLIBAPI double COINLINKAGE
     136    Cbc_primalTolerance(Cbc_Model * model)
     137    ;
     138    COINLIBAPI void COINLINKAGE
     139    Cbc_setPrimalTolerance(Cbc_Model * model,  double value)
     140    ;
     141    /** Dual tolerance to use */
     142    COINLIBAPI double COINLINKAGE
     143    Cbc_dualTolerance(Cbc_Model * model)
     144    ;
     145    COINLIBAPI void COINLINKAGE
     146    Cbc_setDualTolerance(Cbc_Model * model,  double value)
     147    ;
     148    /* Integer tolerance to use */
     149    COINLIBAPI double COINLINKAGE
     150    Cbc_integerTolerance(Cbc_Model * model)
     151    ;
     152    COINLIBAPI void COINLINKAGE
     153    Cbc_setIntegerTolerance(Cbc_Model * model,  double value)
     154    ;
     155    /** Dual objective limit */
     156    COINLIBAPI double COINLINKAGE
     157    Cbc_dualObjectiveLimit(Cbc_Model * model)
     158    ;
     159    COINLIBAPI void COINLINKAGE
     160    Cbc_setDualObjectiveLimit(Cbc_Model * model, double value)
     161    ;
     162    /** Objective offset */
     163    COINLIBAPI double COINLINKAGE
     164    Cbc_objectiveOffset(Cbc_Model * model)
     165    ;
     166    COINLIBAPI void COINLINKAGE
     167    Cbc_setObjectiveOffset(Cbc_Model * model, double value)
     168    ;
     169    /** Fills in array with problem name  */
     170    COINLIBAPI void COINLINKAGE
     171    Cbc_problemName(Cbc_Model * model, int maxNumberCharacters, char * array)
     172    ;
     173    /** Sets problem name.  Must have \0 at end.  */
     174    COINLIBAPI int COINLINKAGE
     175    Cbc_setProblemName(Cbc_Model * model, int maxNumberCharacters, char * array)
     176    ;
     177    /** Number of iterations */
     178    COINLIBAPI int COINLINKAGE
     179    Cbc_numberIterations(Cbc_Model * model)
     180    ;
     181    COINLIBAPI void COINLINKAGE
     182    Cbc_setNumberIterations(Cbc_Model * model, int numberIterations)
     183    ;
     184    /** Maximum number of iterations */
     185    COINLIBAPI int COINLINKAGE
     186    Cbc_maximumIterations(Cbc_Model * model)
     187    ;
     188    COINLIBAPI void COINLINKAGE
     189    Cbc_setMaximumIterations(Cbc_Model * model, int value)
     190    ;
     191    /** Maximum number of nodes */
     192    COINLIBAPI int COINLINKAGE
     193    Cbc_maxNumNode(Cbc_Model * model)
     194    ;
     195    COINLIBAPI void COINLINKAGE
     196    Cbc_setMaxNumNode(Cbc_Model * model, int value)
     197    ;
     198    /* Maximum number of solutions */
     199    COINLIBAPI int COINLINKAGE
     200    Cbc_maxNumSol(Cbc_Model * model)
     201    ;
     202    COINLIBAPI void COINLINKAGE
     203    Cbc_setMaxNumSol(Cbc_Model * model, int value)
     204    ;
     205    /** Maximum time in seconds (from when set called) */
     206    COINLIBAPI double COINLINKAGE
     207    Cbc_maximumSeconds(Cbc_Model * model)
     208    ;
     209    COINLIBAPI void COINLINKAGE
     210    Cbc_setMaximumSeconds(Cbc_Model * model, double value)
     211    ;
     212    /** Returns true if hit maximum iterations (or time) */
     213    COINLIBAPI int COINLINKAGE
     214    Cbc_hitMaximumIterations(Cbc_Model * model)
     215    ;
     216    /** Status of problem:
     217        0 - optimal
     218        1 - primal infeasible
     219        2 - dual infeasible
     220        3 - stopped on iterations etc
     221        4 - stopped due to errors
     222    */
     223    COINLIBAPI int COINLINKAGE
     224    Cbc_status(Cbc_Model * model)
     225    ;
     226    /** Set problem status */
     227    COINLIBAPI void COINLINKAGE
     228    Cbc_setProblemStatus(Cbc_Model * model, int problemStatus)
     229    ;
     230    /** Secondary status of problem - may get extended
     231        0 - none
     232        1 - primal infeasible because dual limit reached
     233        2 - scaled problem optimal - unscaled has primal infeasibilities
     234        3 - scaled problem optimal - unscaled has dual infeasibilities
     235        4 - scaled problem optimal - unscaled has both dual and primal infeasibilities
     236    */
     237    COINLIBAPI int COINLINKAGE
     238    Cbc_secondaryStatus(Cbc_Model * model)
     239    ;
     240    COINLIBAPI void COINLINKAGE
     241    Cbc_setSecondaryStatus(Cbc_Model * model, int status)
     242    ;
     243    /** Direction of optimization (1 - minimize, -1 - maximize, 0 - ignore */
     244    COINLIBAPI double COINLINKAGE
     245    Cbc_optimizationDirection(Cbc_Model * model)
     246    ;
     247    COINLIBAPI void COINLINKAGE
     248    Cbc_setOptimizationDirection(Cbc_Model * model, double value)
     249    ;
     250    /** Primal row solution */
     251    COINLIBAPI double * COINLINKAGE
     252    Cbc_primalRowSolution(Cbc_Model * model)
     253    ;
     254    /** Primal column solution */
     255    COINLIBAPI double * COINLINKAGE
     256    Cbc_primalColumnSolution(Cbc_Model * model)
     257    ;
     258    /** Dual row solution */
     259    COINLIBAPI double * COINLINKAGE
     260    Cbc_dualRowSolution(Cbc_Model * model)
     261    ;
     262    /** Reduced costs */
     263    COINLIBAPI double * COINLINKAGE
     264    Cbc_dualColumnSolution(Cbc_Model * model)
     265    ;
     266    /** Row lower */
     267    COINLIBAPI double* COINLINKAGE
     268    Cbc_rowLower(Cbc_Model * model)
     269    ;
     270    /** Row upper  */
     271    COINLIBAPI double* COINLINKAGE
     272    Cbc_rowUpper(Cbc_Model * model)
     273    ;
     274    /** Objective */
     275    COINLIBAPI double * COINLINKAGE
     276    Cbc_objective(Cbc_Model * model)
     277    ;
     278    /** Column Lower */
     279    COINLIBAPI double * COINLINKAGE
     280    Cbc_columnLower(Cbc_Model * model)
     281    ;
     282    /** Column Upper */
     283    COINLIBAPI double * COINLINKAGE
     284    Cbc_columnUpper(Cbc_Model * model)
     285    ;
     286    /** Number of elements in matrix */
     287    COINLIBAPI int COINLINKAGE
     288    Cbc_getNumElements(Cbc_Model * model)
     289    ;
     290    /** Column starts in matrix */
     291    COINLIBAPI const CoinBigIndex * COINLINKAGE
     292    Cbc_getVectorStarts(Cbc_Model * model)
     293    ;
     294    /** Row indices in matrix */
     295    COINLIBAPI const int * COINLINKAGE
     296    Cbc_getIndices(Cbc_Model * model)
     297    ;
     298    /** Column vector lengths in matrix */
     299    COINLIBAPI const int * COINLINKAGE
     300    Cbc_getVectorLengths(Cbc_Model * model)
     301    ;
     302    /** Element values in matrix */
     303    COINLIBAPI const double * COINLINKAGE
     304    Cbc_getElements(Cbc_Model * model)
     305    ;
     306    /** Objective value */
     307    COINLIBAPI double COINLINKAGE
     308    Cbc_objectiveValue(Cbc_Model * model)
     309    ;
     310    /** Infeasibility/unbounded ray (NULL returned if none/wrong)
     311        Up to user to use delete [] on these arrays.  */
     312    COINLIBAPI double * COINLINKAGE
     313    Cbc_infeasibilityRay(Cbc_Model * model)
     314    ;
     315    COINLIBAPI double * COINLINKAGE
     316    Cbc_unboundedRay(Cbc_Model * model)
     317    ;
     318    /** See if status array exists (partly for OsiClp) */
     319    COINLIBAPI int COINLINKAGE
     320    Cbc_statusExists(Cbc_Model * model)
     321    ;
     322    /** Return address of status array (char[numberRows+numberColumns]) */
     323    COINLIBAPI void  COINLINKAGE
     324    Cbc_getBasisStatus(Cbc_Model * model, int * cstat, int * rstat)
     325    ;
     326    /** Copy in status vector */
     327    COINLIBAPI void COINLINKAGE
     328    Cbc_setBasisStatus(Cbc_Model * model, int * cstat, int * rstat)
     329    ;
     330
     331    /** User pointer for whatever reason */
     332    COINLIBAPI void COINLINKAGE
     333    Cbc_setUserPointer (Cbc_Model * model, void * pointer)
     334    ;
     335    COINLIBAPI void * COINLINKAGE
     336    Cbc_getUserPointer (Cbc_Model * model)
     337    ;
     338    /*@}*/
     339    /**@name Message handling.  Call backs are handled by ONE function */
     340    /*@{*/
     341    /** Pass in Callback function.
     342     Message numbers up to 1000000 are Clp, Coin ones have 1000000 added */
     343    COINLIBAPI void COINLINKAGE
     344    Cbc_registerCallBack(Cbc_Model * model,
     345                         cbc_callback userCallBack)
     346    ;
     347    /** Unset Callback function */
     348    COINLIBAPI void COINLINKAGE
     349    Cbc_clearCallBack(Cbc_Model * model)
     350    ;
     351    /** Amount of print out:
     352        0 - none
     353        1 - just final
     354        2 - just factorizations
     355        3 - as 2 plus a bit more
     356        4 - verbose
     357        above that 8,16,32 etc just for selective debug
     358    */
     359    COINLIBAPI void COINLINKAGE
     360    Cbc_setLogLevel(Cbc_Model * model, int value)
     361    ;
     362    COINLIBAPI int COINLINKAGE
     363    Cbc_logLevel(Cbc_Model * model)
     364    ;
     365    /** length of names (0 means no names0 */
     366    COINLIBAPI int COINLINKAGE
     367    Cbc_lengthNames(Cbc_Model * model)
     368    ;
     369    /** Fill in array (at least lengthNames+1 long) with a row name */
     370    COINLIBAPI void COINLINKAGE
     371    Cbc_rowName(Cbc_Model * model, int iRow, char * name)
     372    ;
     373    /** Fill in array (at least lengthNames+1 long) with a column name */
     374    COINLIBAPI void COINLINKAGE
     375    Cbc_columnName(Cbc_Model * model, int iColumn, char * name)
     376    ;
     377
     378    /*@}*/
     379
     380
     381    /**@name Functions most useful to user */
     382    /*@{*/
     383    /** General solve algorithm which can do presolve.
     384        See  ClpSolve.hpp for options
     385     */
     386    COINLIBAPI int COINLINKAGE
     387    Cbc_initialSolve(Cbc_Model * model)
     388    ;
     389    /* General solve algorithm which can do presolve.
     390       See  CbcModel.hpp for options
     391    */
     392    COINLIBAPI int COINLINKAGE
     393    Cbc_branchAndBound(Cbc_Model * model)
     394    ;
     395    /** Sets or unsets scaling, 0 -off, 1 equilibrium, 2 geometric, 3, auto, 4 dynamic(later) */
     396    COINLIBAPI void COINLINKAGE
     397    Cbc_scaling(Cbc_Model * model, int mode)
     398    ;
     399    /** Gets scalingFlag */
     400    COINLIBAPI int COINLINKAGE
     401    Cbc_scalingFlag(Cbc_Model * model)
     402    ;
     403    /** Crash - at present just aimed at dual, returns
     404        -2 if dual preferred and crash basis created
     405        -1 if dual preferred and all slack basis preferred
     406         0 if basis going in was not all slack
     407         1 if primal preferred and all slack basis preferred
     408         2 if primal preferred and crash basis created.
     409
     410         if gap between bounds <="gap" variables can be flipped
     411
     412         If "pivot" is
     413         0 No pivoting (so will just be choice of algorithm)
     414         1 Simple pivoting e.g. gub
     415         2 Mini iterations
     416    */
     417    COINLIBAPI int COINLINKAGE
     418    Cbc_crash(Cbc_Model * model, double gap, int pivot)
     419    ;
     420    /*@}*/
     421
     422
     423    /**@name most useful gets and sets */
     424    /*@{*/
     425    /** If problem is primal feasible */
     426    COINLIBAPI int COINLINKAGE
     427    Cbc_primalFeasible(Cbc_Model * model)
     428    ;
     429    /** If problem is dual feasible */
     430    COINLIBAPI int COINLINKAGE
     431    Cbc_dualFeasible(Cbc_Model * model)
     432    ;
     433    /** Dual bound */
     434    COINLIBAPI double COINLINKAGE
     435    Cbc_dualBound(Cbc_Model * model)
     436    ;
     437    COINLIBAPI void COINLINKAGE
     438    Cbc_setDualBound(Cbc_Model * model, double value)
     439    ;
     440    /** Infeasibility cost */
     441    COINLIBAPI double COINLINKAGE
     442    Cbc_infeasibilityCost(Cbc_Model * model)
     443    ;
     444    COINLIBAPI void COINLINKAGE
     445    Cbc_setInfeasibilityCost(Cbc_Model * model, double value)
     446    ;
     447    /** Perturbation:
     448        50  - switch on perturbation
     449        100 - auto perturb if takes too long (1.0e-6 largest nonzero)
     450        101 - we are perturbed
     451        102 - don't try perturbing again
     452        default is 100
     453        others are for playing
     454    */
     455    COINLIBAPI int COINLINKAGE
     456    Cbc_perturbation(Cbc_Model * model)
     457    ;
     458    COINLIBAPI void COINLINKAGE
     459    Cbc_setPerturbation(Cbc_Model * model, int value)
     460    ;
     461    /** Current (or last) algorithm */
     462    COINLIBAPI int COINLINKAGE
     463    Cbc_algorithm(Cbc_Model * model)
     464    ;
     465    /** Set algorithm */
     466    COINLIBAPI void COINLINKAGE
     467    Cbc_setAlgorithm(Cbc_Model * model, int value)
     468    ;
     469    /** Sum of dual infeasibilities */
     470    COINLIBAPI double COINLINKAGE
     471    Cbc_sumDualInfeasibilities(Cbc_Model * model)
     472    ;
     473    /** Number of dual infeasibilities */
     474    COINLIBAPI int COINLINKAGE
     475    Cbc_numberDualInfeasibilities(Cbc_Model * model)
     476    ;
     477    /** Sum of primal infeasibilities */
     478    COINLIBAPI double COINLINKAGE
     479    Cbc_sumPrimalInfeasibilities(Cbc_Model * model)
     480    ;
     481    /** Number of primal infeasibilities */
     482    COINLIBAPI int COINLINKAGE
     483    Cbc_numberPrimalInfeasibilities(Cbc_Model * model)
     484    ;
     485    /** Save model to file, returns 0 if success.  This is designed for
     486        use outside algorithms so does not save iterating arrays etc.
     487    It does not save any messaging information.
     488    Does not save scaling values.
     489    It does not know about all types of virtual functions.
     490    */
     491    COINLIBAPI int COINLINKAGE
     492    Cbc_saveModel(Cbc_Model * model, const char * fileName)
     493    ;
     494    /** Restore model from file, returns 0 if success,
     495        deletes current model */
     496    COINLIBAPI int COINLINKAGE
     497    Cbc_restoreModel(Cbc_Model * model, const char * fileName)
     498    ;
     499
     500    /** Just check solution (for external use) - sets sum of
     501        infeasibilities etc */
     502    COINLIBAPI void COINLINKAGE
     503    Cbc_checkSolution(Cbc_Model * model)
     504    ;
     505    /*@}*/
     506
     507    /******************** End of most useful part **************/
     508    /**@name gets and sets - some synonyms */
     509    /*@{*/
     510    /** Number of rows */
     511    COINLIBAPI int COINLINKAGE
     512    Cbc_getNumRows(Cbc_Model * model)
     513    ;
     514    /** Number of columns */
     515    COINLIBAPI int COINLINKAGE
     516    Cbc_getNumCols(Cbc_Model * model)
     517    ;
     518    /** Number of iterations */
     519    COINLIBAPI int COINLINKAGE
     520    Cbc_getIterationCount(Cbc_Model * model)
     521    ;
     522    /** Are there a numerical difficulties? */
     523    COINLIBAPI int COINLINKAGE
     524    Cbc_isAbandoned(Cbc_Model * model)
     525    ;
     526    /** Is optimality proven? */
     527    COINLIBAPI int COINLINKAGE
     528    Cbc_isProvenOptimal(Cbc_Model * model)
     529    ;
     530    /** Is primal infeasiblity proven? */
     531    COINLIBAPI int COINLINKAGE
     532    Cbc_isProvenPrimalInfeasible(Cbc_Model * model)
     533    ;
     534    /** Is dual infeasiblity proven? */
     535    COINLIBAPI int COINLINKAGE
     536    Cbc_isProvenDualInfeasible(Cbc_Model * model)
     537    ;
     538    /** Is the given primal objective limit reached? */
     539    COINLIBAPI int COINLINKAGE
     540    Cbc_isPrimalObjectiveLimitReached(Cbc_Model * model)
     541    ;
     542    /** Is the given dual objective limit reached? */
     543    COINLIBAPI int COINLINKAGE
     544    Cbc_isDualObjectiveLimitReached(Cbc_Model * model)
     545    ;
     546    /** Iteration limit reached? */
     547    COINLIBAPI int COINLINKAGE
     548    Cbc_isIterationLimitReached(Cbc_Model * model)
     549    ;
     550    /** Direction of optimization (1 - minimize, -1 - maximize, 0 - ignore */
     551    COINLIBAPI double COINLINKAGE
     552    Cbc_getObjSense(Cbc_Model * model)
     553    ;
     554    /** Primal row solution */
     555    COINLIBAPI const double * COINLINKAGE
     556    Cbc_getRowActivity(Cbc_Model * model)
     557    ;
     558    /** Primal column solution */
     559    COINLIBAPI const double * COINLINKAGE
     560    Cbc_getColSolution(Cbc_Model * model)
     561    ;
     562    COINLIBAPI void COINLINKAGE
     563    Cbc_setColSolution(Cbc_Model * model, const double * input)
     564    ;
     565    /** Dual row solution */
     566    COINLIBAPI const double * COINLINKAGE
     567    Cbc_getRowPrice(Cbc_Model * model)
     568    ;
     569    /** Reduced costs */
     570    COINLIBAPI const double * COINLINKAGE
     571    Cbc_getReducedCost(Cbc_Model * model)
     572    ;
     573    /** Row lower */
     574    COINLIBAPI const double* COINLINKAGE
     575    Cbc_getRowLower(Cbc_Model * model)
     576    ;
     577    /** Row upper  */
     578    COINLIBAPI const double* COINLINKAGE
     579    Cbc_getRowUpper(Cbc_Model * model)
     580    ;
     581    /** Objective */
     582    COINLIBAPI const double * COINLINKAGE
     583    Cbc_getObjCoefficients(Cbc_Model * model)
     584    ;
     585    /** Column Lower */
     586    COINLIBAPI const double * COINLINKAGE
     587    Cbc_getColLower(Cbc_Model * model)
     588    ;
     589    /** Column Upper */
     590    COINLIBAPI const double * COINLINKAGE
     591    Cbc_getColUpper(Cbc_Model * model)
     592    ;
     593    /** Objective value */
     594    COINLIBAPI double COINLINKAGE
     595    Cbc_getObjValue(Cbc_Model * model)
     596    ;
     597    /** Print the model */
     598    COINLIBAPI void COINLINKAGE
     599    Cbc_printModel(Cbc_Model * model, const char * argPrefix)
     600    ;
     601    /** Determine whether the variable at location i is integer restricted */
     602    COINLIBAPI int COINLINKAGE
     603    Cbc_isInteger(Cbc_Model * model, int i)
     604    ;
     605    /** Return CPU time */
     606    COINLIBAPI double COINLINKAGE
     607    Cbc_cpuTime(Cbc_Model * model)
     608    ;
     609    /** Number of nodes explored in B&B tree */
     610    COINLIBAPI int COINLINKAGE
     611    Cbc_getNodeCount(Cbc_Model * model)
     612    ;
     613    /** Return a copy of this model */
     614    COINLIBAPI Cbc_Model * COINLINKAGE
     615    Cbc_clone(Cbc_Model * model)
     616    ;
     617    /** Set this the variable to be continuous */
     618    COINLIBAPI Cbc_Model * COINLINKAGE
     619    Cbc_setContinuous(Cbc_Model * model, int iColumn)
     620    ;
     621    /** Add SOS constraints to the model using dense matrix */
     622    COINLIBAPI void  COINLINKAGE
     623    Cbc_addSOS_Dense(Cbc_Model * model, int numObjects, const int * len,
     624                     const int ** which, const double * weights, const int type)
     625    ;
     626    /** Add SOS constraints to the model using row-order matrix */
     627    COINLIBAPI void  COINLINKAGE
     628    Cbc_addSOS_Sparse(Cbc_Model * model, const int * rowStarts,
     629                      const int * rowIndices, const double * weights, const int type)
     630    ;
     631    /** Delete all object information */
     632    COINLIBAPI void  COINLINKAGE
     633    Cbc_deleteObjects(Cbc_Model * model)
     634    ;
     635    /** Print the solution */
     636    COINLIBAPI void  COINLINKAGE
     637    Cbc_printSolution(Cbc_Model * model)
     638    ;
     639    /** Dual initial solve */
     640    COINLIBAPI int COINLINKAGE
     641    Cbc_initialDualSolve(Cbc_Model * model)
     642    ;
     643    /** Primal initial solve */
     644    COINLIBAPI int COINLINKAGE
     645    Cbc_initialPrimalSolve(Cbc_Model * model)
     646    ;
     647    /** Dual algorithm - see ClpSimplexDual.hpp for method */
     648    COINLIBAPI int COINLINKAGE
     649    Cbc_dual(Cbc_Model * model, int ifValuesPass)
     650    ;
     651    /** Primal algorithm - see ClpSimplexPrimal.hpp for method */
     652    COINLIBAPI int COINLINKAGE
     653    Cbc_primal(Cbc_Model * model, int ifValuesPass)
     654    ;
     655    /*@}*/
    656656#ifdef __cplusplus
    657     }
     657}
    658658#endif
    659659#endif
Note: See TracChangeset for help on using the changeset viewer.