Clp trunk
ClpDualRowPivot.hpp
Go to the documentation of this file.
00001 /* $Id$ */
00002 // Copyright (C) 2002, International Business Machines
00003 // Corporation and others.  All Rights Reserved.
00004 // This code is licensed under the terms of the Eclipse Public License (EPL).
00005 
00006 #ifndef ClpDualRowPivot_H
00007 #define ClpDualRowPivot_H
00008 
00009 class ClpSimplex;
00010 class CoinIndexedVector;
00011 
00012 //#############################################################################
00013 
00022 class ClpDualRowPivot  {
00023 
00024 public:
00025 
00027 
00028 
00030      virtual int pivotRow() = 0;
00031 
00034      virtual double updateWeights(CoinIndexedVector * input,
00035                                   CoinIndexedVector * spare,
00036                                   CoinIndexedVector * spare2,
00037                                   CoinIndexedVector * updatedColumn) = 0;
00038 
00045      /* FIXME: this was pure virtul (=0). Why? */
00046      virtual void updatePrimalSolution(CoinIndexedVector * input,
00047                                        double theta,
00048                                        double & changeInObjective) = 0;
00059      virtual void saveWeights(ClpSimplex * model, int mode);
00061      virtual void checkAccuracy();
00063      virtual void unrollWeights();
00065      virtual void clearArrays();
00067      virtual bool looksOptimal() const {
00068           return false;
00069      }
00071      virtual void maximumPivotsChanged() {}
00073 
00074 
00076 
00077 
00078      ClpDualRowPivot();
00079 
00081      ClpDualRowPivot(const ClpDualRowPivot &);
00082 
00084      ClpDualRowPivot & operator=(const ClpDualRowPivot& rhs);
00085 
00087      virtual ~ClpDualRowPivot ();
00088 
00090      virtual ClpDualRowPivot * clone(bool copyData = true) const = 0;
00091 
00093 
00095 
00096 
00097      inline ClpSimplex * model() {
00098           return model_;
00099      }
00100 
00102      inline void setModel(ClpSimplex * newmodel) {
00103           model_ = newmodel;
00104      }
00105 
00107      inline int type() {
00108           return type_;
00109      }
00110 
00112 
00113      //---------------------------------------------------------------------------
00114 
00115 protected:
00117 
00118 
00119      ClpSimplex * model_;
00121      int type_;
00123 };
00124 
00125 #endif
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines