Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

lp.h
Go to the documentation of this file.
1 
30 #pragma once
31 
35 #include <ogdf/basic/Stopwatch.h>
36 
37 
38 #pragma GCC visibility push(default)
39 namespace abacus {
40 
41 class Master;
42 class SparVec;
43 class Row;
44 class Column;
45 
46 
48 
71 class OGDF_EXPORT LP : public AbacusRoot {
72 public:
73 
75  enum OPTSTAT {
77  Unoptimized,
80  Feasible,
84  LimitReached
85  };
86 
88  enum SOLSTAT {
90  Missing
91  };
92 
94  enum METHOD {
96  Dual,
99  Approximate
100  };
101 
103 
106  LP (Master *master) :
107  master_(master),
108  optStat_(Unoptimized),
109  xValStatus_(Missing),
110  barXValStatus_(Missing),
111  yValStatus_(Missing),
112  recoStatus_(Missing),
113  slackStatus_(Missing),
114  basisStatus_(Missing),
115  nOpt_(0)
116  { }
117 
119  virtual ~LP () { }
120 
137  friend OGDF_EXPORT std::ostream &operator<<(std::ostream& out, const LP& rhs);
138 
162  OptSense sense,
163  int nRow,
164  int maxRow,
165  int nCol,
166  int maxCol,
167  Array<double> &obj,
168  Array<double> &lBound,
169  Array<double> &uBound,
170  Array<Row*> &rows) {
171  _initialize(sense, nRow, maxRow, nCol, maxCol, obj, lBound, uBound, rows);
172  }
173 
191  OptSense sense,
192  int nRow, int maxRow,
193  int nCol, int maxCol,
194  Array<double> &obj,
195  Array<double> &lBound,
196  Array<double> &uBound,
197  Array<Row*> &rows,
198  Array<LPVARSTAT::STATUS> &lpVarStat,
199  Array<SlackStat::STATUS> &slackStat) {
200  _initialize(sense, nRow, maxRow, nCol, maxCol, obj, lBound, uBound, rows);
201  loadBasis(lpVarStat,slackStat);
202  }
203 
204 
210  virtual void loadBasis(
211  Array<LPVARSTAT::STATUS> &lpVarStat,
212  Array<SlackStat::STATUS> &slackStat) {
213  _loadBasis(lpVarStat,slackStat);
214  }
215 
216  OptSense sense() const { return _sense(); }
217 
218  void sense(const OptSense &newSense) { _sense(newSense); }
219 
220  int nRow() const { return _nRow(); }
221 
222  int maxRow() const { return _maxRow(); }
223 
224  int nCol() const { return _nCol(); }
225 
226  int maxCol() const { return _maxCol(); }
227 
228  int nnz() const { return _nnz(); }
229 
230  double obj(int i) const {
231 #ifdef OGDF_DEBUG
232  colRangeCheck(i);
233 #endif
234  return _obj(i);
235  }
236 
237  double lBound(int i) const {
238 #ifdef OGDF_DEBUG
239  colRangeCheck(i);
240 #endif
241  return _lBound(i);
242  }
243 
244  double uBound(int i) const {
245 #ifdef OGDF_DEBUG
246  colRangeCheck(i);
247 #endif
248  return _uBound(i);
249  }
250 
251  void row(int i, Row &r) const {
252 #ifdef OGDF_DEBUG
253  rowRangeCheck(i);
254 #endif
255  _row(i, r);
256  }
257 
258  double rhs(int i) const {
259 #ifdef ABACUSSAFE
260  rowRangeCheck(i);
261 #endif
262  return _rhs(i);
263  }
264 
265  virtual double value() const { return _value(); }
266 
267  virtual double xVal(int i) const {
268 #ifdef OGDF_DEBUG
269  colRangeCheck(i);
270 #endif
271  return _xVal(i);
272  }
273 
274  virtual double barXVal(int i) const {
275 #ifdef OGDF_DEBUG
276  colRangeCheck(i);
277 #endif
278  return _barXVal(i);
279  }
280 
281  virtual double reco(int i) const {
282 #ifdef OGDF_DEBUG
283  colRangeCheck(i);
284 #endif
285  return _reco(i);
286  }
287 
288  virtual double yVal(int c) const {
289 #ifdef OGDF_DEBUG
290  rowRangeCheck(c);
291 #endif
292  return _yVal(c);
293  }
294 
295  virtual double slack(int c) const {
296 #ifdef OGDF_DEBUG
297  rowRangeCheck(c);
298 #endif
299  return _slack(c);
300  }
301 
302  SOLSTAT xValStatus() const { return xValStatus_; }
303 
304  SOLSTAT barXValStatus() const { return barXValStatus_; }
305 
306  SOLSTAT yValStatus() const { return yValStatus_; }
307 
308  SOLSTAT recoStatus() const { return recoStatus_; }
309 
310  SOLSTAT slackStatus() const { return slackStatus_; }
311 
312  SOLSTAT basisStatus() const { return basisStatus_; }
313 
314  int nOpt() const { return nOpt_; }
315 
316  virtual bool infeasible() const {
317  return ( optStat_ == Infeasible );
318  }
319 
320 
347  virtual int getInfeas(int &infeasRow, int &infeasCol, double *bInvRow) const {
348  return _getInfeas(infeasRow,infeasCol,bInvRow);
349  }
350 
351  virtual LPVARSTAT::STATUS lpVarStat(int i) const {
352 #ifdef OGDF_DEBUG
353  colRangeCheck(i);
354 #endif
355  return _lpVarStat(i);
356  }
357 
358  virtual SlackStat::STATUS slackStat(int i) const {
359 #ifdef OGDF_DEBUG
360  rowRangeCheck(i);
361 #endif
362  return _slackStat(i);
363  }
364 
371  virtual OPTSTAT optimize(METHOD method);
372 
378  initPostOpt();
379  _remRows(ind);
380  }
381 
389  void addRows(ArrayBuffer<Row*> &newRows);
390 
395  void remCols(ArrayBuffer<int> &cols) {
396  initPostOpt();
397  _remCols(cols);
398  }
399 
407  void addCols(ArrayBuffer<Column*> &newCols);
408 
413  void changeRhs(Array<double> &newRhs) {
414  initPostOpt();
415  _changeRhs(newRhs);
416  }
417 
423  virtual void changeLBound(int i, double newLb);
424 
430  virtual void changeUBound(int i, double newUb);
431 
440  virtual int pivotSlackVariableIn(ArrayBuffer<int> &rows);
441 
446  void rowRealloc(int newSize) {
447  _rowRealloc(newSize);
448  }
449 
454  void colRealloc(int newSize) {
455  _colRealloc(newSize);
456  }
457 
458 
467  int writeBasisMatrix(const char *fileName);
468 
476  int setSimplexIterationLimit(int limit) {
477  return _setSimplexIterationLimit(limit);
478  }
479 
486  int getSimplexIterationLimit(int &limit) const {
487  return _getSimplexIterationLimit(limit);
488  }
489 
490  ogdf::StopwatchCPU* lpSolverTime() { return &lpSolverTime_; }
491 
492 protected:
493 
502  void colsNnz(int nRow, Array<Row*> &rows, Array<int> &nnz);
503 
518  void rows2cols(int nRow, Array<Row*> &rows,
519  Array<SparVec*> &cols);
520 
525  void rowRangeCheck(int r) const;
526 
531  void colRangeCheck(int i) const;
532 
536  virtual OptSense _sense() const = 0;
537  virtual void _sense(const OptSense &newSense) = 0;
538 
542  virtual int _nRow() const = 0;
543 
547  virtual int _maxRow() const = 0;
548 
552  virtual int _nCol() const = 0;
553 
557  virtual int _maxCol() const = 0;
558 
564  virtual int _nnz() const = 0;
565 
570  virtual double _obj(int i) const = 0;
571 
575  virtual double _lBound(int i) const = 0;
576 
580  virtual double _uBound(int i) const = 0;
581 
585  virtual double _rhs(int i) const = 0;
586 
590  virtual void _row(int i, Row &r) const = 0;
591 
605  virtual void _initialize(OptSense sense, int nRow, int maxRow,
606  int nCol, int maxCol,
607  Array<double> &obj, Array<double> &lBound,
608  Array<double> &uBound, Array<Row*> &rows) = 0;
609 
615  virtual void _loadBasis(Array<LPVARSTAT::STATUS> &lpVarStat,
616  Array<SlackStat::STATUS> &slackStat) = 0;
617 
622  virtual OPTSTAT _primalSimplex() = 0;
623 
628  virtual OPTSTAT _dualSimplex() = 0;
629 
634  virtual OPTSTAT _barrier(bool doCrossover) = 0;
635 
640  virtual OPTSTAT _approx() = 0;
641 
646  virtual double _value() const = 0;
647 
652  virtual double _xVal(int i) const = 0;
653  virtual double _barXVal(int i) const = 0;
654 
658  virtual double _reco(int i) const = 0;
659 
663  virtual double _slack(int i) const = 0;
664 
669  virtual double _yVal(int i) const = 0;
670 
675  virtual LPVARSTAT::STATUS _lpVarStat(int i) const = 0;
676 
681  virtual SlackStat::STATUS _slackStat(int i) const = 0;
682 
695  virtual int _getInfeas(int &infeasRow, int &infeasCol,
696  double *bInvRow) const = 0;
697 
702  virtual void _remRows(ArrayBuffer<int> &ind) = 0;
703 
708  virtual void _addRows(ArrayBuffer<Row*> &newRows) = 0;
709 
714  virtual void _remCols(ArrayBuffer<int> &vars) = 0;
715 
720  virtual void _addCols(ArrayBuffer<Column*> &newCols) = 0;
721 
726  virtual void _changeRhs(Array<double> &newRhs) = 0;
727 
732  virtual void _changeLBound(int i, double newLb) = 0;
733 
738  virtual void _changeUBound(int i, double newUb) = 0;
739 
749  virtual int _pivotSlackVariableIn(ArrayBuffer<int> &rows) = 0;
750 
756  virtual void _rowRealloc(int newSize) = 0;
757 
762  virtual void _colRealloc(int newSize) = 0;
763 
772  virtual int _setSimplexIterationLimit(int limit) = 0;
773 
783  virtual int _getSimplexIterationLimit(int &limit) const = 0;
784 
788 
792 
799 
806 
812 
819 
827 
830  int nOpt_;
832 
833 private:
834 
842  void initPostOpt() {
843  optStat_= Unoptimized;
844  xValStatus_= barXValStatus_= recoStatus_= Missing;
845  slackStatus_= yValStatus_= basisStatus_= Missing;
846  }
847 
848  LP(const LP &rhs);
849  const LP &operator=(const LP &rhs);
850 };
851 
852 
853 #if 0
854 inline OptSense LP::sense() const
855 {
856  return _sense();
857 }
858 
859 inline void LP::sense(const OptSense &newSense)
860 {
861  _sense(newSense);
862 }
863 
864 inline int LP::nRow() const
865 {
866  return _nRow();
867 }
868 
869 inline int LP::maxRow() const
870 {
871  return _maxRow();
872 }
873 
874 inline int LP::nCol() const
875 {
876  return _nCol();
877 }
878 
879 inline int LP::maxCol() const
880 {
881  return _maxCol();
882 }
883 
884 inline int LP::nnz() const
885 {
886  return _nnz();
887 }
888 
889 inline double LP::obj(int i) const
890 {
891 #ifdef OGDF_DEBUG
892  colRangeCheck(i);
893 #endif
894  return _obj(i);
895 }
896 
897 inline double LP::lBound(int i) const
898 {
899 #ifdef OGDF_DEBUG
900  colRangeCheck(i);
901 #endif
902  return _lBound(i);
903 }
904 
905 inline double LP::uBound(int i) const
906 {
907 #ifdef OGDF_DEBUG
908  colRangeCheck(i);
909 #endif
910  return _uBound(i);
911 }
912 
913 inline void LP::row(int i, Row &r) const
914 {
915 #ifdef OGDF_DEBUG
916  rowRangeCheck(i);
917 #endif
918  _row(i, r);
919 }
920 
921 inline double LP::rhs(int i) const
922 {
923 #ifdef ABACUSSAFE
924  rowRangeCheck(i);
925 #endif
926  return _rhs(i);
927 }
928 
929 inline double LP::value() const
930 {
931  return _value();
932 }
933 
934 inline double LP::xVal(int i)
935 {
936 #ifdef OGDF_DEBUG
937  colRangeCheck(i);
938 #endif
939  return _xVal(i);
940 }
941 
942 inline double LP::barXVal(int i)
943 {
944 #ifdef OGDF_DEBUG
945  colRangeCheck(i);
946 #endif
947  return _barXVal(i);
948 }
949 
950 inline double LP::reco(int i)
951 {
952 #ifdef OGDF_DEBUG
953  colRangeCheck(i);
954 #endif
955  return _reco(i);
956 }
957 
958 inline double LP::yVal(int c)
959 {
960 #ifdef OGDF_DEBUG
961  rowRangeCheck(c);
962 #endif
963  return _yVal(c);
964 }
965 
966 inline double LP::slack(int c)
967 {
968 #ifdef OGDF_DEBUG
969  rowRangeCheck(c);
970 #endif
971  return _slack(c);
972 }
973 
974 inline LP::SOLSTAT LP::xValStatus() const
975 {
976  return xValStatus_;
977 }
978 
979 inline LP::SOLSTAT LP::barXValStatus() const
980 {
981  return barXValStatus_;
982 }
983 
984 inline LP::SOLSTAT LP::recoStatus() const
985 {
986  return recoStatus_;
987 }
988 
989 inline LP::SOLSTAT LP::yValStatus() const
990 {
991  return yValStatus_;
992 }
993 
994 inline LP::SOLSTAT LP::slackStatus() const
995 {
996  return slackStatus_;
997 }
998 
999 inline LP::SOLSTAT LP::basisStatus() const
1000 {
1001  return basisStatus_;
1002 }
1003 
1004 inline int LP::nOpt() const
1005 {
1006  return nOpt_;
1007 }
1008 
1009 inline bool LP::infeasible() const
1010 {
1011  if (optStat_ == Infeasible) return true;
1012  else return false;
1013 }
1014 
1015 inline LPVARSTAT::STATUS LP::lpVarStat(int i)
1016 {
1017 #ifdef OGDF_DEBUG
1018  colRangeCheck(i);
1019 #endif
1020  return _lpVarStat(i);
1021 }
1022 
1023 inline SlackStat::STATUS LP::slackStat(int i)
1024 {
1025 #ifdef OGDF_DEBUG
1026  rowRangeCheck(i);
1027 #endif
1028  return _slackStat(i);
1029 }
1030 #endif
1031 
1032 }
1033 #pragma GCC visibility pop
ogdf::ArrayBuffer
An array that keeps track of the number of inserted elements; also usable as an efficient stack.
Definition: Array.h:53
lpvarstat.h
status of variables.
abacus::LP::rowRealloc
void rowRealloc(int newSize)
Performs a reallocation of the row space of the linear program.
Definition: lp.h:446
abacus::LP::BarrierAndCrossover
@ BarrierAndCrossover
The barrier method followed by a crossover to a basis.
Definition: lp.h:97
abacus::LP::reco
virtual double reco(int i) const
Definition: lp.h:281
abacus::LP::sense
OptSense sense() const
Definition: lp.h:216
abacus::LP::_row
virtual void _row(int i, Row &r) const =0
The pure virtual function _row() must be defined by the used LP-solver and store the i-th row of the ...
abacus::LP::yVal
virtual double yVal(int c) const
Definition: lp.h:288
abacus::LP::slackStatus
SOLSTAT slackStatus() const
Definition: lp.h:310
abacus::LP::basisStatus
SOLSTAT basisStatus() const
Definition: lp.h:312
abacus::LP::nOpt
int nOpt() const
Definition: lp.h:314
abacus::LP::initialize
void initialize(OptSense sense, int nRow, int maxRow, int nCol, int maxCol, Array< double > &obj, Array< double > &lBound, Array< double > &uBound, Array< Row * > &rows, Array< LPVARSTAT::STATUS > &lpVarStat, Array< SlackStat::STATUS > &slackStat)
This version of the function initialize() performs like its previous version, but also initializes th...
Definition: lp.h:190
abacus::LP::_barXVal
virtual double _barXVal(int i) const =0
abacus::operator<<
std::ostream & operator<<(std::ostream &out, const Active< BaseType, CoType > &rhs)
abacus::OptSense
Sense of optimization.
Definition: optsense.h:45
abacus::LP::recoStatus
SOLSTAT recoStatus() const
Definition: lp.h:308
abacus::LP::_lBound
virtual double _lBound(int i) const =0
The pure virtual function _lBound() must be defined by the used LP-solver and return the lower bound ...
abacus::LP::remCols
void remCols(ArrayBuffer< int > &cols)
Removes columns from the linear program.
Definition: lp.h:395
abacus::LP::recoStatus_
SOLSTAT recoStatus_
This member becomes Available if the reduced costs of the optimal solution can be accessed with the f...
Definition: lp.h:811
abacus
Definition: ILPClusterPlanarity.h:50
abacus::LP::Primal
@ Primal
The primal simplex method.
Definition: lp.h:95
abacus::LP::lpVarStat
virtual LPVARSTAT::STATUS lpVarStat(int i) const
Definition: lp.h:351
abacus::LP::xVal
virtual double xVal(int i) const
Definition: lp.h:267
abacus::LP::_slack
virtual double _slack(int i) const =0
The pure virtual function _slack() must be defined by the used LP-solver and should return the value ...
abacus::LPVARSTAT::STATUS
STATUS
The enumeration of the statuses a variable gets from the linear program solver.
Definition: lpvarstat.h:55
abacus::LP::_obj
virtual double _obj(int i) const =0
The pure virtual function _obj() must be defined by the used LP-solver and return the objective funct...
abacus::LP::_nnz
virtual int _nnz() const =0
The pure virtual function _nnz() must be defined by the used LP-solver and return the number of nonze...
abacus::LP::_maxCol
virtual int _maxCol() const =0
The pure virtual function _maxCol() must be defined by the the used LP-solver and return the maximal ...
abacus::LP::obj
double obj(int i) const
Definition: lp.h:230
abacus::LP::nnz
int nnz() const
Definition: lp.h:228
abacus::LP::_reco
virtual double _reco(int i) const =0
The pure virtual function _reco() must be defined by the used LP-solver and should return the reduced...
abacus::LP::basisStatus_
SOLSTAT basisStatus_
This member becomes Available if the status of the variables and the slack variables of the optimal s...
Definition: lp.h:826
ogdf::StopwatchCPU
Implements a stopwatch measuring CPU time.
Definition: Stopwatch.h:157
abacus::LP::slackStatus_
SOLSTAT slackStatus_
This member becomes Available if the values of the slack variables of the optimal solution can be acc...
Definition: lp.h:818
abacus::LP::_uBound
virtual double _uBound(int i) const =0
The pure virtual function _uBound() must be defined by the used LP-solver and return the upper bound ...
abacus::LP::lpSolverTime_
ogdf::StopwatchCPU lpSolverTime_
Definition: lp.h:831
abacus::LP::Optimal
@ Optimal
The optimal solution has been computed.
Definition: lp.h:76
abacus::SlackStat::STATUS
STATUS
The different statuses of a slack variable.
Definition: slackstat.h:52
abacus::LP::_maxRow
virtual int _maxRow() const =0
The pure virtual function _maxRow() must be defined by the used LP-solver and return the maximal numb...
abacus::LP::_nCol
virtual int _nCol() const =0
The pure virtual function _nCol() must be defined by the used LP-solver and return the number of colu...
abacus::LP::Unbounded
@ Unbounded
The linear program is unbounded.
Definition: lp.h:83
abacus::LP::slack
virtual double slack(int c) const
Definition: lp.h:295
abacus::LP::_yVal
virtual double _yVal(int i) const =0
The pure virtual function _yVal() must be defined by the used LP-solver and should return the value o...
abacus::LP::rowRangeCheck
void rowRangeCheck(int r) const
Terminates the program if there is no row with index r.
abacus::LP::colRealloc
void colRealloc(int newSize)
Performs a reallocation of the column space of the linear program.
Definition: lp.h:454
abacus::LP::_rhs
virtual double _rhs(int i) const =0
The pure virtual function _rhs() must be defined by the used LP-solver and return the right hand side...
abacus::LP::maxRow
int maxRow() const
Definition: lp.h:222
abacus::LP::yValStatus_
SOLSTAT yValStatus_
This member becomes Available if the values of the dual variables of the optimal solution can be acce...
Definition: lp.h:805
abacus::LP::barXValStatus
SOLSTAT barXValStatus() const
Definition: lp.h:304
abacus::LP::row
void row(int i, Row &r) const
Definition: lp.h:251
abacus::LP::slackStat
virtual SlackStat::STATUS slackStat(int i) const
Definition: lp.h:358
abacus::LP::Available
@ Available
The part of the solution is available.
Definition: lp.h:89
abacus::LP::master_
Master * master_
A pointer to the corresponding master of the optimization.
Definition: lp.h:787
abacus::LP::sense
void sense(const OptSense &newSense)
Definition: lp.h:218
r
int r[]
Definition: hierarchical-ranking.cpp:13
abacus::LP::OPTSTAT
OPTSTAT
The optimization status of the linear program.
Definition: lp.h:75
abacus::LP::yValStatus
SOLSTAT yValStatus() const
Definition: lp.h:306
abacus::LP::getSimplexIterationLimit
int getSimplexIterationLimit(int &limit) const
Definition: lp.h:486
abacus::LP::LP
LP(Master *master)
Creates a linear program.
Definition: lp.h:106
abacus::LP::nRow
int nRow() const
Definition: lp.h:220
abacus::AbacusRoot
Base class of all other classes of ABACUS.
Definition: abacusroot.h:69
abacus::LP::BarrierNoCrossover
@ BarrierNoCrossover
The barrier method without crossover.
Definition: lp.h:98
abacus::LP::getInfeas
virtual int getInfeas(int &infeasRow, int &infeasCol, double *bInvRow) const
Can be called if the last linear program has been solved with the dual simplex method and is infeasib...
Definition: lp.h:347
ogdf::Array
The parameterized class Array implements dynamic arrays of type E.
Definition: Array.h:219
abacus::LP::changeRhs
void changeRhs(Array< double > &newRhs)
Changes the complete right hand side of the linear program.
Definition: lp.h:413
optsense.h
sense of optimization.
abacus::Row
Representation of constraints in the row format.
Definition: row.h:52
abacus::LP::barXValStatus_
SOLSTAT barXValStatus_
Definition: lp.h:798
abacus::LP::uBound
double uBound(int i) const
Definition: lp.h:244
abacus::LP
Linear programs.
Definition: lp.h:71
abacus::LP::xValStatus
SOLSTAT xValStatus() const
Definition: lp.h:302
Stopwatch.h
Declaration of stopwatch classes.
abacus::LP::barXVal
virtual double barXVal(int i) const
Definition: lp.h:274
abacus::LP::nCol
int nCol() const
Definition: lp.h:224
abacus::LP::initialize
void initialize(OptSense sense, int nRow, int maxRow, int nCol, int maxCol, Array< double > &obj, Array< double > &lBound, Array< double > &uBound, Array< Row * > &rows)
Loads the linear program defined by its arguments.
Definition: lp.h:161
abacus::LP::_value
virtual double _value() const =0
The pure virtual function _value() must be defined by the used LP-solver and should return the optimu...
abacus::LP::METHOD
METHOD
The solution method for the linear program.
Definition: lp.h:94
abacus::LP::colRangeCheck
void colRangeCheck(int i) const
Terminates the program if there is no column with index i.
abacus::LP::xValStatus_
SOLSTAT xValStatus_
This member becomes Available if the -values of the optimal solution can be accessed with the functio...
Definition: lp.h:797
abacus::LP::value
virtual double value() const
Definition: lp.h:265
abacus::LP::Dual
@ Dual
The dual simplex method.
Definition: lp.h:96
abacus::LP::_slackStat
virtual SlackStat::STATUS _slackStat(int i) const =0
The pure virtual function _slackStat() must be defined by the used LP-solver and should return the st...
abacus::LP::infeasible
virtual bool infeasible() const
Definition: lp.h:316
abacus::LP::setSimplexIterationLimit
int setSimplexIterationLimit(int limit)
Changes the iteration limit of the Simplex algorithm.
Definition: lp.h:476
abacus::LP::remRows
void remRows(ArrayBuffer< int > &ind)
Removes rows of the linear program.
Definition: lp.h:377
abacus::LP::rhs
double rhs(int i) const
Definition: lp.h:258
abacus::LP::_xVal
virtual double _xVal(int i) const =0
The pure virtual function _xVal() must be defined by the used LP-solver and should return the value o...
abacus::LP::maxCol
int maxCol() const
Definition: lp.h:226
OGDF_EXPORT
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF dynamic library (shared object / DLL),...
Definition: config.h:117
ogdf::AlgorithmFailureCode::SparVec
@ SparVec
abacus::LP::initPostOpt
void initPostOpt()
Resets the optimization status and the availability statuses of the solution.
Definition: lp.h:842
abacus::LP::SOLSTAT
SOLSTAT
Describes if parts of the solution like x-values, reduced costs, etc. are available.
Definition: lp.h:88
abacus::LP::lBound
double lBound(int i) const
Definition: lp.h:237
abacus::LP::loadBasis
virtual void loadBasis(Array< LPVARSTAT::STATUS > &lpVarStat, Array< SlackStat::STATUS > &slackStat)
Loads a new basis for the linear program.
Definition: lp.h:210
abacus::LP::Error
@ Error
An error has happened during optimization.
Definition: lp.h:79
abacus::LP::_nRow
virtual int _nRow() const =0
The pure virtual function _nRow() must be defined by the used LP-solver and return the number of rows...
abacus::LP::Infeasible
@ Infeasible
The linear program is primal infeasible.
Definition: lp.h:82
abacus::LP::lpSolverTime
ogdf::StopwatchCPU * lpSolverTime()
Definition: lp.h:490
abacus::LP::_lpVarStat
virtual LPVARSTAT::STATUS _lpVarStat(int i) const =0
The pure virtual function _lpVarStat() must be defined by the used LP-solver and should return the st...
abacus::LP::~LP
virtual ~LP()
The destructor.
Definition: lp.h:119
abacus::LP::_sense
virtual OptSense _sense() const =0
The pure virtual function _sense() must be defined by the used LP-solver and return the sense of the ...
abacus::Master
The master of the optimization.
Definition: master.h:70
abacus::LP::nOpt_
int nOpt_
The number of optimizations of the linear program.
Definition: lp.h:830
slackstat.h
status of slack variables
abacus::LP::optStat_
OPTSTAT optStat_
The status of the linear program.
Definition: lp.h:791