00001 /*===========================================================================* 00002 * This file is part of the Bcps Linear Solver (BLIS). * 00003 * * 00004 * ALPS is distributed under the Common Public License as part of the * 00005 * COIN-OR repository (http://www.coin-or.org). * 00006 * * 00007 * Authors: * 00008 * * 00009 * Yan Xu, Lehigh University * 00010 * Ted Ralphs, Lehigh University * 00011 * * 00012 * Conceptual Design: * 00013 * * 00014 * Yan Xu, Lehigh University * 00015 * Ted Ralphs, Lehigh University * 00016 * Laszlo Ladanyi, IBM T.J. Watson Research Center * 00017 * Matthew Saltzman, Clemson University * 00018 * * 00019 * * 00020 * Copyright (C) 2001-2005, International Business Machines * 00021 * Corporation, Lehigh University, Yan Xu, Ted Ralphs, Matthew Salzman and * 00022 * others. All Rights Reserved. * 00023 *===========================================================================*/ 00024 00025 00026 //############################################################################# 00027 // NOTE: Borrow ideas from COIN/Cbc 00028 //############################################################################# 00029 00030 00031 #ifndef BlisBranchStrategyStrong_h_ 00032 #define BlisBranchStrategyStrong_h_ 00033 00034 #include "BcpsBranchObject.h" 00035 #include "BcpsBranchStrategy.h" 00036 #include "BlisModel.h" 00037 00038 00039 //############################################################################# 00040 00041 00042 typedef struct { 00043 int objectIndex; // object index 00044 BcpsBranchObject * bObject; // the branching object 00045 int numIntInfUp; // without odd ones 00046 int numObjInfUp; // just odd ones 00047 bool finishedUp; // true if solver finished 00048 int numIntInfDown; // without odd ones 00049 int numObjInfDown; // just odd ones 00050 bool finishedDown; // true if solver finished 00051 } BlisStrong; 00052 00053 00054 //############################################################################# 00055 00056 00060 class BlisBranchStrategyStrong : public BcpsBranchStrategy { 00061 00062 private: 00063 00065 BlisBranchStrategyStrong& operator=(const BlisBranchStrategyStrong& rhs); 00066 00067 public: 00068 00070 BlisBranchStrategyStrong() {} 00071 00073 BlisBranchStrategyStrong(BlisModel *model) 00074 : BcpsBranchStrategy(model) 00075 {} 00076 00078 virtual ~BlisBranchStrategyStrong() {} 00079 00081 BlisBranchStrategyStrong(const BlisBranchStrategyStrong &); 00082 00084 virtual BcpsBranchStrategy * clone() const { 00085 return new BlisBranchStrategyStrong(*this); 00086 } 00087 00089 virtual int createCandBranchObjects(int numPassesLeft); 00090 00096 virtual int betterBranchObject(BcpsBranchObject * thisOne, 00097 BcpsBranchObject * bestSoFar); 00098 }; 00099 00100 #endif