Changeset 266


Ignore:
Timestamp:
Mar 7, 2006 5:04:29 PM (14 years ago)
Author:
forrest
Message:

for bon-min

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/CbcModel.cpp

    r265 r266  
    547547    secondaryStatus_ = 1;
    548548    originalContinuousObjective_ = COIN_DBL_MAX;
     549    solverCharacteristics_ = NULL;
    549550    return ; }
    550551  // Save objective (just so user can access it)
     
    768769    double newObjValue = direction*solver_->getObjValue();
    769770    if (newObjValue!=solverCharacteristics_->mipBound()) {
    770       newObjValue = CoinMin(newObjValue,solverCharacteristics_->mipBound());
     771      newObjValue = CoinMax(newObjValue,solverCharacteristics_->mipBound());
    771772      solverCharacteristics_->setMipBound(-COIN_DBL_MAX);
    772773    }
     
    11721173          }
    11731174          if (numberUnsatisfied)   {
    1174             feasible = solveWithCuts(cuts,maximumCutPassesAtRoot_,
    1175                                      NULL);
     1175            feasible = solveWithCuts(cuts,maximumCutPasses_,node);
    11761176          } else {
    11771177            // may generate cuts and turn the solution
    11781178            //to an infeasible one
    11791179            feasible = solveWithCuts(cuts, 1,
    1180                                      NULL);
     1180                                     node);
    11811181#if 0
    11821182            currentNumberCuts_ = cuts.sizeRowCuts();
     
    12501250          double newObjValue = direction*solver_->getObjValue();
    12511251          if (newObjValue!=solverCharacteristics_->mipBound()) {
    1252             newObjValue = CoinMin(newObjValue,solverCharacteristics_->mipBound());
     1252            newObjValue = CoinMax(newObjValue,solverCharacteristics_->mipBound());
    12531253            solverCharacteristics_->setMipBound(-COIN_DBL_MAX);
    12541254          }
     
    17431743      continuousSolver_->initialSolve() ; }
    17441744    delete solver_ ;
     1745    // above deletes solverCharacteristics_
     1746    solverCharacteristics_ = NULL;
    17451747    solver_ = continuousSolver_ ;
    17461748    setPointers(solver_);
     
    21092111    double newObjValue = direction*solver_->getObjValue();
    21102112    if (newObjValue!=solverCharacteristics_->mipBound()) {
    2111       newObjValue = CoinMin(newObjValue,solverCharacteristics_->mipBound());
     2113      newObjValue = CoinMax(newObjValue,solverCharacteristics_->mipBound());
    21122114      solverCharacteristics_->setMipBound(-COIN_DBL_MAX);
    21132115    }
     
    52475249        if (ifSol>0) {
    52485250          // better solution found
    5249           found = i ;
     5251          found = i-numberCutGenerators_ ;
    52505252          incrementUsed(newSolution);
    52515253        } else if (ifSol<0) {
     
    88868888  cbcRowPrice_ = solver_->getRowPrice();
    88878889  /// Get a pointer to array[getNumCols()] (for speed) of reduced costs
    8888   if(solverCharacteristics_->reducedCostsAccurate())
     8890  if(solverCharacteristics_&&solverCharacteristics_->reducedCostsAccurate())
    88898891    cbcReducedCost_ = solver_->getReducedCost();
    88908892  else
Note: See TracChangeset for help on using the changeset viewer.