Changeset 2385 for trunk/Clp/src/AbcDualRowSteepest.hpp
 Timestamp:
 Jan 6, 2019 2:43:06 PM (19 months ago)
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

trunk/Clp/src/AbcDualRowSteepest.hpp
r1910 r2385 10 10 class CoinIndexedVector; 11 11 12 13 12 //############################################################################# 14 13 … … 20 19 21 20 class AbcDualRowSteepest : public AbcDualRowPivot { 22 21 23 22 public: 24 25 23 ///@name Algorithmic methods 26 24 //@{ 27 25 28 26 /// Returns pivot row, 1 if none 29 27 virtual int pivotRow(); 30 28 31 29 /** Updates weights and returns pivot alpha. 32 30 Also does FT update */ 33 virtual double updateWeights(CoinIndexedVector & input,CoinIndexedVector &updatedColumn);34 virtual double updateWeights1(CoinIndexedVector & input,CoinIndexedVector &updateColumn);35 virtual void updateWeightsOnly(CoinIndexedVector & 31 virtual double updateWeights(CoinIndexedVector &input, CoinIndexedVector &updatedColumn); 32 virtual double updateWeights1(CoinIndexedVector &input, CoinIndexedVector &updateColumn); 33 virtual void updateWeightsOnly(CoinIndexedVector &input); 36 34 /// Actually updates weights 37 virtual void updateWeights2(CoinIndexedVector & input,CoinIndexedVector &updateColumn);38 35 virtual void updateWeights2(CoinIndexedVector &input, CoinIndexedVector &updateColumn); 36 39 37 /** Updates primal solution (and maybe list of candidates) 40 38 Uses input vector which it deletes 41 39 */ 42 virtual void updatePrimalSolution(CoinIndexedVector & 43 44 45 virtual void updatePrimalSolutionAndWeights(CoinIndexedVector & 46 CoinIndexedVector &updateColumn,47 40 virtual void updatePrimalSolution(CoinIndexedVector &input, 41 double theta); 42 43 virtual void updatePrimalSolutionAndWeights(CoinIndexedVector &weightsVector, 44 CoinIndexedVector &updateColumn, 45 double theta); 48 46 /** Saves any weights round factorization as pivot rows may change 49 47 Save model … … 56 54 5) for strong branching  initialize (uninitialized) , infeasibilities 57 55 */ 58 virtual void saveWeights(AbcSimplex * 56 virtual void saveWeights(AbcSimplex *model, int mode); 59 57 /// Recompute infeasibilities 60 58 virtual void recomputeInfeasibilities(); … … 64 62 virtual bool looksOptimal() const; 65 63 //@} 66 64 67 65 /** enums for persistence 68 66 */ … … 71 69 keep = 0x01 // create (if necessary) and leave 72 70 }; 73 71 74 72 ///@name Constructors and destructors 75 73 //@{ … … 82 80 */ 83 81 AbcDualRowSteepest(int mode = 3); 84 82 85 83 /// Copy constructor 86 84 AbcDualRowSteepest(const AbcDualRowSteepest &); 87 85 88 86 /// Assignment operator 89 AbcDualRowSteepest & operator=(const AbcDualRowSteepest&rhs);90 87 AbcDualRowSteepest &operator=(const AbcDualRowSteepest &rhs); 88 91 89 /// Fill most values 92 void fill(const AbcDualRowSteepest &rhs);93 90 void fill(const AbcDualRowSteepest &rhs); 91 94 92 /// Destructor 95 virtual ~AbcDualRowSteepest 96 93 virtual ~AbcDualRowSteepest(); 94 97 95 /// Clone 98 virtual AbcDualRowPivot * 99 96 virtual AbcDualRowPivot *clone(bool copyData = true) const; 97 100 98 //@} 101 99 /**@name gets and sets */ 102 100 //@{ 103 101 /// Mode 104 inline int mode() const { 102 inline int mode() const 103 { 105 104 return mode_; 106 105 } 107 106 /// Set/ get persistence 108 inline void setPersistence(Persistence life) { 107 inline void setPersistence(Persistence life) 108 { 109 109 persistence_ = life; 110 110 } 111 inline Persistence persistence() const { 112 return persistence_ ; 111 inline Persistence persistence() const 112 { 113 return persistence_; 113 114 } 114 115 /// Infeasible vector 115 inline CoinIndexedVector * infeasible() const 116 { return infeasible_;} 116 inline CoinIndexedVector *infeasible() const 117 { 118 return infeasible_; 119 } 117 120 /// Weights vector 118 inline CoinIndexedVector * weights() const 119 { return weights_;} 121 inline CoinIndexedVector *weights() const 122 { 123 return weights_; 124 } 120 125 /// Model 121 inline AbcSimplex * model() const 122 { return model_;} 126 inline AbcSimplex *model() const 127 { 128 return model_; 129 } 123 130 //@} 124 131 125 132 // 126 133 127 134 private: 128 135 ///@name Private member data … … 143 150 Persistence persistence_; 144 151 /// weight array 145 CoinIndexedVector * 152 CoinIndexedVector *weights_; 146 153 /// square of infeasibility array (just for infeasible rows) 147 CoinIndexedVector * 154 CoinIndexedVector *infeasible_; 148 155 /// save weight array (so we can use checkpoint) 149 CoinIndexedVector * 156 CoinIndexedVector *savedWeights_; 150 157 //@} 151 158 }; … … 156 163 #define DEVEX_ADD_ONE 1.0 157 164 #endif 165 166 /* vi: softtabstop=2 shiftwidth=2 expandtab tabstop=2 167 */
Note: See TracChangeset
for help on using the changeset viewer.