Ignore:
Timestamp:
Apr 10, 2008 1:55:10 PM (13 years ago)
Author:
ladanyi
Message:

Incorporated changes from branches/heur

File:
1 edited

Legend:

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

    r904 r912  
    779779  }
    780780}
     781
     782/** Compare the \c this with \c brObj. \c this and \c brObj must be os the
     783    same type and must have the same original object, but they may have
     784    different feasible regions.
     785    Return the appropriate CbcRangeCompare value (first argument being the
     786    sub/superset if that's the case). In case of overlap (and if \c
     787    replaceIfOverlap is true) replace the current branching object with one
     788    whose feasible region is the overlap.
     789*/
     790CbcRangeCompare
     791CbcLotsizeBranchingObject::compareBranchingObject
     792(const CbcBranchingObject* brObj, const bool replaceIfOverlap)
     793{
     794  const CbcLotsizeBranchingObject* br =
     795    dynamic_cast<const CbcLotsizeBranchingObject*>(brObj);
     796  assert(br);
     797  double* thisBd = way_ == -1 ? down_ : up_;
     798  const double* otherBd = br->way_ == -1 ? br->down_ : br->up_;
     799  return CbcCompareRanges(thisBd, otherBd, replaceIfOverlap);
     800}
Note: See TracChangeset for help on using the changeset viewer.