Cgl 0.60.2

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

- File List
- File Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
CoinAbcDenseFactorization.hpp
Go to the documentation of this file.
1 /* $Id: CoinAbcDenseFactorization.hpp 2385 2019-01-06 19:43:06Z unxusr $ */
2 // Copyright (C) 2008, International Business Machines
3 // Corporation and others, Copyright (C) 2012, FasterCoin. All Rights Reserved.
4 // This code is licensed under the terms of the Eclipse Public License (EPL).
5
6 /*
7 Authors
8
9 John Forrest
10
11 */
12 #ifndef CoinAbcDenseFactorization_H
13 #define CoinAbcDenseFactorization_H
14
15 #include <iostream>
16 #include <string>
17 #include <cassert>
18 #include "CoinTypes.hpp"
19 #include "CoinAbcCommon.hpp"
20 #include "CoinIndexedVector.hpp"
21 class CoinPackedMatrix;
23 class CoinAbcAnyFactorization {
24
25 public:
28 CoinAbcAnyFactorization();
31 CoinAbcAnyFactorization(const CoinAbcAnyFactorization &other);
32
34 virtual ~CoinAbcAnyFactorization();
36 CoinAbcAnyFactorization &operator=(const CoinAbcAnyFactorization &other);
37
39 virtual CoinAbcAnyFactorization *clone() const = 0;
41
44 inline int status() const
46 {
47 return status_;
48 }
50 inline void setStatus(int value)
51 {
52 status_ = value;
53 }
55 inline int pivots() const
56 {
57 return numberPivots_;
58 }
59 #if ABC_PARALLEL == 2
60 inline void setParallelMode(int value)
62 {
63 parallelMode_ = value;
64 };
65 #endif
66 inline void setPivots(int value)
68 {
69 numberPivots_ = value;
70 }
72 inline int numberSlacks() const
73 {
74 return numberSlacks_;
75 }
77 inline void setNumberSlacks(int value)
78 {
79 numberSlacks_ = value;
80 }
82 inline void setNumberRows(int value)
83 {
84 numberRows_ = value;
85 }
87 inline int numberRows() const
88 {
89 return numberRows_;
90 }
92 inline CoinSimplexInt numberDense() const
93 {
94 return numberDense_;
95 }
97 inline int numberGoodColumns() const
98 {
99 return numberGoodU_;
100 }
102 inline void relaxAccuracyCheck(double value)
103 {
104 relaxCheck_ = value;
105 }
106 inline double getAccuracyCheck() const
107 {
108 return relaxCheck_;
109 }
111 inline int maximumPivots() const
112 {
113 return maximumPivots_;
114 }
116 virtual void maximumPivots(int value);
117
119 inline double pivotTolerance() const
120 {
121 return pivotTolerance_;
122 }
123 void pivotTolerance(double value);
125 inline double minimumPivotTolerance() const
126 {
127 return minimumPivotTolerance_;
128 }
129 void minimumPivotTolerance(double value);
130 virtual CoinFactorizationDouble *pivotRegion() const
131 {
132 return NULL;
133 }
135 inline double areaFactor() const
136 {
137 return areaFactor_;
138 }
139 inline void areaFactor(CoinSimplexDouble value)
140 {
141 areaFactor_ = value;
142 }
144 inline double zeroTolerance() const
145 {
146 return zeroTolerance_;
147 }
148 void zeroTolerance(double value);
150 virtual CoinFactorizationDouble *elements() const;
152 virtual int *pivotRow() const;
154 virtual CoinFactorizationDouble *workArea() const;
156 virtual int *intWorkArea() const;
158 virtual int *numberInRow() const;
160 virtual int *numberInColumn() const;
162 virtual CoinBigIndex *starts() const;
164 virtual int *permuteBack() const;
166 virtual void goSparse() {}
167 #ifndef NDEBUG
168 virtual inline void checkMarkArrays() const
169 {
170 }
171 #endif
172
176 inline int solveMode() const
177 {
178 return solveMode_;
179 }
184 inline void setSolveMode(int value)
185 {
186 solveMode_ = value;
187 }
189 virtual bool wantsTableauColumn() const;
194 virtual void setUsefulInformation(const int *info, int whereFrom);
196 virtual void clearArrays() {}
198
200 virtual int *indices() const = 0;
203 virtual int *permute() const = 0;
205 virtual int *pivotColumn() const;
207 virtual int numberElements() const = 0;
209
211 virtual void getAreas(int numberRows,
213 int numberColumns,
214 CoinBigIndex maximumL,
215 CoinBigIndex maximumU)
216 = 0;
217
219 virtual void preProcess() = 0;
225 virtual int factor(AbcSimplex *model) = 0;
226 #ifdef EARLY_FACTORIZE
227 virtual int factorize(AbcSimplex * /*model*/, CoinIndexedVector & /*stuff*/)
229 {
230 return -2;
231 }
232 #endif
233 virtual void postProcess(const int *sequence, int *pivotVariable) = 0;
236 virtual void makeNonSingular(int *sequence) = 0;
238
241 #if 0
242
246 virtual int checkReplace ( CoinIndexedVector * /*regionSparse*/,
247 int /*pivotRow*/,
248 double & /*pivotCheck*/,
249 double /*acceptablePivot = 1.0e-8*/)
250 {return 0;}
255 virtual int replaceColumn ( CoinIndexedVector * regionSparse,
256 int pivotRow,
257 double pivotCheck ,
258 bool skipBtranU=false,
259 double acceptablePivot=1.0e-8)=0;
260 #endif
261 #ifdef EARLY_FACTORIZE
262 virtual int replaceColumns(const AbcSimplex * /*model*/,
264 CoinIndexedVector & /*stuff*/,
265 int /*firstPivot*/, int /*lastPivot*/, bool /*cleanUp*/)
266 {
267 return -1;
268 }
269 #endif
270 #ifdef ABC_LONG_FACTORIZATION
271 virtual void clearHiddenArrays() {}
273 #endif
274
278 virtual
279 #ifdef ABC_LONG_FACTORIZATION
280 long
281 #endif
282 double
283 checkReplacePart1(CoinIndexedVector * /*regionSparse*/,
284 int /*pivotRow*/)
285 {
286 return 0.0;
287 }
288 virtual
289 #ifdef ABC_LONG_FACTORIZATION
290 long
291 #endif
292 double
293 checkReplacePart1(CoinIndexedVector * /*regionSparse*/,
294 CoinIndexedVector * /*partialUpdate*/,
295 int /*pivotRow*/)
296 {
297 return 0.0;
298 }
299 virtual void checkReplacePart1a(CoinIndexedVector * /* regionSparse */,
300 int /*pivotRow*/)
301 {
302 }
303 virtual double checkReplacePart1b(CoinIndexedVector * /*regionSparse*/,
304 int /*pivotRow*/)
305 {
306 return 0.0;
307 }
310 virtual int checkReplacePart2(int pivotRow,
311 double btranAlpha,
312 double ftranAlpha,
313 #ifdef ABC_LONG_FACTORIZATION
314 long
315 #endif
316 double ftAlpha,
317 double acceptablePivot = 1.0e-8)
318 = 0;
321 virtual void replaceColumnPart3(const AbcSimplex *model,
322 CoinIndexedVector *regionSparse,
323 CoinIndexedVector *tableauColumn,
324 int pivotRow,
325 #ifdef ABC_LONG_FACTORIZATION
326 long
327 #endif
328 double alpha)
329 = 0;
332 virtual void replaceColumnPart3(const AbcSimplex *model,
333 CoinIndexedVector *regionSparse,
334 CoinIndexedVector *tableauColumn,
335 CoinIndexedVector *partialUpdate,
336 int pivotRow,
337 #ifdef ABC_LONG_FACTORIZATION
338 long
339 #endif
340 double alpha)
341 = 0;
343
351 virtual int updateColumnFT(CoinIndexedVector &regionSparse) = 0;
352 virtual int updateColumnFTPart1(CoinIndexedVector &regionSparse) = 0;
353 virtual void updateColumnFTPart2(CoinIndexedVector &regionSparse) = 0;
354 virtual void updateColumnFT(CoinIndexedVector &regionSparseFT,
355 CoinIndexedVector &partialUpdate,
356 int which)
357 = 0;
360 virtual int updateColumn(CoinIndexedVector &regionSparse) const = 0;
362 virtual int updateTwoColumnsFT(CoinIndexedVector &regionFT,
363 CoinIndexedVector &regionOther)
364 = 0;
367 virtual int updateColumnTranspose(CoinIndexedVector &regionSparse) const = 0;
369 virtual void updateFullColumn(CoinIndexedVector &regionSparse) const = 0;
372 virtual void updateFullColumnTranspose(CoinIndexedVector &regionSparse) const = 0;
374 virtual void updateWeights(CoinIndexedVector &regionSparse) const = 0;
376 virtual void updateColumnCpu(CoinIndexedVector &regionSparse, int whichCpu) const;
378 virtual void updateColumnTransposeCpu(CoinIndexedVector &regionSparse, int whichCpu) const;
380
382 protected:
385 double pivotTolerance_;
388 double minimumPivotTolerance_;
390 double areaFactor_;
392 double zeroTolerance_;
393 //#ifndef slackValue_
394 #define slackValue2_ 1.0
395 //#endif
397 double relaxCheck_;
399 CoinBigIndex factorElements_;
401 int numberRows_;
403 int numberDense_;
405 int numberGoodU_;
407 int maximumPivots_;
409 int numberPivots_;
411 int numberSlacks_;
413 int status_;
415 int maximumRows_;
416 #if ABC_PARALLEL == 2
417 int parallelMode_;
418 #endif
419 int *pivotRow_;
425 CoinFactorizationDouble *elements_;
427 CoinFactorizationDouble *workArea_;
432 int solveMode_;
434 };
442 class CoinAbcDenseFactorization : public CoinAbcAnyFactorization {
443 friend void CoinAbcDenseFactorizationUnitTest(const std::string &mpsDir);
444
445 public:
448 CoinAbcDenseFactorization();
451 CoinAbcDenseFactorization(const CoinAbcDenseFactorization &other);
452
454 virtual ~CoinAbcDenseFactorization();
456 CoinAbcDenseFactorization &operator=(const CoinAbcDenseFactorization &other);
458 virtual CoinAbcAnyFactorization *clone() const;
460
463 virtual void getAreas(int numberRows,
465 int numberColumns,
466 CoinBigIndex maximumL,
467 CoinBigIndex maximumU);
468
470 virtual void preProcess();
476 virtual int factor(AbcSimplex *model);
478 virtual void postProcess(const int *sequence, int *pivotVariable);
480 virtual void makeNonSingular(int *sequence);
482
485 virtual inline int numberElements() const
487 {
488 return numberRows_ * (numberRows_ + numberPivots_);
489 }
491 double maximumCoefficient() const;
493
496
501 virtual int replaceColumn(CoinIndexedVector *regionSparse,
502 int pivotRow,
503 double pivotCheck,
504 bool skipBtranU = false,
505 double acceptablePivot = 1.0e-8);
508 virtual int checkReplacePart2(int pivotRow,
509 double btranAlpha,
510 double ftranAlpha,
511 #ifdef ABC_LONG_FACTORIZATION
512 long
513 #endif
514 double ftAlpha,
515 double acceptablePivot = 1.0e-8);
518 virtual void replaceColumnPart3(const AbcSimplex *model,
519 CoinIndexedVector *regionSparse,
520 CoinIndexedVector *tableauColumn,
521 int pivotRow,
522 #ifdef ABC_LONG_FACTORIZATION
523 long
524 #endif
525 double alpha);
528 virtual void replaceColumnPart3(const AbcSimplex *model,
529 CoinIndexedVector *regionSparse,
530 CoinIndexedVector *tableauColumn,
531 CoinIndexedVector * /*partialUpdate*/,
532 int pivotRow,
533 #ifdef ABC_LONG_FACTORIZATION
534 long
535 #endif
536 double alpha)
537 {
538 replaceColumnPart3(model, regionSparse, tableauColumn, pivotRow, alpha);
539 }
541
549 virtual int updateColumnFT(CoinIndexedVector &regionSparse)
550 {
551 return updateColumn(regionSparse);
552 }
553 virtual int updateColumnFTPart1(CoinIndexedVector &regionSparse)
554 {
555 return updateColumn(regionSparse);
556 }
557 virtual void updateColumnFTPart2(CoinIndexedVector & /*regionSparse*/)
558 {
559 }
560 virtual void updateColumnFT(CoinIndexedVector &regionSparseFT, CoinIndexedVector & /*partialUpdate*/, int /*which*/)
561 {
562 updateColumnFT(regionSparseFT);
563 }
566 virtual int updateColumn(CoinIndexedVector &regionSparse) const;
568 virtual int updateTwoColumnsFT(CoinIndexedVector &regionFT,
569 CoinIndexedVector &regionOther);
572 virtual int updateColumnTranspose(CoinIndexedVector &regionSparse) const;
574 virtual void updateFullColumn(CoinIndexedVector &regionSparse) const
575 {
576 updateColumn(regionSparse);
577 }
580 virtual void updateFullColumnTranspose(CoinIndexedVector &regionSparse) const
581 {
582 updateColumnTranspose(regionSparse);
583 }
585 virtual void updateWeights(CoinIndexedVector &regionSparse) const;
587
592 inline void clearArrays()
594 {
595 gutsOfDestructor();
596 }
598 virtual inline int *indices() const
599 {
600 return reinterpret_cast< int * >(elements_ + numberRows_ * numberRows_);
601 }
603 virtual inline int *permute() const
604 {
605 return NULL; /*pivotRow_*/
606 ;
607 }
609
611 void gutsOfDestructor();
613 void gutsOfInitialize();
615 void gutsOfCopy(const CoinAbcDenseFactorization &other);
616
618 protected:
621 int checkPivot(double saveFromU, double oldPivot) const;
623 protected:
625 CoinBigIndex maximumSpace_;
627 CoinSimplexInt maximumRowsAdjusted_;
628
631
632 };
633 #endif
634
635 /* vi: softtabstop=2 shiftwidth=2 expandtab tabstop=2
636 */
CoinAbcDenseFactorization::updateFullColumn
virtual void updateFullColumn(CoinIndexedVector &regionSparse) const
This version does FTRAN on array when indices not set up.
Definition: CoinAbcDenseFactorization.hpp:574
CoinAbcAnyFactorization::makeNonSingular
virtual void makeNonSingular(int *sequence)=0
Makes a non-singular basis by replacing variables.
CoinAbcDenseFactorization::updateFullColumnTranspose
virtual void updateFullColumnTranspose(CoinIndexedVector &regionSparse) const
Updates one column (BTRAN) from unpacked regionSparse.
Definition: CoinAbcDenseFactorization.hpp:580
CoinAbcDenseFactorization::maximumRowsAdjusted_
CoinSimplexInt maximumRowsAdjusted_
Use for array size to get multiple of 8.
Definition: CoinAbcDenseFactorization.hpp:627
CoinAbcDenseFactorization::factor
virtual int factor(AbcSimplex *model)
Does most of factorization returning status 0 - OK -99 - needs more memory -1 - singular - use number...
CoinAbcAnyFactorization::zeroTolerance
double zeroTolerance() const
Zero tolerance.
Definition: CoinAbcDenseFactorization.hpp:144
CoinAbcAnyFactorization::factor
virtual int factor(AbcSimplex *model)=0
Does most of factorization returning status 0 - OK -99 - needs more memory -1 - singular - use number...
CoinAbcAnyFactorization::numberRows_
int numberRows_
Number of Rows in factorization.
Definition: CoinAbcDenseFactorization.hpp:401
CoinAbcDenseFactorization::replaceColumn
virtual int replaceColumn(CoinIndexedVector *regionSparse, int pivotRow, double pivotCheck, bool skipBtranU=false, double acceptablePivot=1.0e-8)
Replaces one Column to basis, returns 0=OK, 1=Probably OK, 2=singular, 3=no room If skipBtranU is fal...
CoinAbcAnyFactorization::elements_
CoinFactorizationDouble * elements_
Elements of factorization and updates length is maxR*maxR+maxSpace will always be long enough so can ...
Definition: CoinAbcDenseFactorization.hpp:425
CoinAbcDenseFactorization::preProcess
virtual void preProcess()
PreProcesses column ordered copy of basis.
CoinAbcAnyFactorization::checkReplacePart1
virtual double checkReplacePart1(CoinIndexedVector *, int)
Checks if can replace one Column to basis, returns update alpha Fills in region for use later partial...
Definition: CoinAbcDenseFactorization.hpp:283
CoinAbcDenseFactorization::updateColumnTranspose
virtual int updateColumnTranspose(CoinIndexedVector &regionSparse) const
Updates one column (BTRAN) from unpacked regionSparse.
CoinAbcCommon.hpp
CoinAbcDenseFactorization::replaceColumnPart3
virtual void replaceColumnPart3(const AbcSimplex *model, CoinIndexedVector *regionSparse, CoinIndexedVector *tableauColumn, int pivotRow, double alpha)
Replaces one Column to basis, partial update already in U.
AbcSimplex
Definition: AbcSimplex.hpp:62
CoinTypes.hpp
CoinAbcAnyFactorization::areaFactor
void areaFactor(CoinSimplexDouble value)
Definition: CoinAbcDenseFactorization.hpp:139
CoinAbcAnyFactorization::~CoinAbcAnyFactorization
virtual ~CoinAbcAnyFactorization()
Destructor.
CoinAbcAnyFactorization::pivotColumn
virtual int * pivotColumn() const
Returns pivotColumn or permute.
CoinAbcAnyFactorization
Abstract base class which also has some scalars so can be used from Dense or Simp.
Definition: CoinAbcDenseFactorization.hpp:23
CoinAbcAnyFactorization::permuteBack
virtual int * permuteBack() const
Returns permute back.
CoinAbcAnyFactorization::updateFullColumnTranspose
virtual void updateFullColumnTranspose(CoinIndexedVector &regionSparse) const =0
Updates one column (BTRAN) from unpacked regionSparse.
CoinAbcAnyFactorization::updateColumnFTPart1
virtual int updateColumnFTPart1(CoinIndexedVector &regionSparse)=0
CoinAbcAnyFactorization::numberSlacks_
int numberSlacks_
Number slacks.
Definition: CoinAbcDenseFactorization.hpp:411
CoinAbcAnyFactorization::numberPivots_
int numberPivots_
Number pivots since last factorization.
Definition: CoinAbcDenseFactorization.hpp:409
CoinAbcAnyFactorization::updateColumnTranspose
virtual int updateColumnTranspose(CoinIndexedVector &regionSparse) const =0
Updates one column (BTRAN) from unpacked regionSparse.
CoinAbcDenseFactorization::updateColumnFTPart2
virtual void updateColumnFTPart2(CoinIndexedVector &)
Definition: CoinAbcDenseFactorization.hpp:557
CoinAbcAnyFactorization::areaFactor
double areaFactor() const
Area factor.
Definition: CoinAbcDenseFactorization.hpp:135
CoinAbcAnyFactorization::CoinAbcAnyFactorization
CoinAbcAnyFactorization()
Default constructor.
CoinAbcAnyFactorization::updateFullColumn
virtual void updateFullColumn(CoinIndexedVector &regionSparse) const =0
This version does FTRAN on array when indices not set up.
CoinAbcAnyFactorization::relaxCheck_
double relaxCheck_
Relax check on accuracy in replaceColumn.
Definition: CoinAbcDenseFactorization.hpp:397
CoinAbcAnyFactorization::maximumRows_
int maximumRows_
Maximum rows ever (i.e. use to copy arrays etc)
Definition: CoinAbcDenseFactorization.hpp:415
CoinAbcAnyFactorization::updateTwoColumnsFT
virtual int updateTwoColumnsFT(CoinIndexedVector &regionFT, CoinIndexedVector &regionOther)=0
does FTRAN on two unpacked columns
CoinAbcAnyFactorization::numberRows
int numberRows() const
Number of Rows after factorization.
Definition: CoinAbcDenseFactorization.hpp:87
CoinAbcDenseFactorization::permute
virtual int * permute() const
Returns permute in.
Definition: CoinAbcDenseFactorization.hpp:603
CoinAbcDenseFactorization::gutsOfInitialize
void gutsOfInitialize()
The real work of constructor.
CoinAbcDenseFactorization::updateTwoColumnsFT
virtual int updateTwoColumnsFT(CoinIndexedVector &regionFT, CoinIndexedVector &regionOther)
does FTRAN on two unpacked columns
CoinAbcAnyFactorization::pivotRegion
virtual CoinFactorizationDouble * pivotRegion() const
Definition: CoinAbcDenseFactorization.hpp:130
CoinAbcDenseFactorization::indices
virtual int * indices() const
Returns array to put basis indices in.
Definition: CoinAbcDenseFactorization.hpp:598
CoinAbcDenseFactorization::maximumSpace_
CoinBigIndex maximumSpace_
Maximum length of iterating area.
Definition: CoinAbcDenseFactorization.hpp:625
CoinAbcAnyFactorization::status
int status() const
Returns status.
Definition: CoinAbcDenseFactorization.hpp:45
CoinAbcAnyFactorization::pivotRow
virtual int * pivotRow() const
Returns pivot row.
CoinAbcAnyFactorization::updateColumnCpu
virtual void updateColumnCpu(CoinIndexedVector &regionSparse, int whichCpu) const
Updates one column (FTRAN)
CoinSimplexDouble
double CoinSimplexDouble
Definition: CoinAbcCommon.hpp:21
CoinAbcAnyFactorization::setNumberSlacks
void setNumberSlacks(int value)
Sets number of slacks.
Definition: CoinAbcDenseFactorization.hpp:77
CoinAbcAnyFactorization::updateColumnFT
virtual int updateColumnFT(CoinIndexedVector &regionSparse)=0
Updates one column (FTRAN) from unpacked regionSparse Tries to do FT update number returned is negati...
CoinAbcAnyFactorization::pivotTolerance
double pivotTolerance() const
Pivot tolerance.
Definition: CoinAbcDenseFactorization.hpp:119
CoinFactorizationDouble
double CoinFactorizationDouble
Definition: CoinTypes.hpp:57
CoinAbcDenseFactorization::updateColumnFTPart1
virtual int updateColumnFTPart1(CoinIndexedVector &regionSparse)
Definition: CoinAbcDenseFactorization.hpp:553
CoinAbcDenseFactorization::CoinAbcDenseFactorization
CoinAbcDenseFactorization()
Default constructor.
CoinAbcAnyFactorization::workArea_
CoinFactorizationDouble * workArea_
Work area of numberRows_.
Definition: CoinAbcDenseFactorization.hpp:427
CoinAbcDenseFactorization::postProcess
virtual void postProcess(const int *sequence, int *pivotVariable)
Does post processing on valid factorization - putting variables on correct rows.
CoinAbcDenseFactorization
This deals with Factorization and Updates This is a simple dense version so other people can write a ...
Definition: CoinAbcDenseFactorization.hpp:442
CoinIndexedVector
Indexed Vector.
Definition: CoinIndexedVector.hpp:104
CoinAbcAnyFactorization::numberGoodU_
int numberGoodU_
Number factorized in U (not row singletons)
Definition: CoinAbcDenseFactorization.hpp:405
CoinAbcDenseFactorization::makeNonSingular
virtual void makeNonSingular(int *sequence)
Makes a non-singular basis by replacing variables.
CoinAbcAnyFactorization::maximumPivots_
int maximumPivots_
Maximum number of pivots before factorization.
Definition: CoinAbcDenseFactorization.hpp:407
CoinAbcAnyFactorization::numberDense
CoinSimplexInt numberDense() const
Number of dense rows after factorization.
Definition: CoinAbcDenseFactorization.hpp:92
CoinAbcAnyFactorization::clone
virtual CoinAbcAnyFactorization * clone() const =0
Clone.
CoinAbcAnyFactorization::setUsefulInformation
virtual void setUsefulInformation(const int *info, int whereFrom)
Useful information for factorization 0 - iteration number whereFrom is 0 for factorize and 1 for repl...
CoinAbcAnyFactorization::pivotRow_
int * pivotRow_
Pivot row.
Definition: CoinAbcDenseFactorization.hpp:420
CoinAbcAnyFactorization::elements
virtual CoinFactorizationDouble * elements() const
Returns array to put basis elements in.
CoinAbcAnyFactorization::numberInRow
virtual int * numberInRow() const
Number of entries in each row.
CoinAbcAnyFactorization::numberGoodColumns
int numberGoodColumns() const
Number of good columns in factorization.
Definition: CoinAbcDenseFactorization.hpp:97
CoinAbcAnyFactorization::workArea
virtual CoinFactorizationDouble * workArea() const
Returns work area.
CoinAbcAnyFactorization::setNumberRows
void setNumberRows(int value)
Set number of Rows after factorization.
Definition: CoinAbcDenseFactorization.hpp:82
CoinAbcDenseFactorization::clone
virtual CoinAbcAnyFactorization * clone() const
Clone.
CoinAbcAnyFactorization::setStatus
void setStatus(int value)
Sets status.
Definition: CoinAbcDenseFactorization.hpp:50
CoinAbcAnyFactorization::checkReplacePart1
virtual double checkReplacePart1(CoinIndexedVector *, CoinIndexedVector *, int)
Definition: CoinAbcDenseFactorization.hpp:293
CoinAbcDenseFactorization::replaceColumnPart3
virtual void replaceColumnPart3(const AbcSimplex *model, CoinIndexedVector *regionSparse, CoinIndexedVector *tableauColumn, CoinIndexedVector *, int pivotRow, double alpha)
Replaces one Column to basis, partial update in vector.
Definition: CoinAbcDenseFactorization.hpp:528
CoinAbcAnyFactorization::indices
virtual int * indices() const =0
Returns array to put basis indices in.
CoinAbcAnyFactorization::numberDense_
int numberDense_
Number of dense rows in factorization.
Definition: CoinAbcDenseFactorization.hpp:403
CoinAbcAnyFactorization::operator=
CoinAbcAnyFactorization & operator=(const CoinAbcAnyFactorization &other)
= copy
CoinAbcAnyFactorization::updateColumnTransposeCpu
virtual void updateColumnTransposeCpu(CoinIndexedVector &regionSparse, int whichCpu) const
Updates one column (BTRAN)
CoinPackedMatrix
Sparse Matrix Base Class.
Definition: CoinPackedMatrix.hpp:79
CoinAbcAnyFactorization::updateColumn
virtual int updateColumn(CoinIndexedVector &regionSparse) const =0
This version has same effect as above with FTUpdate==false so number returned is always &gt;=0...
CoinAbcAnyFactorization::checkReplacePart1a
virtual void checkReplacePart1a(CoinIndexedVector *, int)
Definition: CoinAbcDenseFactorization.hpp:299
CoinAbcAnyFactorization::numberElements
virtual int numberElements() const =0
Total number of elements in factorization.
CoinAbcDenseFactorization::~CoinAbcDenseFactorization
virtual ~CoinAbcDenseFactorization()
Destructor.
CoinAbcDenseFactorization::gutsOfCopy
void gutsOfCopy(const CoinAbcDenseFactorization &other)
The real work of copy.
CoinAbcAnyFactorization::postProcess
virtual void postProcess(const int *sequence, int *pivotVariable)=0
Does post processing on valid factorization - putting variables on correct rows.
CoinAbcAnyFactorization::setPivots
void setPivots(int value)
Sets number of pivots since factorization.
Definition: CoinAbcDenseFactorization.hpp:67
CoinAbcDenseFactorization::updateColumnFT
virtual void updateColumnFT(CoinIndexedVector &regionSparseFT, CoinIndexedVector &, int)
Definition: CoinAbcDenseFactorization.hpp:560
CoinAbcAnyFactorization::getAreas
virtual void getAreas(int numberRows, int numberColumns, CoinBigIndex maximumL, CoinBigIndex maximumU)=0
Gets space for a factorization.
CoinAbcAnyFactorization::minimumPivotTolerance
double minimumPivotTolerance() const
Minimum pivot tolerance.
Definition: CoinAbcDenseFactorization.hpp:125
CoinAbcAnyFactorization::wantsTableauColumn
virtual bool wantsTableauColumn() const
Returns true if wants tableauColumn in replaceColumn.
CoinBigIndex
int CoinBigIndex
Definition: Coin_C_defines.h:136
CoinAbcDenseFactorization::getAreas
virtual void getAreas(int numberRows, int numberColumns, CoinBigIndex maximumL, CoinBigIndex maximumU)
Gets space for a factorization.
CoinAbcAnyFactorization::solveMode
int solveMode() const
Get solve mode e.g.
Definition: CoinAbcDenseFactorization.hpp:176
CoinAbcDenseFactorization::CoinAbcDenseFactorizationUnitTest
friend void CoinAbcDenseFactorizationUnitTest(const std::string &mpsDir)
CoinAbcDenseFactorization::maximumCoefficient
double maximumCoefficient() const
Returns maximum absolute value in factorization.
CoinAbcAnyFactorization::permute
virtual int * permute() const =0
Returns permute in.
CoinAbcDenseFactorization::updateColumnFT
virtual int updateColumnFT(CoinIndexedVector &regionSparse)
Updates one column (FTRAN) from unpacked regionSparse Tries to do FT update number returned is negati...
Definition: CoinAbcDenseFactorization.hpp:549
CoinAbcAnyFactorization::relaxAccuracyCheck
void relaxAccuracyCheck(double value)
Allows change of pivot accuracy check 1.0 == none &gt;1.0 relaxed.
Definition: CoinAbcDenseFactorization.hpp:102
CoinAbcAnyFactorization::checkReplacePart1b
virtual double checkReplacePart1b(CoinIndexedVector *, int)
Definition: CoinAbcDenseFactorization.hpp:303
CoinAbcDenseFactorization::clearArrays
void clearArrays()
Get rid of all memory.
Definition: CoinAbcDenseFactorization.hpp:593
CoinAbcAnyFactorization::preProcess
virtual void preProcess()=0
PreProcesses column ordered copy of basis.
CoinAbcDenseFactorization::checkPivot
int checkPivot(double saveFromU, double oldPivot) const
Returns accuracy status of replaceColumn returns 0=OK, 1=Probably OK, 2=singular. ...
CoinAbcAnyFactorization::updateWeights
virtual void updateWeights(CoinIndexedVector &regionSparse) const =0
Updates one column for dual steepest edge weights (FTRAN)
CoinAbcDenseFactorization::updateWeights
virtual void updateWeights(CoinIndexedVector &regionSparse) const
Updates one column for dual steepest edge weights (FTRAN)
CoinAbcAnyFactorization::pivotTolerance_
double pivotTolerance_
Pivot tolerance.
Definition: CoinAbcDenseFactorization.hpp:386
CoinAbcAnyFactorization::numberSlacks
int numberSlacks() const
Returns number of slacks.
Definition: CoinAbcDenseFactorization.hpp:72
CoinAbcAnyFactorization::checkReplacePart2
virtual int checkReplacePart2(int pivotRow, double btranAlpha, double ftranAlpha, double ftAlpha, double acceptablePivot=1.0e-8)=0
Checks if can replace one Column to basis, returns 0=OK, 1=Probably OK, 2=singular, 3=no room, 5 max pivots.
CoinIndexedVector.hpp
CoinAbcAnyFactorization::areaFactor_
double areaFactor_
Area factor.
Definition: CoinAbcDenseFactorization.hpp:390
CoinAbcAnyFactorization::intWorkArea
virtual int * intWorkArea() const
Returns int work area.
CoinSimplexInt
int CoinSimplexInt
Definition: CoinAbcCommon.hpp:22
CoinAbcAnyFactorization::numberInColumn
virtual int * numberInColumn() const
Number of entries in each column.
CoinAbcAnyFactorization::getAccuracyCheck
double getAccuracyCheck() const
Definition: CoinAbcDenseFactorization.hpp:106
CoinAbcAnyFactorization::setSolveMode
void setSolveMode(int value)
Set solve mode e.g.
Definition: CoinAbcDenseFactorization.hpp:184
CoinAbcAnyFactorization::pivots
int pivots() const
Returns number of pivots since factorization.
Definition: CoinAbcDenseFactorization.hpp:55
CoinAbcDenseFactorization::checkReplacePart2
virtual int checkReplacePart2(int pivotRow, double btranAlpha, double ftranAlpha, double ftAlpha, double acceptablePivot=1.0e-8)
Checks if can replace one Column to basis, returns 0=OK, 1=Probably OK, 2=singular, 3=no room, 5 max pivots.
CoinAbcDenseFactorization::operator=
CoinAbcDenseFactorization & operator=(const CoinAbcDenseFactorization &other)
= copy
CoinAbcAnyFactorization::minimumPivotTolerance_
double minimumPivotTolerance_
Minimum pivot tolerance.
Definition: CoinAbcDenseFactorization.hpp:388
CoinAbcDenseFactorization::gutsOfDestructor
void gutsOfDestructor()
The real work of desstructor.
CoinAbcAnyFactorization::status_
int status_
Status of factorization.
Definition: CoinAbcDenseFactorization.hpp:413
CoinAbcAnyFactorization::solveMode_
int solveMode_
Solve mode e.g.
Definition: CoinAbcDenseFactorization.hpp:432
CoinAbcAnyFactorization::starts
virtual CoinBigIndex * starts() const
Returns array to put basis starts in.
CoinAbcAnyFactorization::checkMarkArrays
virtual void checkMarkArrays() const
Definition: CoinAbcDenseFactorization.hpp:168
CoinAbcAnyFactorization::clearArrays
virtual void clearArrays()
Get rid of all memory.
Definition: CoinAbcDenseFactorization.hpp:196
CoinAbcAnyFactorization::maximumPivots
int maximumPivots() const
Maximum number of pivots between factorizations.
Definition: CoinAbcDenseFactorization.hpp:111
CoinAbcAnyFactorization::zeroTolerance_
double zeroTolerance_
Zero tolerance.
Definition: CoinAbcDenseFactorization.hpp:392
CoinAbcDenseFactorization::updateColumn
virtual int updateColumn(CoinIndexedVector &regionSparse) const
This version has same effect as above with FTUpdate==false so number returned is always &gt;=0...
CoinAbcAnyFactorization::goSparse
virtual void goSparse()
Sees whether to go sparse.
Definition: CoinAbcDenseFactorization.hpp:166
CoinAbcAnyFactorization::updateColumnFTPart2
virtual void updateColumnFTPart2(CoinIndexedVector &regionSparse)=0
CoinAbcAnyFactorization::factorElements_
CoinBigIndex factorElements_
Number of elements after factorization.
Definition: CoinAbcDenseFactorization.hpp:399
CoinAbcDenseFactorization::numberElements
virtual int numberElements() const
Total number of elements in factorization.
Definition: CoinAbcDenseFactorization.hpp:486
CoinAbcAnyFactorization::replaceColumnPart3
virtual void replaceColumnPart3(const AbcSimplex *model, CoinIndexedVector *regionSparse, CoinIndexedVector *tableauColumn, int pivotRow, double alpha)=0
Replaces one Column to basis, partial update already in U.