• Main Page
  • Namespaces
  • Classes
  • Files
  • File List
  • File Members

/build/buildd/coinor-cgl-0.55.0/Cgl/src/CglGomory/CglGomory.hpp

Go to the documentation of this file.
00001 // Copyright (C) 2002, International Business Machines
00002 // Corporation and others.  All Rights Reserved.
00003 #ifndef CglGomory_H
00004 #define CglGomory_H
00005 
00006 #include <string>
00007 
00008 #include "CglCutGenerator.hpp"
00009 
00010 class CoinWarmStartBasis;
00012 class CglGomory : public CglCutGenerator {
00013    friend void CglGomoryUnitTest(const OsiSolverInterface * siP,
00014                                   const std::string mpdDir );
00015  
00016 public:
00017     
00018   
00032   virtual void generateCuts( const OsiSolverInterface & si, OsiCuts & cs,
00033                              const CglTreeInfo info = CglTreeInfo()) const;
00036   int generateCuts( const OsiRowCutDebugger * debugger, 
00037                     OsiCuts & cs,
00038                     const CoinPackedMatrix & columnCopy,
00039                     const CoinPackedMatrix & rowCopy,
00040                     const double * colsol,
00041                     const double * colLower, const double * colUpper,
00042                     const double * rowLower, const double * rowUpper,
00043                     const char * intVar ,
00044                     const CoinWarmStartBasis* warm,
00045                     const CglTreeInfo info = CglTreeInfo()) const;
00048   int generateCuts( const OsiRowCutDebugger * debugger, 
00049                     OsiCuts & cs,
00050                     const CoinPackedMatrix & columnCopy,
00051                     const double * colsol,
00052                     const double * colLower, const double * colUpper,
00053                     const double * rowLower, const double * rowUpper,
00054                     const char * intVar ,
00055                     const CoinWarmStartBasis* warm,
00056                     const CglTreeInfo info = CglTreeInfo()) const;
00057 
00059   virtual bool needsOptimalBasis() const;
00061 
00064 
00065   void setLimit(int limit);
00067   int getLimit() const;
00069   void setLimitAtRoot(int limit);
00071   int getLimitAtRoot() const;
00073   virtual int maximumLengthOfCutInTree() const;
00075 
00080 
00081   void setAway(double value);
00083   double getAway() const;
00085   void setAwayAtRoot(double value);
00087   double getAwayAtRoot() const;
00089 
00099 
00100   void setConditionNumberMultiplier(double value);
00102   double getConditionNumberMultiplier() const;
00104   void setLargestFactorMultiplier(double value);
00106   double getLargestFactorMultiplier() const;
00108 
00111 
00112   inline void useAlternativeFactorization(bool yes=true)
00113   { alternateFactorization_= (yes) ? 1 : 0;} 
00115   inline bool alternativeFactorization() const
00116   { return (alternateFactorization_!=0);} 
00118 
00121 
00122   CglGomory ();
00123  
00125   CglGomory (
00126     const CglGomory &);
00127 
00129   virtual CglCutGenerator * clone() const;
00130 
00132   CglGomory &
00133     operator=(
00134     const CglGomory& rhs);
00135   
00137   virtual
00138     ~CglGomory ();
00140   virtual std::string generateCpp( FILE * fp);
00142       
00143 private:
00144   
00145  // Private member methods
00146 
00147   // Private member data
00148 
00151 
00152   double away_;
00154   double awayAtRoot_;
00156   double conditionNumberMultiplier_;
00158   double largestFactorMultiplier_;
00160   int limit_;
00162   int limitAtRoot_;
00164   mutable int dynamicLimitInTree_;
00166   mutable int numberTimesStalled_;
00168   int alternateFactorization_;
00170 };
00171 
00172 //#############################################################################
00178 void CglGomoryUnitTest(const OsiSolverInterface * siP,
00179                         const std::string mpdDir );
00180   
00181 #endif

Generated on Fri Aug 20 2010 23:58:04 for coin-Cgl by  doxygen 1.7.1