- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- File List
- File Members

CoinSimpFactorization.hpp
Go to the documentation of this file.
1 /* $Id: CoinSimpFactorization.hpp 1416 2011-04-17 09:57:29Z stefan $ */
2 // Copyright (C) 2008, International Business Machines
3 // Corporation and others. All Rights Reserved.
4 // This code is licensed under the terms of the Eclipse Public License (EPL).
5
6 /*
7 This is a simple factorization of the LP Basis
8 */
9 #ifndef CoinSimpFactorization_H
10 #define CoinSimpFactorization_H
11
12 #include <iostream>
13 #include <string>
14 #include <cassert>
15 #include "CoinTypes.hpp"
16 #include "CoinIndexedVector.hpp"
17 #include "CoinDenseFactorization.hpp"
18 class CoinPackedMatrix;
19
20
22 class FactorPointers{
23 public:
24 double *rowMax;
25 int *firstRowKnonzeros;
26 int *prevRow;
27 int *nextRow;
28 int *firstColKnonzeros;
29 int *prevColumn;
30 int *nextColumn;
31 int *newCols;
32 //constructor
33 FactorPointers( int numRows, int numCols, int *UrowLengths_, int *UcolLengths_ );
34 // destructor
35 ~ FactorPointers();
36 };
37
38 class CoinSimpFactorization : public CoinOtherFactorization {
39 friend void CoinSimpFactorizationUnitTest( const std::string & mpsDir );
40
41 public:
42
45 CoinSimpFactorization ( );
48 CoinSimpFactorization ( const CoinSimpFactorization &other);
49
51 virtual ~CoinSimpFactorization ( );
53 CoinSimpFactorization & operator = ( const CoinSimpFactorization & other );
55 virtual CoinOtherFactorization * clone() const ;
57
60 virtual void getAreas ( int numberRows,
62 int numberColumns,
63 CoinBigIndex maximumL,
64 CoinBigIndex maximumU );
65
67 virtual void preProcess ( );
73 virtual int factor ( );
75 virtual void postProcess(const int * sequence, int * pivotVariable);
77 virtual void makeNonSingular(int * sequence, int numberColumns);
79
82 virtual inline int numberElements ( ) const {
84 return numberRows_*(numberColumns_+numberPivots_);
85 }
87 double maximumCoefficient() const;
89
92
100 virtual int replaceColumn ( CoinIndexedVector * regionSparse,
101 int pivotRow,
102 double pivotCheck ,
103 bool checkBeforeModifying=false,
104 double acceptablePivot=1.0e-8);
106
117 virtual int updateColumnFT ( CoinIndexedVector * regionSparse,
118 CoinIndexedVector * regionSparse2,
119 bool noPermute=false);
120
123 virtual int updateColumn ( CoinIndexedVector * regionSparse,
124 CoinIndexedVector * regionSparse2,
125 bool noPermute=false) const;
127 virtual int updateTwoColumnsFT(CoinIndexedVector * regionSparse1,
128 CoinIndexedVector * regionSparse2,
129 CoinIndexedVector * regionSparse3,
130 bool noPermute=false);
132 int upColumn ( CoinIndexedVector * regionSparse,
133 CoinIndexedVector * regionSparse2,
134 bool noPermute=false, bool save=false) const;
139 virtual int updateColumnTranspose ( CoinIndexedVector * regionSparse,
140 CoinIndexedVector * regionSparse2) const;
142 int upColumnTranspose ( CoinIndexedVector * regionSparse,
143 CoinIndexedVector * regionSparse2) const;
145
150 inline void clearArrays()
152 { gutsOfDestructor();}
154 inline int * indices() const
155 { return reinterpret_cast<int *> (elements_+numberRows_*numberRows_);}
157 virtual inline int * permute() const
158 { return pivotRow_;}
160
162 void gutsOfDestructor();
164 void gutsOfInitialize();
166 void gutsOfCopy(const CoinSimpFactorization &other);
167
168
170 void factorize(int numberOfRows,
171 int numberOfColumns,
172 const int colStarts[],
173 const int indicesRow[],
174 const double elements[]);
176 int mainLoopFactor (FactorPointers &pointers );
178 void copyLbyRows();
180 void copyUbyColumns();
182 int findPivot(FactorPointers &pointers, int &r, int &s, bool &ifSlack);
184 int findPivotShCol(FactorPointers &pointers, int &r, int &s);
186 int findPivotSimp(FactorPointers &pointers, int &r, int &s);
188 void GaussEliminate(FactorPointers &pointers, int &r, int &s);
190 int findShortRow(const int column, const int length, int &minRow,
191 int &minRowLength, FactorPointers &pointers);
193 int findShortColumn(const int row, const int length, int &minCol,
194 int &minColLength, FactorPointers &pointers);
196 double findMaxInRrow(const int row, FactorPointers &pointers);
198 void pivoting(const int pivotRow, const int pivotColumn,
199 const double invPivot, FactorPointers &pointers);
201 void updateCurrentRow(const int pivotRow, const int row,
202 const double multiplier, FactorPointers &pointers,
203 int &newNonZeros);
205 void increaseLsize();
207 void increaseRowSize(const int row, const int newSize);
209 void increaseColSize(const int column, const int newSize, const bool b);
211 void enlargeUrow(const int numNewElements);
213 void enlargeUcol(const int numNewElements, const bool b);
215 int findInRow(const int row, const int column);
217 int findInColumn(const int column, const int row);
219 void removeRowFromActSet(const int row, FactorPointers &pointers);
221 void removeColumnFromActSet(const int column, FactorPointers &pointers);
223 void allocateSpaceForU();
225 void allocateSomeArrays();
227 void initialSomeNumbers();
229 void Lxeqb(double *b) const;
231 void Lxeqb2(double *b1, double *b2) const;
233 void Uxeqb(double *b, double *sol) const;
235 void Uxeqb2(double *b1, double *sol1, double *sol2, double *b2) const;
237 void xLeqb(double *b) const;
239 void xUeqb(double *b, double *sol) const;
241 int LUupdate(int newBasicCol);
243 void newEta(int row, int numNewElements);
245 void copyRowPermutations();
247 void Hxeqb(double *b) const;
249 void Hxeqb2(double *b1, double *b2) const;
251 void xHeqb(double *b) const;
253 void ftran(double *b, double *sol, bool save) const;
255 void ftran2(double *b1, double *sol1, double *b2, double *sol2) const;
257 void btran(double *b, double *sol) const;
259
260
261
263 protected:
266 int checkPivot(double saveFromU, double oldPivot) const;
268 protected:
269
272 double *denseVector_;
275 double *workArea2_;
277 double *workArea3_;
279 int *vecLabels_;
281 int *indVector_;
282
284 double *auxVector_;
286 int *auxInd_;
287
289 double *vecKeep_;
291 int *indKeep_;
293 mutable int keepSize_;
294
295
296
298 int *LrowStarts_;
300 int *LrowLengths_;
302 double *Lrows_;
304 int *LrowInd_;
306 int LrowSize_;
308 int LrowCap_;
309
311 int *LcolStarts_;
313 int *LcolLengths_;
315 double *Lcolumns_;
317 int *LcolInd_;
319 int LcolSize_;
321 int LcolCap_;
322
323
325 int *UrowStarts_;
327 int *UrowLengths_;
328 #ifdef COIN_SIMP_CAPACITY
329 int *UrowCapacities_;
331 #endif
332 double *Urows_;
335 int *UrowInd_;
337 int UrowMaxCap_;
339 int UrowEnd_;
341 int firstRowInU_;
343 int lastRowInU_;
345 int *prevRowInU_;
347 int *nextRowInU_;
348
350 int *UcolStarts_;
352 int *UcolLengths_;
353 #ifdef COIN_SIMP_CAPACITY
354 int *UcolCapacities_;
356 #endif
357 double *Ucolumns_;
360 int *UcolInd_;
362 int *prevColInU_;
364 int *nextColInU_;
366 int firstColInU_;
368 int lastColInU_;
370 int UcolMaxCap_;
372 int UcolEnd_;
374 int *colSlack_;
375
377 double *invOfPivots_;
378
380 int *colOfU_;
382 int *colPosition_;
384 int *rowOfU_;
386 int *rowPosition_;
388 int *secRowOfU_;
390 int *secRowPosition_;
391
393 int *EtaPosition_;
395 int *EtaStarts_;
397 int *EtaLengths_;
399 int *EtaInd_;
401 double *Eta_;
403 int EtaSize_;
405 int lastEtaRow_;
407 int maxEtaRows_;
409 int EtaMaxCap_;
410
412 int minIncrease_;
414 double updateTol_;
416 bool doSuhlHeuristic_;
418 double maxU_;
420 double maxGrowth_;
422 double maxA_;
424 int pivotCandLimit_;
426 int numberSlacks_;
428 int firstNumberSlacks_;
430 };
431 #endif
CoinSimpFactorization::doSuhlHeuristic_
bool doSuhlHeuristic_
do Shul heuristic
Definition: CoinSimpFactorization.hpp:416
CoinSimpFactorization::Uxeqb2
void Uxeqb2(double *b1, double *sol1, double *sol2, double *b2) const
same as above but with two rhs
CoinSimpFactorization::maxEtaRows_
int maxEtaRows_
maximum number of eta vectors
Definition: CoinSimpFactorization.hpp:407
CoinBigIndex
int CoinBigIndex
Definition: Coin_C_defines.h:105
FactorPointers::prevColumn
int * prevColumn
Definition: CoinSimpFactorization.hpp:29
CoinSimpFactorization::Ucolumns_
double * Ucolumns_
U by columns.
Definition: CoinSimpFactorization.hpp:358
CoinSimpFactorization::increaseColSize
void increaseColSize(const int column, const int newSize, const bool b)
allocates more space for a column of U
CoinSimpFactorization::gutsOfInitialize
void gutsOfInitialize()
The real work of constructor.
CoinSimpFactorization
Definition: CoinSimpFactorization.hpp:38
CoinSimpFactorization::firstNumberSlacks_
int firstNumberSlacks_
number of slacks in irst basis
Definition: CoinSimpFactorization.hpp:428
CoinSimpFactorization::auxInd_
int * auxInd_
auxiliary vector
Definition: CoinSimpFactorization.hpp:286
CoinSimpFactorization::Hxeqb
void Hxeqb(double *b) const
solves H x = b, where H is a product of eta matrices
CoinSimpFactorization::GaussEliminate
void GaussEliminate(FactorPointers &pointers, int &r, int &s)
does Gauss elimination
CoinOtherFactorization::numberColumns_
int numberColumns_
Number of Columns in factorization.
Definition: CoinDenseFactorization.hpp:247
CoinSimpFactorization::operator=
CoinSimpFactorization & operator=(const CoinSimpFactorization &other)
= copy
CoinSimpFactorization::LcolInd_
int * LcolInd_
indices in the columns of L
Definition: CoinSimpFactorization.hpp:317
CoinSimpFactorization::checkPivot
int checkPivot(double saveFromU, double oldPivot) const
CoinSimpFactorization::makeNonSingular
virtual void makeNonSingular(int *sequence, int numberColumns)
Makes a non-singular basis by replacing variables.
CoinSimpFactorization::copyUbyColumns
void copyUbyColumns()
copies U by columns
CoinSimpFactorization::factor
virtual int factor()
Does most of factorization returning status 0 - OK -99 - needs more memory -1 - singular - use number...
CoinSimpFactorization::EtaStarts_
int * EtaStarts_
Starts of eta vectors.
Definition: CoinSimpFactorization.hpp:395
CoinSimpFactorization::gutsOfDestructor
void gutsOfDestructor()
The real work of destructor.
CoinSimpFactorization::lastEtaRow_
int lastEtaRow_
last eta row
Definition: CoinSimpFactorization.hpp:405
CoinSimpFactorization::ftran
void ftran(double *b, double *sol, bool save) const
does FTRAN
CoinSimpFactorization::indKeep_
int * indKeep_
indices of this vector
Definition: CoinSimpFactorization.hpp:291
CoinSimpFactorization::vecLabels_
int * vecLabels_
array of labels (should be initialized to zero)
Definition: CoinSimpFactorization.hpp:279
CoinOtherFactorization::numberColumns
int numberColumns() const
Total number of columns in factorization.
Definition: CoinDenseFactorization.hpp:71
CoinSimpFactorization::updateColumn
virtual int updateColumn(CoinIndexedVector *regionSparse, CoinIndexedVector *regionSparse2, bool noPermute=false) const
This version has same effect as above with FTUpdate==false so number returned is always &gt;=0...
CoinSimpFactorization::colPosition_
int * colPosition_
position of column after permutation
Definition: CoinSimpFactorization.hpp:382
CoinSimpFactorization::findShortRow
int findShortRow(const int column, const int length, int &minRow, int &minRowLength, FactorPointers &pointers)
finds short row that intersects a given column
CoinOtherFactorization
Abstract base class which also has some scalars so can be used from Dense or Simp.
Definition: CoinDenseFactorization.hpp:27
CoinSimpFactorization::newEta
void newEta(int row, int numNewElements)
creates a new eta vector
CoinSimpFactorization::updateColumnTranspose
virtual int updateColumnTranspose(CoinIndexedVector *regionSparse, CoinIndexedVector *regionSparse2) const
Updates one column (BTRAN) from regionSparse2 regionSparse starts as zero and is zero at end Note - i...
CoinOtherFactorization::elements
virtual CoinFactorizationDouble * elements() const
Returns array to put basis elements in.
CoinSimpFactorization::mainLoopFactor
int mainLoopFactor(FactorPointers &pointers)
main loop of factorization
CoinSimpFactorization::Lxeqb2
void Lxeqb2(double *b1, double *b2) const
same as above but with two rhs
CoinSimpFactorization::numberSlacks_
int numberSlacks_
number of slacks in basis
Definition: CoinSimpFactorization.hpp:426
CoinSimpFactorization::updateTwoColumnsFT
virtual int updateTwoColumnsFT(CoinIndexedVector *regionSparse1, CoinIndexedVector *regionSparse2, CoinIndexedVector *regionSparse3, bool noPermute=false)
does FTRAN on two columns
CoinPackedMatrix
Sparse Matrix Base Class.
Definition: CoinPackedMatrix.hpp:79
CoinSimpFactorization::clone
virtual CoinOtherFactorization * clone() const
Clone.
CoinSimpFactorization::UcolMaxCap_
int UcolMaxCap_
maximum capacity of Ucolumns_
Definition: CoinSimpFactorization.hpp:370
CoinSimpFactorization::indVector_
int * indVector_
array of indices
Definition: CoinSimpFactorization.hpp:281
CoinSimpFactorization::xLeqb
void xLeqb(double *b) const
solves x L = b
CoinDenseFactorization.hpp
CoinSimpFactorization::upColumnTranspose
int upColumnTranspose(CoinIndexedVector *regionSparse, CoinIndexedVector *regionSparse2) const
does updateColumnTranspose, the other is a wrapper
CoinSimpFactorization::LrowSize_
int LrowSize_
Size of Lrows_;.
Definition: CoinSimpFactorization.hpp:306
FactorPointers::nextRow
int * nextRow
Definition: CoinSimpFactorization.hpp:27
CoinSimpFactorization::invOfPivots_
double * invOfPivots_
inverse values of the elements of diagonal of U
Definition: CoinSimpFactorization.hpp:377
CoinSimpFactorization::nextColInU_
int * nextColInU_
next column in U
Definition: CoinSimpFactorization.hpp:364
FactorPointers::rowMax
double * rowMax
Definition: CoinSimpFactorization.hpp:24
CoinSimpFactorization::findPivotSimp
int findPivotSimp(FactorPointers &pointers, int &r, int &s)
finds a pivot in the first column available
CoinSimpFactorization::removeColumnFromActSet
void removeColumnFromActSet(const int column, FactorPointers &pointers)
declares a column inactive
CoinSimpFactorization::replaceColumn
virtual int replaceColumn(CoinIndexedVector *regionSparse, int pivotRow, double pivotCheck, bool checkBeforeModifying=false, double acceptablePivot=1.0e-8)
Replaces one Column to basis, returns 0=OK, 1=Probably OK, 2=singular, 3=no room If checkBeforeModify...
CoinSimpFactorization::LcolCap_
int LcolCap_
maximum capacity of L
Definition: CoinSimpFactorization.hpp:321
FactorPointers
pointers used during factorization
Definition: CoinSimpFactorization.hpp:22
CoinSimpFactorization::increaseRowSize
void increaseRowSize(const int row, const int newSize)
allocates more space for a row of U
CoinSimpFactorization::indices
int * indices() const
Returns array to put basis indices in.
Definition: CoinSimpFactorization.hpp:154
CoinSimpFactorization::increaseLsize
void increaseLsize()
allocates more space for L
CoinSimpFactorization::maxU_
double maxU_
maximum of U
Definition: CoinSimpFactorization.hpp:418
CoinSimpFactorization::pivotCandLimit_
int pivotCandLimit_
maximum number of candidates for pivot
Definition: CoinSimpFactorization.hpp:424
CoinSimpFactorization::ftran2
void ftran2(double *b1, double *sol1, double *b2, double *sol2) const
same as above but with two columns
CoinSimpFactorization::LrowInd_
int * LrowInd_
indices in the rows of L
Definition: CoinSimpFactorization.hpp:304
CoinSimpFactorization::colOfU_
int * colOfU_
permutation of columns
Definition: CoinSimpFactorization.hpp:380
CoinSimpFactorization::keepSize_
int keepSize_
number of nonzeros
Definition: CoinSimpFactorization.hpp:293
CoinSimpFactorization::findPivotShCol
int findPivotShCol(FactorPointers &pointers, int &r, int &s)
finds a pivot in a shortest column
CoinSimpFactorization::workArea2_
double * workArea2_
work array
Definition: CoinSimpFactorization.hpp:275
CoinSimpFactorization::factorize
void factorize(int numberOfRows, int numberOfColumns, const int colStarts[], const int indicesRow[], const double elements[])
calls factorization
CoinSimpFactorization::updateColumnFT
virtual int updateColumnFT(CoinIndexedVector *regionSparse, CoinIndexedVector *regionSparse2, bool noPermute=false)
Updates one column (FTRAN) from regionSparse2 Tries to do FT update number returned is negative if no...
CoinSimpFactorization::UrowEnd_
int UrowEnd_
number of used places in Urows
Definition: CoinSimpFactorization.hpp:339
CoinSimpFactorization::LrowCap_
int LrowCap_
Capacity of Lrows_.
Definition: CoinSimpFactorization.hpp:308
CoinSimpFactorization::firstRowInU_
int firstRowInU_
first row in U
Definition: CoinSimpFactorization.hpp:341
CoinSimpFactorization::LcolStarts_
int * LcolStarts_
Starts of the columns of L.
Definition: CoinSimpFactorization.hpp:311
CoinSimpFactorization::Lxeqb
void Lxeqb(double *b) const
solves L x = b
CoinSimpFactorization::Hxeqb2
void Hxeqb2(double *b1, double *b2) const
same as above but with two rhs
CoinSimpFactorization::rowPosition_
int * rowPosition_
position of row after permutation
Definition: CoinSimpFactorization.hpp:386
CoinSimpFactorization::EtaLengths_
int * EtaLengths_
Lengths of eta vectors.
Definition: CoinSimpFactorization.hpp:397
CoinSimpFactorization::xHeqb
void xHeqb(double *b) const
solves x H = b
CoinSimpFactorization::LUupdate
int LUupdate(int newBasicCol)
updates factorization after a Simplex iteration
CoinIndexedVector.hpp
CoinSimpFactorization::pivoting
void pivoting(const int pivotRow, const int pivotColumn, const double invPivot, FactorPointers &pointers)
does pivoting
CoinSimpFactorization::Lcolumns_
double * Lcolumns_
L by columns.
Definition: CoinSimpFactorization.hpp:315
CoinSimpFactorization::findInRow
int findInRow(const int row, const int column)
finds a given row in a column
CoinOtherFactorization::elements_
CoinFactorizationDouble * elements_
Elements of factorization and updates length is maxR*maxR+maxSpace will always be long enough so can ...
Definition: CoinDenseFactorization.hpp:266
CoinSimpFactorization::CoinSimpFactorizationUnitTest
friend void CoinSimpFactorizationUnitTest(const std::string &mpsDir)
FactorPointers::firstRowKnonzeros
int * firstRowKnonzeros
Definition: CoinSimpFactorization.hpp:25
CoinSimpFactorization::EtaSize_
int EtaSize_
number of elements in Eta_
Definition: CoinSimpFactorization.hpp:403
CoinSimpFactorization::findInColumn
int findInColumn(const int column, const int row)
finds a given column in a row
CoinIndexedVector
Indexed Vector.
Definition: CoinIndexedVector.hpp:104
CoinSimpFactorization::minIncrease_
int minIncrease_
minimum storage increase
Definition: CoinSimpFactorization.hpp:412
CoinSimpFactorization::CoinSimpFactorization
CoinSimpFactorization()
Default constructor.
CoinSimpFactorization::workArea3_
double * workArea3_
work array
Definition: CoinSimpFactorization.hpp:277
CoinSimpFactorization::maxGrowth_
double maxGrowth_
bound on the growth rate
Definition: CoinSimpFactorization.hpp:420
CoinSimpFactorization::Eta_
double * Eta_
elements of eta vectors
Definition: CoinSimpFactorization.hpp:401
CoinSimpFactorization::UcolStarts_
int * UcolStarts_
Starts of the columns of U.
Definition: CoinSimpFactorization.hpp:350
CoinSimpFactorization::nextRowInU_
int * nextRowInU_
next row in U
Definition: CoinSimpFactorization.hpp:347
CoinSimpFactorization::UrowMaxCap_
int UrowMaxCap_
maximum capacity of Urows
Definition: CoinSimpFactorization.hpp:337
CoinSimpFactorization::permute
virtual int * permute() const
Returns permute in.
Definition: CoinSimpFactorization.hpp:157
CoinSimpFactorization::colSlack_
int * colSlack_
indicator of slack variables
Definition: CoinSimpFactorization.hpp:374
CoinSimpFactorization::numberElements
virtual int numberElements() const
Total number of elements in factorization.
Definition: CoinSimpFactorization.hpp:83
CoinSimpFactorization::allocateSpaceForU
void allocateSpaceForU()
allocates space for U
CoinSimpFactorization::updateTol_
double updateTol_
maximum size for the diagonal of U after update
Definition: CoinSimpFactorization.hpp:414
CoinSimpFactorization::LrowStarts_
int * LrowStarts_
Starts of the rows of L.
Definition: CoinSimpFactorization.hpp:298
CoinSimpFactorization::maxA_
double maxA_
maximum of A
Definition: CoinSimpFactorization.hpp:422
CoinSimpFactorization::removeRowFromActSet
void removeRowFromActSet(const int row, FactorPointers &pointers)
declares a row inactive
CoinSimpFactorization::initialSomeNumbers
void initialSomeNumbers()
initializes some numbers
CoinSimpFactorization::preProcess
virtual void preProcess()
PreProcesses column ordered copy of basis.
CoinSimpFactorization::lastRowInU_
int lastRowInU_
last row in U
Definition: CoinSimpFactorization.hpp:343
CoinTypes.hpp
CoinOtherFactorization::numberRows
int numberRows() const
Number of Rows after factorization.
Definition: CoinDenseFactorization.hpp:67
CoinSimpFactorization::UcolInd_
int * UcolInd_
Indices in the columns of U.
Definition: CoinSimpFactorization.hpp:360
CoinSimpFactorization::findShortColumn
int findShortColumn(const int row, const int length, int &minCol, int &minColLength, FactorPointers &pointers)
finds short column that intersects a given row
CoinSimpFactorization::vecKeep_
double * vecKeep_
vector to keep for LUupdate
Definition: CoinSimpFactorization.hpp:289
CoinSimpFactorization::LcolLengths_
int * LcolLengths_
Lengths of the columns of L.
Definition: CoinSimpFactorization.hpp:313
FactorPointers::nextColumn
int * nextColumn
Definition: CoinSimpFactorization.hpp:30
CoinSimpFactorization::btran
void btran(double *b, double *sol) const
does BTRAN
CoinSimpFactorization::LcolSize_
int LcolSize_
numbers of elements in L
Definition: CoinSimpFactorization.hpp:319
CoinSimpFactorization::clearArrays
void clearArrays()
Get rid of all memory.
Definition: CoinSimpFactorization.hpp:151
CoinOtherFactorization::pivotRow_
int * pivotRow_
Pivot row.
Definition: CoinDenseFactorization.hpp:261
CoinSimpFactorization::EtaPosition_
int * EtaPosition_
position of Eta vector
Definition: CoinSimpFactorization.hpp:393
CoinSimpFactorization::upColumn
int upColumn(CoinIndexedVector *regionSparse, CoinIndexedVector *regionSparse2, bool noPermute=false, bool save=false) const
does updatecolumn if save==true keeps column for replace column
FactorPointers::prevRow
int * prevRow
Definition: CoinSimpFactorization.hpp:26
CoinSimpFactorization::UcolEnd_
int UcolEnd_
last used position in Ucolumns_
Definition: CoinSimpFactorization.hpp:372
CoinSimpFactorization::findPivot
int findPivot(FactorPointers &pointers, int &r, int &s, bool &ifSlack)
finds a pivot element using Markowitz count
CoinSimpFactorization::UrowLengths_
int * UrowLengths_
Lengths of the rows of U.
Definition: CoinSimpFactorization.hpp:327
CoinSimpFactorization::Uxeqb
void Uxeqb(double *b, double *sol) const
solves U x = b
CoinSimpFactorization::firstColInU_
int firstColInU_
first column in U
Definition: CoinSimpFactorization.hpp:366
CoinOtherFactorization::pivotRow
virtual int * pivotRow() const
Returns pivot row.
CoinSimpFactorization::updateCurrentRow
void updateCurrentRow(const int pivotRow, const int row, const double multiplier, FactorPointers &pointers, int &newNonZeros)
part of pivoting
CoinSimpFactorization::enlargeUrow
void enlargeUrow(const int numNewElements)
allocates more space for rows of U
CoinSimpFactorization::secRowPosition_
int * secRowPosition_
position of row after permutation during LUupdate
Definition: CoinSimpFactorization.hpp:390
CoinOtherFactorization::numberPivots_
int numberPivots_
Number pivots since last factorization.
Definition: CoinDenseFactorization.hpp:253
CoinSimpFactorization::EtaInd_
int * EtaInd_
columns of eta vectors
Definition: CoinSimpFactorization.hpp:399
CoinSimpFactorization::getAreas
virtual void getAreas(int numberRows, int numberColumns, CoinBigIndex maximumL, CoinBigIndex maximumU)
Gets space for a factorization.
CoinSimpFactorization::prevRowInU_
int * prevRowInU_
previous row in U
Definition: CoinSimpFactorization.hpp:345
CoinSimpFactorization::postProcess
virtual void postProcess(const int *sequence, int *pivotVariable)
Does post processing on valid factorization - putting variables on correct rows.
CoinSimpFactorization::LrowLengths_
int * LrowLengths_
Lengths of the rows of L.
Definition: CoinSimpFactorization.hpp:300
CoinSimpFactorization::secRowOfU_
int * secRowOfU_
permutations of rows during LUupdate
Definition: CoinSimpFactorization.hpp:388
CoinSimpFactorization::UrowInd_
int * UrowInd_
Indices in the rows of U.
Definition: CoinSimpFactorization.hpp:335
CoinSimpFactorization::findMaxInRrow
double findMaxInRrow(const int row, FactorPointers &pointers)
finds maximum absolute value in a row
CoinSimpFactorization::prevColInU_
int * prevColInU_
previous column in U
Definition: CoinSimpFactorization.hpp:362
CoinSimpFactorization::EtaMaxCap_
int EtaMaxCap_
Capacity of Eta_.
Definition: CoinSimpFactorization.hpp:409
CoinSimpFactorization::Lrows_
double * Lrows_
L by rows.
Definition: CoinSimpFactorization.hpp:302
CoinSimpFactorization::rowOfU_
int * rowOfU_
permutations of rows
Definition: CoinSimpFactorization.hpp:384
CoinOtherFactorization::numberRows_
int numberRows_
Number of Rows in factorization.
Definition: CoinDenseFactorization.hpp:245
CoinSimpFactorization::copyRowPermutations
void copyRowPermutations()
makes a copy of row permutations
CoinSimpFactorization::maximumCoefficient
double maximumCoefficient() const
Returns maximum absolute value in factorization.
FactorPointers::~FactorPointers
~FactorPointers()
CoinSimpFactorization::lastColInU_
int lastColInU_
last column in U
Definition: CoinSimpFactorization.hpp:368
CoinSimpFactorization::auxVector_
double * auxVector_
auxiliary vector
Definition: CoinSimpFactorization.hpp:284
CoinSimpFactorization::Urows_
double * Urows_
U by rows.
Definition: CoinSimpFactorization.hpp:333
CoinSimpFactorization::UrowStarts_
int * UrowStarts_
Starts of the rows of U.
Definition: CoinSimpFactorization.hpp:325
CoinSimpFactorization::~CoinSimpFactorization
virtual ~CoinSimpFactorization()
Destructor.
CoinSimpFactorization::denseVector_
double * denseVector_
work array (should be initialized to zero)
Definition: CoinSimpFactorization.hpp:273
FactorPointers::newCols
int * newCols
Definition: CoinSimpFactorization.hpp:31
FactorPointers::firstColKnonzeros
int * firstColKnonzeros
Definition: CoinSimpFactorization.hpp:28
CoinSimpFactorization::gutsOfCopy
void gutsOfCopy(const CoinSimpFactorization &other)
The real work of copy.
CoinSimpFactorization::UcolLengths_
int * UcolLengths_
Lengths of the columns of U.
Definition: CoinSimpFactorization.hpp:352
CoinSimpFactorization::copyLbyRows
void copyLbyRows()
copies L by rows
FactorPointers::FactorPointers
FactorPointers(int numRows, int numCols, int *UrowLengths_, int *UcolLengths_)
CoinSimpFactorization::allocateSomeArrays
void allocateSomeArrays()
allocates several working arrays
CoinSimpFactorization::xUeqb
void xUeqb(double *b, double *sol) const
solves x U = b
CoinSimpFactorization::enlargeUcol
void enlargeUcol(const int numNewElements, const bool b)
allocates more space for columns of U