Ignore:
Timestamp:
Mar 19, 2013 9:04:43 AM (6 years ago)
Author:
forrest
Message:

changes for cuts and extra variables

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Cbc/src/CbcModel.cpp

    r1867 r1876  
    21532153                handler_->message(CBC_HEURISTICS_OFF, messages_) << numberOdd << CoinMessageEol ;
    21542154            }
     2155            // If odd switch off AddIntegers
     2156            specialOptions_ &= ~65536;
    21552157        } else if (numberSOS) {
    21562158            specialOptions_ |= 128; // say can do SOS in dynamic mode
     
    36953697              Decide if we want to do a restart.
    36963698            */
    3697             if (saveSolver) {
     3699            if (saveSolver && (specialOptions_&(512 + 32768)) != 0) {
    36983700                bool tryNewSearch = solverCharacteristics_->reducedCostsAccurate() &&
    36993701                                    (getCutoff() < 1.0e20 && getCutoff() < checkCutoffForRestart);
     
    1406614068// Set original columns as created by preprocessing
    1406714069void
    14068 CbcModel::setOriginalColumns(const int * originalColumns)
     14070CbcModel::setOriginalColumns(const int * originalColumns,int numberGood)
    1406914071{
    1407014072    int numberColumns = getNumCols();
    1407114073    delete [] originalColumns_;
    14072     originalColumns_ = CoinCopyOfArray(originalColumns, numberColumns);
     14074    originalColumns_ = new int [numberColumns];
     14075    int numberCopy=CoinMin(numberColumns,numberGood);
     14076    memcpy(originalColumns_,originalColumns,numberCopy*sizeof(int));
     14077    for (int i=numberCopy;i<numberColumns;i++)
     14078      originalColumns_[i]=-1;
    1407314079}
    1407414080// Set the cut modifier method
Note: See TracChangeset for help on using the changeset viewer.