Ignore:
Timestamp:
Jan 6, 2019 2:43:06 PM (3 months ago)
Author:
unxusr
Message:

formatting

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Clp/src/CbcOrClpParam.hpp

    r2384 r2385  
    66
    77#ifdef USE_CBCCONFIG
    8 # include "CbcConfig.h"
     8#include "CbcConfig.h"
    99#else
    10 # include "ClpConfig.h"
     10#include "ClpConfig.h"
    1111#endif
    1212
     
    4848
    4949{
    50      CBC_PARAM_GENERALQUERY = -100,
    51      CBC_PARAM_FULLGENERALQUERY,
    52 
    53      CLP_PARAM_DBL_PRIMALTOLERANCE = 1,
    54      CLP_PARAM_DBL_DUALTOLERANCE,
    55      CLP_PARAM_DBL_TIMELIMIT,
    56      CLP_PARAM_DBL_DUALBOUND,
    57      CLP_PARAM_DBL_PRIMALWEIGHT,
    58      CLP_PARAM_DBL_OBJSCALE,
    59      CLP_PARAM_DBL_RHSSCALE,
    60      CLP_PARAM_DBL_ZEROTOLERANCE,
    61      CLP_PARAM_DBL_PSI,
    62 
    63      CBC_PARAM_DBL_INFEASIBILITYWEIGHT = 51,
    64      CBC_PARAM_DBL_CUTOFF,
    65      CBC_PARAM_DBL_INTEGERTOLERANCE,
    66      CBC_PARAM_DBL_INCREMENT,
    67      CBC_PARAM_DBL_ALLOWABLEGAP,
    68      CBC_PARAM_DBL_TIMELIMIT_BAB,
    69      CBC_PARAM_DBL_GAPRATIO,
    70 
    71      CBC_PARAM_DBL_DJFIX = 81,
    72      CBC_PARAM_DBL_TIGHTENFACTOR,
    73      CLP_PARAM_DBL_PRESOLVETOLERANCE,
    74      CLP_PARAM_DBL_OBJSCALE2,
    75      CBC_PARAM_DBL_FAKEINCREMENT,
    76      CBC_PARAM_DBL_FAKECUTOFF,
    77      CBC_PARAM_DBL_ARTIFICIALCOST,
    78      CBC_PARAM_DBL_DEXTRA3,
    79      CBC_PARAM_DBL_SMALLBAB,
    80      CBC_PARAM_DBL_DEXTRA4,
    81      CBC_PARAM_DBL_DEXTRA5,
    82 
    83      CLP_PARAM_INT_SOLVERLOGLEVEL = 101,
     50  CBC_PARAM_GENERALQUERY = -100,
     51  CBC_PARAM_FULLGENERALQUERY,
     52
     53  CLP_PARAM_DBL_PRIMALTOLERANCE = 1,
     54  CLP_PARAM_DBL_DUALTOLERANCE,
     55  CLP_PARAM_DBL_TIMELIMIT,
     56  CLP_PARAM_DBL_DUALBOUND,
     57  CLP_PARAM_DBL_PRIMALWEIGHT,
     58  CLP_PARAM_DBL_OBJSCALE,
     59  CLP_PARAM_DBL_RHSSCALE,
     60  CLP_PARAM_DBL_ZEROTOLERANCE,
     61  CLP_PARAM_DBL_PSI,
     62
     63  CBC_PARAM_DBL_INFEASIBILITYWEIGHT = 51,
     64  CBC_PARAM_DBL_CUTOFF,
     65  CBC_PARAM_DBL_INTEGERTOLERANCE,
     66  CBC_PARAM_DBL_INCREMENT,
     67  CBC_PARAM_DBL_ALLOWABLEGAP,
     68  CBC_PARAM_DBL_TIMELIMIT_BAB,
     69  CBC_PARAM_DBL_GAPRATIO,
     70
     71  CBC_PARAM_DBL_DJFIX = 81,
     72  CBC_PARAM_DBL_TIGHTENFACTOR,
     73  CLP_PARAM_DBL_PRESOLVETOLERANCE,
     74  CLP_PARAM_DBL_OBJSCALE2,
     75  CBC_PARAM_DBL_FAKEINCREMENT,
     76  CBC_PARAM_DBL_FAKECUTOFF,
     77  CBC_PARAM_DBL_ARTIFICIALCOST,
     78  CBC_PARAM_DBL_DEXTRA3,
     79  CBC_PARAM_DBL_SMALLBAB,
     80  CBC_PARAM_DBL_DEXTRA4,
     81  CBC_PARAM_DBL_DEXTRA5,
     82
     83  CLP_PARAM_INT_SOLVERLOGLEVEL = 101,
    8484#ifndef COIN_HAS_CBC
    85      CLP_PARAM_INT_LOGLEVEL = 101,
     85  CLP_PARAM_INT_LOGLEVEL = 101,
    8686#endif
    87      CLP_PARAM_INT_MAXFACTOR,
    88      CLP_PARAM_INT_PERTVALUE,
    89      CLP_PARAM_INT_MAXITERATION,
    90      CLP_PARAM_INT_PRESOLVEPASS,
    91      CLP_PARAM_INT_IDIOT,
    92      CLP_PARAM_INT_SPRINT,
    93      CLP_PARAM_INT_OUTPUTFORMAT,
    94      CLP_PARAM_INT_SLPVALUE,
    95      CLP_PARAM_INT_PRESOLVEOPTIONS,
    96      CLP_PARAM_INT_PRINTOPTIONS,
    97      CLP_PARAM_INT_SPECIALOPTIONS,
    98      CLP_PARAM_INT_SUBSTITUTION,
    99      CLP_PARAM_INT_DUALIZE,
    100      CLP_PARAM_INT_VERBOSE,
    101      CLP_PARAM_INT_CPP,
    102      CLP_PARAM_INT_PROCESSTUNE,
    103      CLP_PARAM_INT_USESOLUTION,
    104      CLP_PARAM_INT_RANDOMSEED,
    105      CLP_PARAM_INT_MORESPECIALOPTIONS,
    106      CLP_PARAM_INT_DECOMPOSE_BLOCKS,
    107      CLP_PARAM_INT_VECTOR_MODE,
    108 
    109      CBC_PARAM_INT_STRONGBRANCHING = 151,
    110      CBC_PARAM_INT_CUTDEPTH,
    111      CBC_PARAM_INT_MAXNODES,
    112      CBC_PARAM_INT_NUMBERBEFORE,
    113      CBC_PARAM_INT_NUMBERANALYZE,
    114      CBC_PARAM_INT_MIPOPTIONS,
    115      CBC_PARAM_INT_MOREMIPOPTIONS,
    116      CBC_PARAM_INT_MAXHOTITS,
    117      CBC_PARAM_INT_FPUMPITS,
    118      CBC_PARAM_INT_MAXSOLS,
    119      CBC_PARAM_INT_FPUMPTUNE,
    120      CBC_PARAM_INT_TESTOSI,
    121      CBC_PARAM_INT_EXTRA1,
    122      CBC_PARAM_INT_EXTRA2,
    123      CBC_PARAM_INT_EXTRA3,
    124      CBC_PARAM_INT_EXTRA4,
    125      CBC_PARAM_INT_DEPTHMINIBAB,
    126      CBC_PARAM_INT_CUTPASSINTREE,
    127      CBC_PARAM_INT_THREADS,
    128      CBC_PARAM_INT_CUTPASS,
    129      CBC_PARAM_INT_VUBTRY,
    130      CBC_PARAM_INT_DENSE,
    131      CBC_PARAM_INT_EXPERIMENT,
    132      CBC_PARAM_INT_DIVEOPT,
    133      CBC_PARAM_INT_DIVEOPTSOLVES,
    134      CBC_PARAM_INT_STRATEGY,
    135      CBC_PARAM_INT_SMALLFACT,
    136      CBC_PARAM_INT_HOPTIONS,
    137      CBC_PARAM_INT_CUTLENGTH,
    138      CBC_PARAM_INT_FPUMPTUNE2,
     87  CLP_PARAM_INT_MAXFACTOR,
     88  CLP_PARAM_INT_PERTVALUE,
     89  CLP_PARAM_INT_MAXITERATION,
     90  CLP_PARAM_INT_PRESOLVEPASS,
     91  CLP_PARAM_INT_IDIOT,
     92  CLP_PARAM_INT_SPRINT,
     93  CLP_PARAM_INT_OUTPUTFORMAT,
     94  CLP_PARAM_INT_SLPVALUE,
     95  CLP_PARAM_INT_PRESOLVEOPTIONS,
     96  CLP_PARAM_INT_PRINTOPTIONS,
     97  CLP_PARAM_INT_SPECIALOPTIONS,
     98  CLP_PARAM_INT_SUBSTITUTION,
     99  CLP_PARAM_INT_DUALIZE,
     100  CLP_PARAM_INT_VERBOSE,
     101  CLP_PARAM_INT_CPP,
     102  CLP_PARAM_INT_PROCESSTUNE,
     103  CLP_PARAM_INT_USESOLUTION,
     104  CLP_PARAM_INT_RANDOMSEED,
     105  CLP_PARAM_INT_MORESPECIALOPTIONS,
     106  CLP_PARAM_INT_DECOMPOSE_BLOCKS,
     107  CLP_PARAM_INT_VECTOR_MODE,
     108
     109  CBC_PARAM_INT_STRONGBRANCHING = 151,
     110  CBC_PARAM_INT_CUTDEPTH,
     111  CBC_PARAM_INT_MAXNODES,
     112  CBC_PARAM_INT_NUMBERBEFORE,
     113  CBC_PARAM_INT_NUMBERANALYZE,
     114  CBC_PARAM_INT_MIPOPTIONS,
     115  CBC_PARAM_INT_MOREMIPOPTIONS,
     116  CBC_PARAM_INT_MAXHOTITS,
     117  CBC_PARAM_INT_FPUMPITS,
     118  CBC_PARAM_INT_MAXSOLS,
     119  CBC_PARAM_INT_FPUMPTUNE,
     120  CBC_PARAM_INT_TESTOSI,
     121  CBC_PARAM_INT_EXTRA1,
     122  CBC_PARAM_INT_EXTRA2,
     123  CBC_PARAM_INT_EXTRA3,
     124  CBC_PARAM_INT_EXTRA4,
     125  CBC_PARAM_INT_DEPTHMINIBAB,
     126  CBC_PARAM_INT_CUTPASSINTREE,
     127  CBC_PARAM_INT_THREADS,
     128  CBC_PARAM_INT_CUTPASS,
     129  CBC_PARAM_INT_VUBTRY,
     130  CBC_PARAM_INT_DENSE,
     131  CBC_PARAM_INT_EXPERIMENT,
     132  CBC_PARAM_INT_DIVEOPT,
     133  CBC_PARAM_INT_DIVEOPTSOLVES,
     134  CBC_PARAM_INT_STRATEGY,
     135  CBC_PARAM_INT_SMALLFACT,
     136  CBC_PARAM_INT_HOPTIONS,
     137  CBC_PARAM_INT_CUTLENGTH,
     138  CBC_PARAM_INT_FPUMPTUNE2,
    139139#ifdef COIN_HAS_CBC
    140      CLP_PARAM_INT_LOGLEVEL ,
     140  CLP_PARAM_INT_LOGLEVEL,
    141141#endif
    142      CBC_PARAM_INT_MAXSAVEDSOLS,
    143      CBC_PARAM_INT_RANDOMSEED,
    144      CBC_PARAM_INT_MULTIPLEROOTS,
    145      CBC_PARAM_INT_STRONG_STRATEGY,
    146      CBC_PARAM_INT_EXTRA_VARIABLES,
    147      CBC_PARAM_INT_MAX_SLOW_CUTS,
    148      CBC_PARAM_INT_MOREMOREMIPOPTIONS,
    149 
    150      CLP_PARAM_STR_DIRECTION = 201,
    151      CLP_PARAM_STR_DUALPIVOT,
    152      CLP_PARAM_STR_SCALING,
    153      CLP_PARAM_STR_ERRORSALLOWED,
    154      CLP_PARAM_STR_KEEPNAMES,
    155      CLP_PARAM_STR_SPARSEFACTOR,
    156      CLP_PARAM_STR_PRIMALPIVOT,
    157      CLP_PARAM_STR_PRESOLVE,
    158      CLP_PARAM_STR_CRASH,
    159      CLP_PARAM_STR_BIASLU,
    160      CLP_PARAM_STR_PERTURBATION,
    161      CLP_PARAM_STR_MESSAGES,
    162      CLP_PARAM_STR_AUTOSCALE,
    163      CLP_PARAM_STR_CHOLESKY,
    164      CLP_PARAM_STR_KKT,
    165      CLP_PARAM_STR_BARRIERSCALE,
    166      CLP_PARAM_STR_GAMMA,
    167      CLP_PARAM_STR_CROSSOVER,
    168      CLP_PARAM_STR_PFI,
    169      CLP_PARAM_STR_INTPRINT,
    170      CLP_PARAM_STR_VECTOR,
    171      CLP_PARAM_STR_FACTORIZATION,
    172      CLP_PARAM_STR_ALLCOMMANDS,
    173      CLP_PARAM_STR_TIME_MODE,
    174      CLP_PARAM_STR_ABCWANTED,
    175      CLP_PARAM_STR_BUFFER_MODE,
    176 
    177      CBC_PARAM_STR_NODESTRATEGY = 301,
    178      CBC_PARAM_STR_BRANCHSTRATEGY,
    179      CBC_PARAM_STR_CUTSSTRATEGY,
    180      CBC_PARAM_STR_HEURISTICSTRATEGY,
    181      CBC_PARAM_STR_GOMORYCUTS,
    182      CBC_PARAM_STR_PROBINGCUTS,
    183      CBC_PARAM_STR_KNAPSACKCUTS,
    184      CBC_PARAM_STR_REDSPLITCUTS,
    185      CBC_PARAM_STR_ROUNDING,
    186      CBC_PARAM_STR_SOLVER,
    187      CBC_PARAM_STR_CLIQUECUTS,
    188      CBC_PARAM_STR_COSTSTRATEGY,
    189      CBC_PARAM_STR_FLOWCUTS,
    190      CBC_PARAM_STR_MIXEDCUTS,
    191      CBC_PARAM_STR_TWOMIRCUTS,
    192      CBC_PARAM_STR_PREPROCESS,
    193      CBC_PARAM_STR_FPUMP,
    194      CBC_PARAM_STR_GREEDY,
    195      CBC_PARAM_STR_COMBINE,
    196      CBC_PARAM_STR_PROXIMITY,
    197      CBC_PARAM_STR_LOCALTREE,
    198      CBC_PARAM_STR_SOS,
    199      CBC_PARAM_STR_LANDPCUTS,
    200      CBC_PARAM_STR_RINS,
    201      CBC_PARAM_STR_RESIDCUTS,
    202      CBC_PARAM_STR_RENS,
    203      CBC_PARAM_STR_DIVINGS,
    204      CBC_PARAM_STR_DIVINGC,
    205      CBC_PARAM_STR_DIVINGF,
    206      CBC_PARAM_STR_DIVINGG,
    207      CBC_PARAM_STR_DIVINGL,
    208      CBC_PARAM_STR_DIVINGP,
    209      CBC_PARAM_STR_DIVINGV,
    210      CBC_PARAM_STR_DINS,
    211      CBC_PARAM_STR_PIVOTANDFIX,
    212      CBC_PARAM_STR_RANDROUND,
    213      CBC_PARAM_STR_NAIVE,
    214      CBC_PARAM_STR_ZEROHALFCUTS,
    215      CBC_PARAM_STR_CPX,
    216      CBC_PARAM_STR_CROSSOVER2,
    217      CBC_PARAM_STR_PIVOTANDCOMPLEMENT,
    218      CBC_PARAM_STR_VND,
    219      CBC_PARAM_STR_LAGOMORYCUTS,
    220      CBC_PARAM_STR_LATWOMIRCUTS,
    221      CBC_PARAM_STR_REDSPLIT2CUTS,
    222      CBC_PARAM_STR_GMICUTS,
    223      CBC_PARAM_STR_CUTOFF_CONSTRAINT,
    224      CBC_PARAM_STR_DW,
    225      CBC_PARAM_STR_ORBITAL,
    226      CBC_PARAM_STR_PREPROCNAMES,
    227      CBC_PARAM_STR_SOSPRIORITIZE,
    228 
    229      CLP_PARAM_ACTION_DIRECTORY = 401,
    230      CLP_PARAM_ACTION_DIRSAMPLE,
    231      CLP_PARAM_ACTION_DIRNETLIB,
    232      CBC_PARAM_ACTION_DIRMIPLIB,
    233      CLP_PARAM_ACTION_IMPORT,
    234      CLP_PARAM_ACTION_EXPORT,
    235      CLP_PARAM_ACTION_RESTORE,
    236      CLP_PARAM_ACTION_SAVE,
    237      CLP_PARAM_ACTION_DUALSIMPLEX,
    238      CLP_PARAM_ACTION_PRIMALSIMPLEX,
    239      CLP_PARAM_ACTION_EITHERSIMPLEX,
    240      CLP_PARAM_ACTION_MAXIMIZE,
    241      CLP_PARAM_ACTION_MINIMIZE,
    242      CLP_PARAM_ACTION_EXIT,
    243      CLP_PARAM_ACTION_STDIN,
    244      CLP_PARAM_ACTION_UNITTEST,
    245      CLP_PARAM_ACTION_NETLIB_EITHER,
    246      CLP_PARAM_ACTION_NETLIB_DUAL,
    247      CLP_PARAM_ACTION_NETLIB_PRIMAL,
    248      CLP_PARAM_ACTION_SOLUTION,
    249      CLP_PARAM_ACTION_SAVESOL,
    250      CLP_PARAM_ACTION_TIGHTEN,
    251      CLP_PARAM_ACTION_FAKEBOUND,
    252      CLP_PARAM_ACTION_HELP,
    253      CLP_PARAM_ACTION_PLUSMINUS,
    254      CLP_PARAM_ACTION_NETWORK,
    255      CLP_PARAM_ACTION_ALLSLACK,
    256      CLP_PARAM_ACTION_REVERSE,
    257      CLP_PARAM_ACTION_BARRIER,
    258      CLP_PARAM_ACTION_NETLIB_BARRIER,
    259      CLP_PARAM_ACTION_NETLIB_TUNE,
    260      CLP_PARAM_ACTION_REALLY_SCALE,
    261      CLP_PARAM_ACTION_BASISIN,
    262      CLP_PARAM_ACTION_BASISOUT,
    263      CLP_PARAM_ACTION_SOLVECONTINUOUS,
    264      CLP_PARAM_ACTION_CLEARCUTS,
    265      CLP_PARAM_ACTION_VERSION,
    266      CLP_PARAM_ACTION_STATISTICS,
    267      CLP_PARAM_ACTION_DEBUG,
    268      CLP_PARAM_ACTION_DUMMY,
    269      CLP_PARAM_ACTION_PRINTMASK,
    270      CLP_PARAM_ACTION_OUTDUPROWS,
    271      CLP_PARAM_ACTION_USERCLP,
    272      CLP_PARAM_ACTION_MODELIN,
    273      CLP_PARAM_ACTION_CSVSTATISTICS,
    274      CLP_PARAM_ACTION_STOREDFILE,
    275      CLP_PARAM_ACTION_ENVIRONMENT,
    276      CLP_PARAM_ACTION_PARAMETRICS,
    277      CLP_PARAM_ACTION_GMPL_SOLUTION,
    278      CLP_PARAM_ACTION_RESTORESOL,
    279      CLP_PARAM_ACTION_GUESS,
    280 
    281      CBC_PARAM_ACTION_BAB = 501,
    282      CBC_PARAM_ACTION_MIPLIB,
    283      CBC_PARAM_ACTION_STRENGTHEN,
    284      CBC_PARAM_ACTION_PRIORITYIN,
    285      CBC_PARAM_ACTION_MIPSTART,
    286      CBC_PARAM_ACTION_USERCBC,
    287      CBC_PARAM_ACTION_DOHEURISTIC,
    288      CLP_PARAM_ACTION_NEXTBESTSOLUTION,
    289 
    290      CBC_PARAM_NOTUSED_OSLSTUFF = 601,
    291      CBC_PARAM_NOTUSED_CBCSTUFF,
    292 
    293      CBC_PARAM_NOTUSED_INVALID = 1000
    294 } ;
     142  CBC_PARAM_INT_MAXSAVEDSOLS,
     143  CBC_PARAM_INT_RANDOMSEED,
     144  CBC_PARAM_INT_MULTIPLEROOTS,
     145  CBC_PARAM_INT_STRONG_STRATEGY,
     146  CBC_PARAM_INT_EXTRA_VARIABLES,
     147  CBC_PARAM_INT_MAX_SLOW_CUTS,
     148  CBC_PARAM_INT_MOREMOREMIPOPTIONS,
     149
     150  CLP_PARAM_STR_DIRECTION = 201,
     151  CLP_PARAM_STR_DUALPIVOT,
     152  CLP_PARAM_STR_SCALING,
     153  CLP_PARAM_STR_ERRORSALLOWED,
     154  CLP_PARAM_STR_KEEPNAMES,
     155  CLP_PARAM_STR_SPARSEFACTOR,
     156  CLP_PARAM_STR_PRIMALPIVOT,
     157  CLP_PARAM_STR_PRESOLVE,
     158  CLP_PARAM_STR_CRASH,
     159  CLP_PARAM_STR_BIASLU,
     160  CLP_PARAM_STR_PERTURBATION,
     161  CLP_PARAM_STR_MESSAGES,
     162  CLP_PARAM_STR_AUTOSCALE,
     163  CLP_PARAM_STR_CHOLESKY,
     164  CLP_PARAM_STR_KKT,
     165  CLP_PARAM_STR_BARRIERSCALE,
     166  CLP_PARAM_STR_GAMMA,
     167  CLP_PARAM_STR_CROSSOVER,
     168  CLP_PARAM_STR_PFI,
     169  CLP_PARAM_STR_INTPRINT,
     170  CLP_PARAM_STR_VECTOR,
     171  CLP_PARAM_STR_FACTORIZATION,
     172  CLP_PARAM_STR_ALLCOMMANDS,
     173  CLP_PARAM_STR_TIME_MODE,
     174  CLP_PARAM_STR_ABCWANTED,
     175  CLP_PARAM_STR_BUFFER_MODE,
     176
     177  CBC_PARAM_STR_NODESTRATEGY = 301,
     178  CBC_PARAM_STR_BRANCHSTRATEGY,
     179  CBC_PARAM_STR_CUTSSTRATEGY,
     180  CBC_PARAM_STR_HEURISTICSTRATEGY,
     181  CBC_PARAM_STR_GOMORYCUTS,
     182  CBC_PARAM_STR_PROBINGCUTS,
     183  CBC_PARAM_STR_KNAPSACKCUTS,
     184  CBC_PARAM_STR_REDSPLITCUTS,
     185  CBC_PARAM_STR_ROUNDING,
     186  CBC_PARAM_STR_SOLVER,
     187  CBC_PARAM_STR_CLIQUECUTS,
     188  CBC_PARAM_STR_COSTSTRATEGY,
     189  CBC_PARAM_STR_FLOWCUTS,
     190  CBC_PARAM_STR_MIXEDCUTS,
     191  CBC_PARAM_STR_TWOMIRCUTS,
     192  CBC_PARAM_STR_PREPROCESS,
     193  CBC_PARAM_STR_FPUMP,
     194  CBC_PARAM_STR_GREEDY,
     195  CBC_PARAM_STR_COMBINE,
     196  CBC_PARAM_STR_PROXIMITY,
     197  CBC_PARAM_STR_LOCALTREE,
     198  CBC_PARAM_STR_SOS,
     199  CBC_PARAM_STR_LANDPCUTS,
     200  CBC_PARAM_STR_RINS,
     201  CBC_PARAM_STR_RESIDCUTS,
     202  CBC_PARAM_STR_RENS,
     203  CBC_PARAM_STR_DIVINGS,
     204  CBC_PARAM_STR_DIVINGC,
     205  CBC_PARAM_STR_DIVINGF,
     206  CBC_PARAM_STR_DIVINGG,
     207  CBC_PARAM_STR_DIVINGL,
     208  CBC_PARAM_STR_DIVINGP,
     209  CBC_PARAM_STR_DIVINGV,
     210  CBC_PARAM_STR_DINS,
     211  CBC_PARAM_STR_PIVOTANDFIX,
     212  CBC_PARAM_STR_RANDROUND,
     213  CBC_PARAM_STR_NAIVE,
     214  CBC_PARAM_STR_ZEROHALFCUTS,
     215  CBC_PARAM_STR_CPX,
     216  CBC_PARAM_STR_CROSSOVER2,
     217  CBC_PARAM_STR_PIVOTANDCOMPLEMENT,
     218  CBC_PARAM_STR_VND,
     219  CBC_PARAM_STR_LAGOMORYCUTS,
     220  CBC_PARAM_STR_LATWOMIRCUTS,
     221  CBC_PARAM_STR_REDSPLIT2CUTS,
     222  CBC_PARAM_STR_GMICUTS,
     223  CBC_PARAM_STR_CUTOFF_CONSTRAINT,
     224  CBC_PARAM_STR_DW,
     225  CBC_PARAM_STR_ORBITAL,
     226  CBC_PARAM_STR_PREPROCNAMES,
     227  CBC_PARAM_STR_SOSPRIORITIZE,
     228
     229  CLP_PARAM_ACTION_DIRECTORY = 401,
     230  CLP_PARAM_ACTION_DIRSAMPLE,
     231  CLP_PARAM_ACTION_DIRNETLIB,
     232  CBC_PARAM_ACTION_DIRMIPLIB,
     233  CLP_PARAM_ACTION_IMPORT,
     234  CLP_PARAM_ACTION_EXPORT,
     235  CLP_PARAM_ACTION_RESTORE,
     236  CLP_PARAM_ACTION_SAVE,
     237  CLP_PARAM_ACTION_DUALSIMPLEX,
     238  CLP_PARAM_ACTION_PRIMALSIMPLEX,
     239  CLP_PARAM_ACTION_EITHERSIMPLEX,
     240  CLP_PARAM_ACTION_MAXIMIZE,
     241  CLP_PARAM_ACTION_MINIMIZE,
     242  CLP_PARAM_ACTION_EXIT,
     243  CLP_PARAM_ACTION_STDIN,
     244  CLP_PARAM_ACTION_UNITTEST,
     245  CLP_PARAM_ACTION_NETLIB_EITHER,
     246  CLP_PARAM_ACTION_NETLIB_DUAL,
     247  CLP_PARAM_ACTION_NETLIB_PRIMAL,
     248  CLP_PARAM_ACTION_SOLUTION,
     249  CLP_PARAM_ACTION_SAVESOL,
     250  CLP_PARAM_ACTION_TIGHTEN,
     251  CLP_PARAM_ACTION_FAKEBOUND,
     252  CLP_PARAM_ACTION_HELP,
     253  CLP_PARAM_ACTION_PLUSMINUS,
     254  CLP_PARAM_ACTION_NETWORK,
     255  CLP_PARAM_ACTION_ALLSLACK,
     256  CLP_PARAM_ACTION_REVERSE,
     257  CLP_PARAM_ACTION_BARRIER,
     258  CLP_PARAM_ACTION_NETLIB_BARRIER,
     259  CLP_PARAM_ACTION_NETLIB_TUNE,
     260  CLP_PARAM_ACTION_REALLY_SCALE,
     261  CLP_PARAM_ACTION_BASISIN,
     262  CLP_PARAM_ACTION_BASISOUT,
     263  CLP_PARAM_ACTION_SOLVECONTINUOUS,
     264  CLP_PARAM_ACTION_CLEARCUTS,
     265  CLP_PARAM_ACTION_VERSION,
     266  CLP_PARAM_ACTION_STATISTICS,
     267  CLP_PARAM_ACTION_DEBUG,
     268  CLP_PARAM_ACTION_DUMMY,
     269  CLP_PARAM_ACTION_PRINTMASK,
     270  CLP_PARAM_ACTION_OUTDUPROWS,
     271  CLP_PARAM_ACTION_USERCLP,
     272  CLP_PARAM_ACTION_MODELIN,
     273  CLP_PARAM_ACTION_CSVSTATISTICS,
     274  CLP_PARAM_ACTION_STOREDFILE,
     275  CLP_PARAM_ACTION_ENVIRONMENT,
     276  CLP_PARAM_ACTION_PARAMETRICS,
     277  CLP_PARAM_ACTION_GMPL_SOLUTION,
     278  CLP_PARAM_ACTION_RESTORESOL,
     279  CLP_PARAM_ACTION_GUESS,
     280
     281  CBC_PARAM_ACTION_BAB = 501,
     282  CBC_PARAM_ACTION_MIPLIB,
     283  CBC_PARAM_ACTION_STRENGTHEN,
     284  CBC_PARAM_ACTION_PRIORITYIN,
     285  CBC_PARAM_ACTION_MIPSTART,
     286  CBC_PARAM_ACTION_USERCBC,
     287  CBC_PARAM_ACTION_DOHEURISTIC,
     288  CLP_PARAM_ACTION_NEXTBESTSOLUTION,
     289
     290  CBC_PARAM_NOTUSED_OSLSTUFF = 601,
     291  CBC_PARAM_NOTUSED_CBCSTUFF,
     292
     293  CBC_PARAM_NOTUSED_INVALID = 1000
     294};
    295295#include <vector>
    296296#include <string>
     
    300300class CbcOrClpParam {
    301301public:
    302      /**@name Constructor and destructor */
    303      //@{
    304      /// Constructors
    305      CbcOrClpParam (  );
    306      CbcOrClpParam (std::string name, std::string help,
    307                     double lower, double upper, CbcOrClpParameterType type, int display = 2);
    308      CbcOrClpParam (std::string name, std::string help,
    309                     int lower, int upper, CbcOrClpParameterType type, int display = 2);
    310      // Other strings will be added by insert
    311      CbcOrClpParam (std::string name, std::string help, std::string firstValue,
    312                     CbcOrClpParameterType type, int whereUsed = 7, int display = 2);
    313      // Action
    314      CbcOrClpParam (std::string name, std::string help,
    315                     CbcOrClpParameterType type, int whereUsed = 7, int display = 2);
    316      /// Copy constructor.
    317      CbcOrClpParam(const CbcOrClpParam &);
    318      /// Assignment operator. This copies the data
    319      CbcOrClpParam & operator=(const CbcOrClpParam & rhs);
    320      /// Destructor
    321      ~CbcOrClpParam (  );
    322      //@}
    323 
    324      /**@name stuff */
    325      //@{
    326      /// Insert string (only valid for keywords)
    327      void append(std::string keyWord);
    328      /// Adds one help line
    329      void addHelp(std::string keyWord);
    330      /// Returns name
    331      inline std::string  name(  ) const {
    332           return name_;
    333      }
    334      /// Returns short help
    335      inline std::string  shortHelp(  ) const {
    336           return shortHelp_;
    337      }
    338      /// Sets a double parameter (nonzero code if error)
    339      int setDoubleParameter(CbcModel & model, double value) ;
    340      /// Sets double parameter and returns printable string and error code
    341      const char * setDoubleParameterWithMessage ( CbcModel & model, double  value , int & returnCode);
    342      /// Gets a double parameter
    343      double doubleParameter(CbcModel & model) const;
    344      /// Sets a int parameter (nonzero code if error)
    345      int setIntParameter(CbcModel & model, int value) ;
    346      /// Sets int parameter and returns printable string and error code
    347      const char * setIntParameterWithMessage ( CbcModel & model, int value , int & returnCode);
    348      /// Gets a int parameter
    349      int intParameter(CbcModel & model) const;
    350      /// Sets a double parameter (nonzero code if error)
    351      int setDoubleParameter(ClpSimplex * model, double value) ;
    352      /// Gets a double parameter
    353      double doubleParameter(ClpSimplex * model) const;
    354      /// Sets double parameter and returns printable string and error code
    355      const char * setDoubleParameterWithMessage ( ClpSimplex * model, double  value , int & returnCode);
    356      /// Sets a int parameter (nonzero code if error)
    357      int setIntParameter(ClpSimplex * model, int value) ;
    358      /// Sets int parameter and returns printable string and error code
    359      const char * setIntParameterWithMessage ( ClpSimplex * model, int  value , int & returnCode);
    360      /// Gets a int parameter
    361      int intParameter(ClpSimplex * model) const;
    362      /// Sets a double parameter (nonzero code if error)
    363      int setDoubleParameter(OsiSolverInterface * model, double value) ;
    364      /// Sets double parameter and returns printable string and error code
    365      const char * setDoubleParameterWithMessage ( OsiSolverInterface * model, double  value , int & returnCode);
    366      /// Gets a double parameter
    367      double doubleParameter(OsiSolverInterface * model) const;
    368      /// Sets a int parameter (nonzero code if error)
    369      int setIntParameter(OsiSolverInterface * model, int value) ;
    370      /// Sets int parameter and returns printable string and error code
    371      const char * setIntParameterWithMessage ( OsiSolverInterface * model, int  value , int & returnCode);
    372      /// Gets a int parameter
    373      int intParameter(OsiSolverInterface * model) const;
    374      /// Checks a double parameter (nonzero code if error)
    375      int checkDoubleParameter(double value) const;
    376      /// Returns name which could match
    377      std::string matchName (  ) const;
    378      /// Returns length of name for ptinting
    379      int lengthMatchName (  ) const;
    380      /// Returns parameter option which matches (-1 if none)
    381      int parameterOption ( std::string check ) const;
    382      /// Prints parameter options
    383      void printOptions (  ) const;
    384      /// Returns current parameter option
    385      inline std::string currentOption (  ) const {
    386           return definedKeyWords_[currentKeyWord_];
    387      }
    388      /// Sets current parameter option
    389      void setCurrentOption ( int value , bool printIt = false);
    390      /// Sets current parameter option and returns printable string
    391      const char * setCurrentOptionWithMessage ( int value );
    392      /// Sets current parameter option using string
    393      void setCurrentOption (const std::string value );
    394      /// Sets current parameter option using string with message
    395      const char * setCurrentOptionWithMessage (const std::string value );
    396      /// Returns current parameter option position
    397      int currentOptionAsInteger (  ) const ;
    398      /** Returns current parameter option position
     302  /**@name Constructor and destructor */
     303  //@{
     304  /// Constructors
     305  CbcOrClpParam();
     306  CbcOrClpParam(std::string name, std::string help,
     307    double lower, double upper, CbcOrClpParameterType type, int display = 2);
     308  CbcOrClpParam(std::string name, std::string help,
     309    int lower, int upper, CbcOrClpParameterType type, int display = 2);
     310  // Other strings will be added by insert
     311  CbcOrClpParam(std::string name, std::string help, std::string firstValue,
     312    CbcOrClpParameterType type, int whereUsed = 7, int display = 2);
     313  // Action
     314  CbcOrClpParam(std::string name, std::string help,
     315    CbcOrClpParameterType type, int whereUsed = 7, int display = 2);
     316  /// Copy constructor.
     317  CbcOrClpParam(const CbcOrClpParam &);
     318  /// Assignment operator. This copies the data
     319  CbcOrClpParam &operator=(const CbcOrClpParam &rhs);
     320  /// Destructor
     321  ~CbcOrClpParam();
     322  //@}
     323
     324  /**@name stuff */
     325  //@{
     326  /// Insert string (only valid for keywords)
     327  void append(std::string keyWord);
     328  /// Adds one help line
     329  void addHelp(std::string keyWord);
     330  /// Returns name
     331  inline std::string name() const
     332  {
     333    return name_;
     334  }
     335  /// Returns short help
     336  inline std::string shortHelp() const
     337  {
     338    return shortHelp_;
     339  }
     340  /// Sets a double parameter (nonzero code if error)
     341  int setDoubleParameter(CbcModel &model, double value);
     342  /// Sets double parameter and returns printable string and error code
     343  const char *setDoubleParameterWithMessage(CbcModel &model, double value, int &returnCode);
     344  /// Gets a double parameter
     345  double doubleParameter(CbcModel &model) const;
     346  /// Sets a int parameter (nonzero code if error)
     347  int setIntParameter(CbcModel &model, int value);
     348  /// Sets int parameter and returns printable string and error code
     349  const char *setIntParameterWithMessage(CbcModel &model, int value, int &returnCode);
     350  /// Gets a int parameter
     351  int intParameter(CbcModel &model) const;
     352  /// Sets a double parameter (nonzero code if error)
     353  int setDoubleParameter(ClpSimplex *model, double value);
     354  /// Gets a double parameter
     355  double doubleParameter(ClpSimplex *model) const;
     356  /// Sets double parameter and returns printable string and error code
     357  const char *setDoubleParameterWithMessage(ClpSimplex *model, double value, int &returnCode);
     358  /// Sets a int parameter (nonzero code if error)
     359  int setIntParameter(ClpSimplex *model, int value);
     360  /// Sets int parameter and returns printable string and error code
     361  const char *setIntParameterWithMessage(ClpSimplex *model, int value, int &returnCode);
     362  /// Gets a int parameter
     363  int intParameter(ClpSimplex *model) const;
     364  /// Sets a double parameter (nonzero code if error)
     365  int setDoubleParameter(OsiSolverInterface *model, double value);
     366  /// Sets double parameter and returns printable string and error code
     367  const char *setDoubleParameterWithMessage(OsiSolverInterface *model, double value, int &returnCode);
     368  /// Gets a double parameter
     369  double doubleParameter(OsiSolverInterface *model) const;
     370  /// Sets a int parameter (nonzero code if error)
     371  int setIntParameter(OsiSolverInterface *model, int value);
     372  /// Sets int parameter and returns printable string and error code
     373  const char *setIntParameterWithMessage(OsiSolverInterface *model, int value, int &returnCode);
     374  /// Gets a int parameter
     375  int intParameter(OsiSolverInterface *model) const;
     376  /// Checks a double parameter (nonzero code if error)
     377  int checkDoubleParameter(double value) const;
     378  /// Returns name which could match
     379  std::string matchName() const;
     380  /// Returns length of name for ptinting
     381  int lengthMatchName() const;
     382  /// Returns parameter option which matches (-1 if none)
     383  int parameterOption(std::string check) const;
     384  /// Prints parameter options
     385  void printOptions() const;
     386  /// Returns current parameter option
     387  inline std::string currentOption() const
     388  {
     389    return definedKeyWords_[currentKeyWord_];
     390  }
     391  /// Sets current parameter option
     392  void setCurrentOption(int value, bool printIt = false);
     393  /// Sets current parameter option and returns printable string
     394  const char *setCurrentOptionWithMessage(int value);
     395  /// Sets current parameter option using string
     396  void setCurrentOption(const std::string value);
     397  /// Sets current parameter option using string with message
     398  const char *setCurrentOptionWithMessage(const std::string value);
     399  /// Returns current parameter option position
     400  int currentOptionAsInteger() const;
     401  /** Returns current parameter option position
    399402         but if fake keyword returns a fake value and sets
    400403         fakeInteger to true value.  If not fake then fakeInteger is -COIN_INT_MAX
    401404      */
    402      int currentOptionAsInteger ( int & fakeInteger ) const;
    403      /// Sets int value
    404      void setIntValue ( int value );
    405      /// Sets int value with message
    406      const char * setIntValueWithMessage ( int value );
    407      inline int intValue () const {
    408           return intValue_;
    409      }
    410      /// Sets double value
    411      void setDoubleValue ( double value );
    412      /// Sets double value with message
    413      const char * setDoubleValueWithMessage ( double value );
    414      inline double doubleValue () const {
    415           return doubleValue_;
    416      }
    417      /// Sets string value
    418      void setStringValue ( std::string value );
    419      inline std::string stringValue () const {
    420           return stringValue_;
    421      }
    422      /// Returns 1 if matches minimum, 2 if matches less, 0 if not matched
    423      int matches (std::string input) const;
    424      /// type
    425      inline CbcOrClpParameterType type() const {
    426           return type_;
    427      }
    428      /// whether to display
    429      inline int displayThis() const {
    430           return display_;
    431      }
    432      /// Set Long help
    433      inline void setLonghelp(const std::string help) {
    434           longHelp_ = help;
    435      }
    436      /// Print Long help
    437      void printLongHelp() const;
    438      /// Print action and string
    439      void printString() const;
    440      /** 7 if used everywhere,
     405  int currentOptionAsInteger(int &fakeInteger) const;
     406  /// Sets int value
     407  void setIntValue(int value);
     408  /// Sets int value with message
     409  const char *setIntValueWithMessage(int value);
     410  inline int intValue() const
     411  {
     412    return intValue_;
     413  }
     414  /// Sets double value
     415  void setDoubleValue(double value);
     416  /// Sets double value with message
     417  const char *setDoubleValueWithMessage(double value);
     418  inline double doubleValue() const
     419  {
     420    return doubleValue_;
     421  }
     422  /// Sets string value
     423  void setStringValue(std::string value);
     424  inline std::string stringValue() const
     425  {
     426    return stringValue_;
     427  }
     428  /// Returns 1 if matches minimum, 2 if matches less, 0 if not matched
     429  int matches(std::string input) const;
     430  /// type
     431  inline CbcOrClpParameterType type() const
     432  {
     433    return type_;
     434  }
     435  /// whether to display
     436  inline int displayThis() const
     437  {
     438    return display_;
     439  }
     440  /// Set Long help
     441  inline void setLonghelp(const std::string help)
     442  {
     443    longHelp_ = help;
     444  }
     445  /// Print Long help
     446  void printLongHelp() const;
     447  /// Print action and string
     448  void printString() const;
     449  /** 7 if used everywhere,
    441450         1 - used by clp
    442451         2 - used by cbc
    443452         4 - used by ampl
    444453     */
    445      inline int whereUsed() const {
    446           return whereUsed_;
    447      }
    448      /// Gets value of fake keyword
    449      inline int fakeKeyWord() const
    450      { return fakeKeyWord_;}
    451      /// Sets value of fake keyword
    452      inline void setFakeKeyWord(int value, int fakeValue)
    453      { fakeKeyWord_ = value; fakeValue_ = fakeValue;}
    454      /// Sets value of fake keyword to current size of keywords
    455      void setFakeKeyWord(int fakeValue);
     454  inline int whereUsed() const
     455  {
     456    return whereUsed_;
     457  }
     458  /// Gets value of fake keyword
     459  inline int fakeKeyWord() const
     460  {
     461    return fakeKeyWord_;
     462  }
     463  /// Sets value of fake keyword
     464  inline void setFakeKeyWord(int value, int fakeValue)
     465  {
     466    fakeKeyWord_ = value;
     467    fakeValue_ = fakeValue;
     468  }
     469  /// Sets value of fake keyword to current size of keywords
     470  void setFakeKeyWord(int fakeValue);
    456471
    457472private:
    458      /// gutsOfConstructor
    459      void gutsOfConstructor();
    460      //@}
    461 ////////////////// data //////////////////
     473  /// gutsOfConstructor
     474  void gutsOfConstructor();
     475  //@}
     476  ////////////////// data //////////////////
    462477private:
    463 
    464      /**@name data
     478  /**@name data
    465479      We might as well throw all type data in - could derive?
    466480     */
    467      //@{
    468      // Type see CbcOrClpParameterType
    469      CbcOrClpParameterType type_;
    470      /// If double == okay
    471      double lowerDoubleValue_;
    472      double upperDoubleValue_;
    473      /// If int == okay
    474      int lowerIntValue_;
    475      int upperIntValue_;
    476      // Length of name
    477      unsigned int lengthName_;
    478      // Minimum match
    479      unsigned int lengthMatch_;
    480      /// set of valid strings
    481      std::vector<std::string> definedKeyWords_;
    482      /// Name
    483      std::string name_;
    484      /// Short help
    485      std::string shortHelp_;
    486      /// Long help
    487      std::string longHelp_;
    488      /// Action
    489      CbcOrClpParameterType action_;
    490      /// Current keyWord (if a keyword parameter)
    491      int currentKeyWord_;
    492      /// Display on ?
    493      int display_;
    494      /// Integer parameter - current value
    495      int intValue_;
    496      /// Double parameter - current value
    497      double doubleValue_;
    498      /// String parameter - current value
    499      std::string stringValue_;
    500      /** 7 if used everywhere,
     481  //@{
     482  // Type see CbcOrClpParameterType
     483  CbcOrClpParameterType type_;
     484  /// If double == okay
     485  double lowerDoubleValue_;
     486  double upperDoubleValue_;
     487  /// If int == okay
     488  int lowerIntValue_;
     489  int upperIntValue_;
     490  // Length of name
     491  unsigned int lengthName_;
     492  // Minimum match
     493  unsigned int lengthMatch_;
     494  /// set of valid strings
     495  std::vector< std::string > definedKeyWords_;
     496  /// Name
     497  std::string name_;
     498  /// Short help
     499  std::string shortHelp_;
     500  /// Long help
     501  std::string longHelp_;
     502  /// Action
     503  CbcOrClpParameterType action_;
     504  /// Current keyWord (if a keyword parameter)
     505  int currentKeyWord_;
     506  /// Display on ?
     507  int display_;
     508  /// Integer parameter - current value
     509  int intValue_;
     510  /// Double parameter - current value
     511  double doubleValue_;
     512  /// String parameter - current value
     513  std::string stringValue_;
     514  /** 7 if used everywhere,
    501515         1 - used by clp
    502516         2 - used by cbc
    503517         4 - used by ampl
    504518     */
    505      int whereUsed_;
    506      /** If >=0 then integers allowed as a fake keyword
     519  int whereUsed_;
     520  /** If >=0 then integers allowed as a fake keyword
    507521         So minusnnnn would got to -nnnn in currentKeyword_
    508522         and plusnnnn would go to fakeKeyword_+nnnn
    509523     */
    510      int fakeKeyWord_;
    511      /// Return this as main value if an integer
    512      int fakeValue_;
    513      //@}
     524  int fakeKeyWord_;
     525  /// Return this as main value if an integer
     526  int fakeValue_;
     527  //@}
    514528};
    515529/// Simple read stuff
     
    519533std::string CoinReadGetString(int argc, const char *argv[]);
    520534// valid 0 - okay, 1 bad, 2 not there
    521 int CoinReadGetIntField(int argc, const char *argv[], int * valid);
    522 double CoinReadGetDoubleField(int argc, const char *argv[], int * valid);
    523 void CoinReadPrintit(const char * input);
     535int CoinReadGetIntField(int argc, const char *argv[], int *valid);
     536double CoinReadGetDoubleField(int argc, const char *argv[], int *valid);
     537void CoinReadPrintit(const char *input);
    524538void setCbcOrClpPrinting(bool yesNo);
    525539#define CBCMAXPARAMETERS 250
     
    528542  class CbcOrClpParam for details. Pulled from C..Main() for clarity.
    529543*/
    530 void establishParams (int &numberParameters, CbcOrClpParam *const parameters);
     544void establishParams(int &numberParameters, CbcOrClpParam *const parameters);
    531545// Given a parameter type - returns its number in list
    532 int whichParam (CbcOrClpParameterType name,
    533                 int numberParameters, CbcOrClpParam *const parameters);
     546int whichParam(CbcOrClpParameterType name,
     547  int numberParameters, CbcOrClpParam *const parameters);
    534548// Dump/restore a solution to file
    535 void saveSolution(const ClpSimplex * lpSolver, std::string fileName);
    536 void restoreSolution(ClpSimplex * lpSolver, std::string fileName, int mode);
    537 #endif  /* CbcOrClpParam_H */
     549void saveSolution(const ClpSimplex *lpSolver, std::string fileName);
     550void restoreSolution(ClpSimplex *lpSolver, std::string fileName, int mode);
     551#endif /* CbcOrClpParam_H */
     552
     553/* vi: softtabstop=2 shiftwidth=2 expandtab tabstop=2
     554*/
Note: See TracChangeset for help on using the changeset viewer.