Clp  1.17.8
AbcSimplex.hpp
Go to the documentation of this file.
1 /* $Id$ */
2 // Copyright (C) 2002, 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  Authors
7 
8  John Forrest
9 
10 */
11 #ifndef AbcSimplex_H
12 #define AbcSimplex_H
13 
14 #include <iostream>
15 #include <cfloat>
16 #include "ClpModel.hpp"
17 #include "ClpMatrixBase.hpp"
18 #include "CoinIndexedVector.hpp"
19 #include "AbcCommon.hpp"
20 class AbcSimplex;
21 #include "ClpSolve.hpp"
22 #include "CoinAbcCommon.hpp"
23 #include "ClpSimplex.hpp"
24 class AbcDualRowPivot;
27 class AbcNonLinearCost;
28 class OsiAbcSolverInterface;
29 class CoinWarmStartBasis;
30 class ClpDisasterHandler;
31 class AbcSimplexProgress;
32 class AbcMatrix;
33 class AbcTolerancesEtc;
34 
52 #define PAN
53 #if ABC_NORMAL_DEBUG > 0
54 #define PRINT_PAN 1
55 #endif
56 #define TRY_ABC_GUS
57 #define HEAVY_PERTURBATION 57
58 #if ABC_PARALLEL == 1
59 // Use pthreads
60 #include <pthread.h>
61 #endif
62 class AbcSimplex : public ClpSimplex {
63  friend void AbcSimplexUnitTest(const std::string &mpsDir);
64 
65 public:
74  enum Status {
75  atLowerBound = 0x00, // so we can use bottom two bits to sort and swap signs
76  atUpperBound = 0x01,
77  isFree = 0x04,
78  superBasic = 0x05,
79  basic = 0x06,
80  isFixed = 0x07
81  };
82  // For Dual
83  enum FakeBound {
84  noFake = 0x00,
85  lowerFake = 0x01,
86  upperFake = 0x02,
87  bothFake = 0x03
88  };
89 
92  AbcSimplex(bool emptyMessages = false);
94 
97  AbcSimplex(const AbcSimplex &rhs);
100  AbcSimplex(const ClpSimplex &rhs);
107  AbcSimplex(const ClpSimplex *wholeModel,
108  int numberRows, const int *whichRows,
109  int numberColumns, const int *whichColumns,
110  bool dropNames = true, bool dropIntegers = true,
111  bool fixOthers = false);
118  AbcSimplex(const AbcSimplex *wholeModel,
119  int numberRows, const int *whichRows,
120  int numberColumns, const int *whichColumns,
121  bool dropNames = true, bool dropIntegers = true,
122  bool fixOthers = false);
126  AbcSimplex(AbcSimplex *wholeModel,
127  int numberColumns, const int *whichColumns);
130  void originalModel(AbcSimplex *miniModel);
132  AbcSimplex(const ClpSimplex *clpSimplex);
134  void putBackSolution(ClpSimplex *simplex);
140  //void setPersistenceFlag(int value);
142  void makeBaseModel();
144  void deleteBaseModel();
146  inline AbcSimplex *baseModel() const
147  {
148  return abcBaseModel_;
149  }
153  void setToBaseModel(AbcSimplex *model = NULL);
155  AbcSimplex &operator=(const AbcSimplex &rhs);
157  ~AbcSimplex();
159 
164  int dual();
165  int doAbcDual();
168  int primal(int ifValuesPass);
169  int doAbcPrimal(int ifValuesPass);
171  CoinWarmStartBasis *getBasis() const;
187  int tightenPrimalBounds();
196 
199  inline AbcSimplexFactorization *factorization() const
201  {
202  return reinterpret_cast< AbcSimplexFactorization * >(abcFactorization_);
203  }
204 #ifdef EARLY_FACTORIZE
205  inline AbcSimplexFactorization *earlyFactorization() const
207  {
208  return reinterpret_cast< AbcSimplexFactorization * >(abcEarlyFactorization_);
209  }
210 #endif
211  int factorizationFrequency() const;
213  void setFactorizationFrequency(int value);
215  inline int maximumAbcNumberRows() const
216  {
217  return maximumAbcNumberRows_;
218  }
220  inline int maximumNumberTotal() const
221  {
222  return maximumNumberTotal_;
223  }
224  inline int maximumTotal() const
225  {
226  return maximumNumberTotal_;
227  }
229  bool isObjectiveLimitTestValid() const;
231  inline int numberTotal() const
232  {
233  return numberTotal_;
234  }
236  inline int numberTotalWithoutFixed() const
237  {
239  }
241  inline CoinPartitionedVector *usefulArray(int index)
242  {
243  return &usefulArray_[index];
244  }
245  inline CoinPartitionedVector *usefulArray(int index) const
246  {
247  return const_cast< CoinPartitionedVector * >(&usefulArray_[index]);
248  }
250 
251  /******************** End of most useful part **************/
257  int getSolution();
265  void setupDualValuesPass(const double *fakeDuals,
266  const double *fakePrimals,
267  int type);
269  inline double minimizationObjectiveValue() const
270  {
272  }
274  inline double currentDualTolerance() const
275  {
276  return currentDualTolerance_;
277  }
278  inline void setCurrentDualTolerance(double value)
279  {
280  currentDualTolerance_ = value;
281  }
284  {
285  return abcNonLinearCost_;
286  }
288  double *perturbationSaved() const
289  {
290  return perturbationSaved_;
291  }
293  inline double acceptablePivot() const
294  {
295  return acceptablePivot_;
296  }
298  inline int ordinaryVariables() const
299  {
300  return ordinaryVariables_;
301  }
303  inline int numberOrdinary() const
304  {
305  return numberOrdinary_;
306  }
308  inline void setNumberOrdinary(int number)
309  {
310  numberOrdinary_ = number;
311  }
313  inline double currentDualBound() const
314  {
315  return currentDualBound_;
316  }
319  {
320  return abcDualRowPivot_;
321  }
324  {
325  return abcPrimalColumnPivot_;
326  }
328  inline AbcMatrix *abcMatrix() const
329  {
330  return abcMatrix_;
331  }
341  int internalFactorize(int solveType);
357  void permuteIn();
359  void permuteBasis();
361  void permuteOut(int whatsWanted);
365  void restoreData(ClpDataSave saved);
367  void cleanStatus(bool valuesPass = false);
370  int computeDuals(double *givenDjs, CoinIndexedVector *array1, CoinIndexedVector *array2);
372  int computePrimals(CoinIndexedVector *array1, CoinIndexedVector *array2);
374  void computeObjective();
376  void setMultipleSequenceIn(int sequenceIn[4]);
381  inline void unpack(CoinIndexedVector &rowArray) const
382  {
384  }
388  void unpack(CoinIndexedVector &rowArray, int sequence) const;
393  int housekeeping(/*double objectiveChange*/);
396  void checkPrimalSolution(bool justBasic);
399  void checkDualSolution();
404  void checkBothSolutions();
406  int gutsOfSolution(int type);
408  int gutsOfPrimalSolution(int type);
410  void saveGoodStatus();
412  void restoreGoodStatus(int type);
413 #define rowUseScale_ scaleFromExternal_
414 #define inverseRowUseScale_ scaleToExternal_
415  void refreshCosts();
417  void refreshLower(unsigned int type = ~(ROW_LOWER_SAME | COLUMN_UPPER_SAME));
418  void refreshUpper(unsigned int type = ~(ROW_LOWER_SAME | COLUMN_LOWER_SAME));
420  void setupPointers(int maxRows, int maxColumns);
422  void copyFromSaved(int type = 31);
424  void fillPerturbation(int start, int number);
426  void checkArrays(int ignoreEmpty = 0) const;
428  void checkDjs(int type = 1) const;
430  void checkSolutionBasic() const;
432  void checkMoveBack(bool checkDuals);
433 
434 public:
445  void setValuesPassAction(double incomingInfeasibility,
446  double allowedInfeasibility);
449  int cleanFactorization(int ifValuesPass);
451  void moveStatusToClp(ClpSimplex *clpModel);
453  void moveStatusFromClp(ClpSimplex *clpModel);
455 
457 public:
459  inline double clpObjectiveValue() const
460  {
462  }
465  inline int *pivotVariable() const
466  {
467  return abcPivotVariable_;
468  }
470  inline int stateOfProblem() const
471  {
472  return stateOfProblem_;
473  }
475  inline void setStateOfProblem(int value)
476  {
477  stateOfProblem_ = value;
478  }
480  //inline int * fromExternal() const
481  //{ return fromExternal_;}
483  //inline int * toExternal() const
484  //{return toExternal_;}
487  inline double *scaleFromExternal() const
488  {
489  return scaleFromExternal_;
490  }
493  inline double *scaleToExternal() const
494  {
495  return scaleToExternal_;
496  }
498  inline double *rowScale2() const
499  {
500  return rowUseScale_;
501  }
502  inline double *inverseRowScale2() const
503  {
504  return inverseRowUseScale_;
505  }
506  inline double *inverseColumnScale2() const
507  {
508  return inverseColumnUseScale_;
509  }
510  inline double *columnScale2() const
511  {
512  return columnUseScale_;
513  }
514  inline int arrayForDualColumn() const
515  {
516  return arrayForDualColumn_;
517  }
519  inline double upperTheta() const
520  {
521  return upperTheta_;
522  }
523  inline int arrayForReplaceColumn() const
524  {
525  return arrayForReplaceColumn_;
526  }
527  inline int arrayForFlipBounds() const
528  {
529  return arrayForFlipBounds_;
530  }
531  inline int arrayForFlipRhs() const
532  {
533  return arrayForFlipRhs_;
534  }
535  inline int arrayForBtran() const
536  {
537  return arrayForBtran_;
538  }
539  inline int arrayForFtran() const
540  {
541  return arrayForFtran_;
542  }
543  inline int arrayForTableauRow() const
544  {
545  return arrayForTableauRow_;
546  }
548  double valueIncomingDual() const;
550  const double *getColSolution() const;
551 
553  const double *getRowPrice() const;
554 
556  const double *getReducedCost() const;
557 
560  const double *getRowActivity() const;
562 
568  int gutsOfSolution(double *givenDuals,
569  const double *givenPrimals,
570  bool valuesPass = false);
572  void gutsOfDelete(int type);
574  void gutsOfCopy(const AbcSimplex &rhs);
576  void gutsOfInitialize(int numberRows, int numberColumns, bool doMore);
578  void gutsOfResize(int numberRows, int numberColumns);
582  void translate(int type);
584  void moveToBasic(int which = 15);
586 public:
589  inline double *solutionRegion() const
591  {
592  return abcSolution_;
593  }
594  inline double *djRegion() const
595  {
596  return abcDj_;
597  }
598  inline double *lowerRegion() const
599  {
600  return abcLower_;
601  }
602  inline double *upperRegion() const
603  {
604  return abcUpper_;
605  }
606  inline double *costRegion() const
607  {
608  return abcCost_;
609  }
611  inline double *solutionRegion(int which) const
612  {
613  return abcSolution_ + which * maximumAbcNumberRows_;
614  }
615  inline double *djRegion(int which) const
616  {
617  return abcDj_ + which * maximumAbcNumberRows_;
618  }
619  inline double *lowerRegion(int which) const
620  {
621  return abcLower_ + which * maximumAbcNumberRows_;
622  }
623  inline double *upperRegion(int which) const
624  {
625  return abcUpper_ + which * maximumAbcNumberRows_;
626  }
627  inline double *costRegion(int which) const
628  {
629  return abcCost_ + which * maximumAbcNumberRows_;
630  }
632  inline double *solutionBasic() const
633  {
634  return solutionBasic_;
635  }
636  inline double *djBasic() const
637  {
638  return djBasic_;
639  }
640  inline double *lowerBasic() const
641  {
642  return lowerBasic_;
643  }
644  inline double *upperBasic() const
645  {
646  return upperBasic_;
647  }
648  inline double *costBasic() const
649  {
650  return costBasic_;
651  }
653  inline double *abcPerturbation() const
654  {
655  return abcPerturbation_;
656  }
658  inline double *fakeDjs() const
659  {
660  return djSaved_;
661  }
662  inline unsigned char *internalStatus() const
663  {
664  return internalStatus_;
665  }
666  inline AbcSimplex::Status getInternalStatus(int sequence) const
667  {
668  return static_cast< Status >(internalStatus_[sequence] & 7);
669  }
670  inline AbcSimplex::Status getInternalColumnStatus(int sequence) const
671  {
672  return static_cast< Status >(internalStatus_[sequence + maximumAbcNumberRows_] & 7);
673  }
674  inline void setInternalStatus(int sequence, AbcSimplex::Status newstatus)
675  {
676  unsigned char &st_byte = internalStatus_[sequence];
677  st_byte = static_cast< unsigned char >(st_byte & ~7);
678  st_byte = static_cast< unsigned char >(st_byte | newstatus);
679  }
680  inline void setInternalColumnStatus(int sequence, AbcSimplex::Status newstatus)
681  {
682  unsigned char &st_byte = internalStatus_[sequence + maximumAbcNumberRows_];
683  st_byte = static_cast< unsigned char >(st_byte & ~7);
684  st_byte = static_cast< unsigned char >(st_byte | newstatus);
685  }
690  void setInitialDenseFactorization(bool onOff);
691  bool initialDenseFactorization() const;
693  inline int sequenceIn() const
694  {
695  return sequenceIn_;
696  }
697  inline int sequenceOut() const
698  {
699  return sequenceOut_;
700  }
702  inline void setSequenceIn(int sequence)
703  {
704  sequenceIn_ = sequence;
705  }
706  inline void setSequenceOut(int sequence)
707  {
708  sequenceOut_ = sequence;
709  }
710 #if 0
711 
712  inline int sequenceInternalIn() const {
713  return sequenceInternalIn_;
714  }
715  inline int sequenceInternalOut() const {
716  return sequenceInternalOut_;
717  }
719  inline void setSequenceInternalIn(int sequence) {
720  sequenceInternalIn_ = sequence;
721  }
722  inline void setSequenceInternalOut(int sequence) {
723  sequenceInternalOut_ = sequence;
724  }
725 #endif
726  inline int isColumn(int sequence) const
728  {
729  return sequence >= maximumAbcNumberRows_ ? 1 : 0;
730  }
732  inline int sequenceWithin(int sequence) const
733  {
734  return sequence < maximumAbcNumberRows_ ? sequence : sequence - maximumAbcNumberRows_;
735  }
737  inline int lastPivotRow() const
738  {
739  return lastPivotRow_;
740  }
742  inline int firstFree() const
743  {
744  return firstFree_;
745  }
747  inline int lastFirstFree() const
748  {
749  return lastFirstFree_;
750  }
752  inline int freeSequenceIn() const
753  {
754  return freeSequenceIn_;
755  }
757  inline double currentAcceptablePivot() const
758  {
760  }
761 #ifdef PAN
762 
768  inline int fakeSuperBasic(int iSequence)
769  {
770  if ((internalStatus_[iSequence] & 7) == 4)
771  return 0; // free
772  if ((internalStatus_[iSequence] & 7) != 5)
773  return -2;
774  double value = abcSolution_[iSequence];
775  if (value < abcLower_[iSequence] + primalTolerance_) {
776  if (abcDj_[iSequence] >= -currentDualTolerance_) {
777  setInternalStatus(iSequence, atLowerBound);
778 #if PRINT_PAN > 1
779  printf("Pansetting %d to lb\n", iSequence);
780 #endif
781  return -1;
782  } else {
783  return 1;
784  }
785  } else if (value > abcUpper_[iSequence] - primalTolerance_) {
786  if (abcDj_[iSequence] <= currentDualTolerance_) {
787  setInternalStatus(iSequence, atUpperBound);
788 #if PRINT_PAN > 1
789  printf("Pansetting %d to ub\n", iSequence);
790 #endif
791  return -1;
792  } else {
793  return 1;
794  }
795  } else {
796  return 0;
797  }
798  }
799 #endif
800  inline double solution(int sequence)
802  {
803  return abcSolution_[sequence];
804  }
806  inline double &solutionAddress(int sequence)
807  {
808  return abcSolution_[sequence];
809  }
810  inline double reducedCost(int sequence)
811  {
812  return abcDj_[sequence];
813  }
814  inline double &reducedCostAddress(int sequence)
815  {
816  return abcDj_[sequence];
817  }
818  inline double lower(int sequence)
819  {
820  return abcLower_[sequence];
821  }
823  inline double &lowerAddress(int sequence)
824  {
825  return abcLower_[sequence];
826  }
827  inline double upper(int sequence)
828  {
829  return abcUpper_[sequence];
830  }
832  inline double &upperAddress(int sequence)
833  {
834  return abcUpper_[sequence];
835  }
836  inline double cost(int sequence)
837  {
838  return abcCost_[sequence];
839  }
841  inline double &costAddress(int sequence)
842  {
843  return abcCost_[sequence];
844  }
846  inline double originalLower(int iSequence) const
847  {
848  if (iSequence < numberColumns_)
849  return columnLower_[iSequence];
850  else
851  return rowLower_[iSequence - numberColumns_];
852  }
854  inline double originalUpper(int iSequence) const
855  {
856  if (iSequence < numberColumns_)
857  return columnUpper_[iSequence];
858  else
859  return rowUpper_[iSequence - numberColumns_];
860  }
862  inline AbcSimplexProgress *abcProgress()
863  {
864  return &abcProgress_;
865  }
866 #ifdef ABC_SPRINT
867  AbcSimplex *createSubProblem(int numberColumns, const int *whichColumn);
870  void restoreFromSubProblem(AbcSimplex *fullProblem, const int *whichColumn);
871 #endif
872 public:
875  inline void clearArraysPublic(int which)
876  {
877  clearArrays(which);
878  }
881  inline int getAvailableArrayPublic() const
882  {
883  return getAvailableArray();
884  }
885 #if ABC_PARALLEL
886  inline int parallelMode() const
888  {
889  return parallelMode_;
890  }
892  inline void setParallelMode(int value)
893  {
894  parallelMode_ = value;
895  }
897  inline int numberCpus() const
898  {
899  return parallelMode_ + 1;
900  }
901 #if ABC_PARALLEL == 1
902  inline void setStopStart(int value)
904  {
905  stopStart_ = value;
906  }
907 #endif
908 #endif
909  //protected:
911  void clearArrays(int which);
913  void clearArrays(CoinPartitionedVector *which);
915  int getAvailableArray() const;
917  inline void setUsedArray(int which) const
918  {
919  int check = 1 << which;
920  assert((stateOfProblem_ & check) == 0);
921  stateOfProblem_ |= check;
922  }
924  inline void setAvailableArray(int which) const
925  {
926  int check = 1 << which;
927  assert((stateOfProblem_ & check) != 0);
928  assert(!usefulArray_[which].getNumElements());
929  stateOfProblem_ &= ~check;
930  }
932  void swapPrimalStuff();
934  void swapDualStuff(int lastSequenceOut, int lastDirectionOut);
935 
936 protected:
938 
940  void swap(int pivotRow, int nonBasicPosition, Status newStatus);
942  inline void setFakeBound(int sequence, FakeBound fakeBound)
943  {
944  unsigned char &st_byte = internalStatus_[sequence];
945  st_byte = static_cast< unsigned char >(st_byte & ~24);
946  st_byte = static_cast< unsigned char >(st_byte | (fakeBound << 3));
947  }
948  inline FakeBound getFakeBound(int sequence) const
949  {
950  return static_cast< FakeBound >((internalStatus_[sequence] >> 3) & 3);
951  }
952  bool atFakeBound(int sequence) const;
953  inline void setPivoted(int sequence)
954  {
955  internalStatus_[sequence] = static_cast< unsigned char >(internalStatus_[sequence] | 32);
956  }
957  inline void clearPivoted(int sequence)
958  {
959  internalStatus_[sequence] = static_cast< unsigned char >(internalStatus_[sequence] & ~32);
960  }
961  inline bool pivoted(int sequence) const
962  {
963  return (((internalStatus_[sequence] >> 5) & 1) != 0);
964  }
965 
966 public:
968  void swap(int pivotRow, int nonBasicPosition);
970  void setFlagged(int sequence);
971  inline void clearFlagged(int sequence)
972  {
973  internalStatus_[sequence] = static_cast< unsigned char >(internalStatus_[sequence] & ~64);
974  }
975  inline bool flagged(int sequence) const
976  {
977  return ((internalStatus_[sequence] & 64) != 0);
978  }
979 
980 protected:
982  inline void setActive(int iRow)
983  {
984  internalStatus_[iRow] = static_cast< unsigned char >(internalStatus_[iRow] | 128);
985  }
986  inline void clearActive(int iRow)
987  {
988  internalStatus_[iRow] = static_cast< unsigned char >(internalStatus_[iRow] & ~128);
989  }
990  inline bool active(int iRow) const
991  {
992  return ((internalStatus_[iRow] & 128) != 0);
993  }
994 
995 public:
998  void createStatus();
1000  void crash(int type);
1005  void putStuffInBasis(int type);
1008  void allSlackBasis();
1010  void checkConsistentPivots() const;
1012  void printStuff() const;
1014  int startup(int ifValuesPass);
1015 
1017  inline double rawObjectiveValue() const
1018  {
1019  return objectiveValue_;
1020  }
1022  void computeObjectiveValue(bool useWorkingSolution = false);
1026  void moveInfo(const AbcSimplex &rhs, bool justStatus = false);
1027 #ifndef NUMBER_THREADS
1028 #define NUMBER_THREADS 3
1029 #endif
1030 #if ABC_PARALLEL == 1
1031  // For waking up thread
1032  inline pthread_mutex_t *mutexPointer(int which, int thread = 0)
1033  {
1034  return mutex_ + which + 3 * thread;
1035  }
1036  inline pthread_barrier_t *barrierPointer()
1037  {
1038  return &barrier_;
1039  }
1040  inline int whichLocked(int thread = 0) const
1041  {
1042  return locked_[thread];
1043  }
1044  inline CoinThreadInfo *threadInfoPointer(int thread = 0)
1045  {
1046  return threadInfo_ + thread;
1047  }
1048  void startParallelStuff(int type);
1049  int stopParallelStuff(int type);
1051  int whichThread() const;
1052 #elif ABC_PARALLEL == 2
1053  //inline CoinThreadInfo * threadInfoPointer(int thread=0)
1054  //{ return threadInfo_+thread;}
1055 #endif
1056 
1057 
1058  //-------------------------------------------------------------------------
1062  void setObjectiveCoefficient(int elementIndex, double elementValue);
1064  inline void setObjCoeff(int elementIndex, double elementValue)
1065  {
1066  setObjectiveCoefficient(elementIndex, elementValue);
1067  }
1068 
1071  void setColumnLower(int elementIndex, double elementValue);
1072 
1075  void setColumnUpper(int elementIndex, double elementValue);
1076 
1078  void setColumnBounds(int elementIndex,
1079  double lower, double upper);
1080 
1089  void setColumnSetBounds(const int *indexFirst,
1090  const int *indexLast,
1091  const double *boundList);
1092 
1095  inline void setColLower(int elementIndex, double elementValue)
1096  {
1097  setColumnLower(elementIndex, elementValue);
1098  }
1101  inline void setColUpper(int elementIndex, double elementValue)
1102  {
1103  setColumnUpper(elementIndex, elementValue);
1104  }
1105 
1107  inline void setColBounds(int elementIndex,
1108  double newlower, double newupper)
1109  {
1110  setColumnBounds(elementIndex, newlower, newupper);
1111  }
1112 
1119  inline void setColSetBounds(const int *indexFirst,
1120  const int *indexLast,
1121  const double *boundList)
1122  {
1123  setColumnSetBounds(indexFirst, indexLast, boundList);
1124  }
1125 
1128  void setRowLower(int elementIndex, double elementValue);
1129 
1132  void setRowUpper(int elementIndex, double elementValue);
1133 
1135  void setRowBounds(int elementIndex,
1136  double lower, double upper);
1137 
1144  void setRowSetBounds(const int *indexFirst,
1145  const int *indexLast,
1146  const double *boundList);
1148  void resize(int newNumberRows, int newNumberColumns);
1149 
1151 
1153 protected:
1160  double sumNonBasicCosts_;
1176  double largestGap_;
1188  double movement_;
1192  double btranAlpha_;
1194 #ifdef ABC_LONG_FACTORIZATION
1195  long
1196 #endif
1197  double ftAlpha_;
1202 
1203 public:
1206 
1207 protected:
1228  /*
1229  May want to put some arrays into struct
1230  Two arrays point to/from external
1231  Order is basic,unused basic, at lower, at upper, superbasic, free, fixed with starts
1232  */
1238 #define startAtLowerNoOther_ maximumAbcNumberRows_
1239  int startAtLowerOther_;
1249 #ifdef EARLY_FACTORIZE
1250  int numberEarly_;
1252 #endif
1253 
1270 #define ALL_STATUS_OK 2048
1271 #define ROW_PRIMAL_OK 4096
1272 #define ROW_DUAL_OK 8192
1273 #define COLUMN_PRIMAL_OK 16384
1274 #define COLUMN_DUAL_OK 32768
1275 #define PESSIMISTIC 65536
1276 #define ADD_A_BIT 131072
1277 #define DO_SCALE_AND_MATRIX 262144
1278 #define DO_BASIS_AND_ORDER 524288
1279 #define DO_STATUS 1048576
1280 #define DO_SOLUTION 2097152
1281 #define DO_JUST_BOUNDS 0x400000
1282 #define NEED_BASIS_SORT 0x800000
1283 #define FAKE_SUPERBASIC 0x1000000
1284 #define VALUES_PASS 0x2000000
1285 #define VALUES_PASS2 0x4000000
1286  mutable int stateOfProblem_;
1287 #if ABC_PARALLEL
1288 public:
1290  int parallelMode_;
1291 
1292 protected:
1293 #endif
1294  int numberOrdinary_;
1309  //int * fromExternal_;
1311  //int * toExternal_;
1325  double *offset_;
1327  double *offsetRhs_;
1329  double *tempArray_;
1334  unsigned char *internalStatus_;
1336  unsigned char *internalStatusSaved_;
1348  double *abcLower_;
1351  double *abcUpper_;
1357  double *abcCost_;
1360  double *abcSolution_;
1363  double *abcDj_;
1365  double *lowerSaved_;
1367  double *upperSaved_;
1369  double *costSaved_;
1373  double *djSaved_;
1375  double *lowerBasic_;
1377  double *upperBasic_;
1379  double *costBasic_;
1383  double *djBasic_;
1396 #ifdef EARLY_FACTORIZE
1397  AbcSimplexFactorization *abcEarlyFactorization_;
1399 #endif
1400 #ifdef TEMPORARY_FACTORIZATION
1401  AbcSimplexFactorization *abcOtherFactorization_;
1403 #endif
1404  //double * savedSolution_;
1416  /* has secondary offset and counts so row goes first then column
1417  Probably back to CoinPartitionedVector as AbcMatrix has slacks
1418  also says if in use - so we can just get next available one */
1419 #define ABC_NUMBER_USEFUL 8
1420  mutable CoinPartitionedVector usefulArray_[ABC_NUMBER_USEFUL];
1422  AbcSimplexProgress abcProgress_;
1426  double upperTheta_;
1429 
1430 public:
1434  int arrayForFlipRhs_; // if sequential can re-use
1435  int arrayForBtran_; // 0
1436  int arrayForFtran_; // 1
1438 protected:
1441  //int nextCleanNonBasicIteration_;
1442 #if ABC_PARALLEL == 1
1443  // For waking up thread
1444  pthread_mutex_t mutex_[3 * NUMBER_THREADS];
1445  pthread_barrier_t barrier_;
1446  CoinThreadInfo threadInfo_[NUMBER_THREADS];
1447  pthread_t abcThread_[NUMBER_THREADS];
1448  int locked_[NUMBER_THREADS];
1449  int stopStart_;
1450 #elif ABC_PARALLEL == 2
1451  //CoinThreadInfo threadInfo_[NUMBER_THREADS];
1452 #endif
1453 
1454 };
1455 //#############################################################################
1464 void AbcSimplexUnitTest(const std::string &mpsDir);
1465 #endif
1466 
1467 /* vi: softtabstop=2 shiftwidth=2 expandtab tabstop=2
1468 */
ClpSimplex
This solves LPs using the simplex method.
Definition: ClpSimplex.hpp:106
AbcSimplex::refreshCosts
void refreshCosts()
After modifying first copy refreshes second copy and marks as updated.
AbcSimplex::upperFake
@ upperFake
Definition: AbcSimplex.hpp:86
AbcSimplex::arrayForFlipBounds_
int arrayForFlipBounds_
Definition: AbcSimplex.hpp:1433
AbcSimplex::costBasic_
double * costBasic_
Working scaled copy of basic objective.
Definition: AbcSimplex.hpp:1379
AbcSimplex::solutionRegion
double * solutionRegion() const
Return region.
Definition: AbcSimplex.hpp:590
COLUMN_UPPER_SAME
#define COLUMN_UPPER_SAME
Definition: ClpModel.hpp:1343
AbcSimplex::startup
int startup(int ifValuesPass)
Common bits of coding for dual and primal.
ClpObjOffset
@ ClpObjOffset
Objective function constant.
Definition: ClpParameters.hpp:60
inverseRowUseScale_
#define inverseRowUseScale_
Definition: AbcSimplex.hpp:414
AbcSimplex::saveGoodStatus
void saveGoodStatus()
Saves good status etc.
AbcSimplex::usefulArray_
CoinPartitionedVector usefulArray_[ABC_NUMBER_USEFUL]
Definition: AbcSimplex.hpp:1420
AbcSimplex::valueIncomingDual
double valueIncomingDual() const
value of incoming variable (in Dual)
AbcSimplex::moveStatusFromClp
void moveStatusFromClp(ClpSimplex *clpModel)
Move status and solution from ClpSimplex.
ClpSimplex::firstFree_
int firstFree_
First free/super-basic variable (-1 if none)
Definition: ClpSimplex.hpp:1921
AbcSimplex::upperBasic_
double * upperBasic_
Working scaled copy of basic upper bounds.
Definition: AbcSimplex.hpp:1377
AbcSimplex::permuteBasis
void permuteBasis()
deals with new basis and puts in abcPivotVariable_
AbcSimplex::dualRowPivot
AbcDualRowPivot * dualRowPivot() const
dual row pivot choice
Definition: AbcSimplex.hpp:318
AbcSimplex::lastPivotRow
int lastPivotRow() const
Current/last pivot row (set after END of choosing pivot row in dual)
Definition: AbcSimplex.hpp:737
AbcSimplex::crash
void crash(int type)
Does sort of crash.
AbcSimplex::numberTotalWithoutFixed_
int numberTotalWithoutFixed_
Number of variables without fixed to zero (includes spare rows)
Definition: AbcSimplex.hpp:1236
ClpModel::getNumElements
CoinBigIndex getNumElements() const
Number of elements in matrix.
Definition: ClpModel.hpp:781
AbcSimplex::abcPivotVariable_
int * abcPivotVariable_
Basic variables pivoting on which rows followed by atLo/atUp then free/superbasic then fixed.
Definition: AbcSimplex.hpp:1391
AbcSimplex::rowScale2
double * rowScale2() const
corresponds to rowScale etc
Definition: AbcSimplex.hpp:498
AbcSimplex::usefulArray
CoinPartitionedVector * usefulArray(int index) const
Definition: AbcSimplex.hpp:245
AbcSimplex::setObjCoeff
void setObjCoeff(int elementIndex, double elementValue)
Set an objective function coefficient.
Definition: AbcSimplex.hpp:1064
ClpModel::columnUpper_
double * columnUpper_
Column Upper.
Definition: ClpModel.hpp:1279
AbcSimplex::upperRegion
double * upperRegion(int which) const
Definition: AbcSimplex.hpp:623
AbcSimplex::ordinaryVariables
int ordinaryVariables() const
Set to 1 if no free or super basic.
Definition: AbcSimplex.hpp:298
AbcSimplex::getEmptyFactorization
AbcSimplexFactorization * getEmptyFactorization()
Gets clean and emptyish factorization.
ClpSimplex::rowArray
CoinIndexedVector * rowArray(int index) const
Useful row length arrays (0,1,2,3,4,5)
Definition: ClpSimplex.hpp:815
AbcSimplex::solution
double solution(int sequence)
Return row or column values.
Definition: AbcSimplex.hpp:801
AbcSimplex::reducedCost
double reducedCost(int sequence)
Definition: AbcSimplex.hpp:810
AbcSimplex::swap
void swap(int pivotRow, int nonBasicPosition, Status newStatus)
Swaps two variables and does status.
AbcSimplex::checkBothSolutions
void checkBothSolutions()
This sets sum and number of infeasibilities (Dual and Primal)
AbcSimplex::abcNonLinearCost
AbcNonLinearCost * abcNonLinearCost() const
Return pointer to details of costs.
Definition: AbcSimplex.hpp:283
ClpModel::solveType
int solveType() const
Solve type - 1 simplex, 2 simplex interface, 3 Interior.
Definition: ClpModel.hpp:391
AbcSimplex::upperRegion
double * upperRegion() const
Definition: AbcSimplex.hpp:602
AbcSimplex::offset_
double * offset_
Primal offset (in external order) So internal value is (external-offset)*scaleFromExternal.
Definition: AbcSimplex.hpp:1325
AbcSimplex::columnUseScale_
double * columnUseScale_
use this instead of columnScale
Definition: AbcSimplex.hpp:1319
AbcSimplex::isColumn
int isColumn(int sequence) const
Returns 1 if sequence indicates column.
Definition: AbcSimplex.hpp:727
AbcSimplex::lastPivotRow_
int lastPivotRow_
Current/last pivot row (set after END of choosing pivot row in dual)
Definition: AbcSimplex.hpp:1303
AbcSimplex::solutionRegion
double * solutionRegion(int which) const
Return region.
Definition: AbcSimplex.hpp:611
AbcSimplex::getColSolution
const double * getColSolution() const
Get pointer to array[getNumCols()] of primal solution vector.
AbcSimplex::solutionAddress
double & solutionAddress(int sequence)
Return address of row or column values.
Definition: AbcSimplex.hpp:806
AbcSimplex::arrayForReplaceColumn_
int arrayForReplaceColumn_
Definition: AbcSimplex.hpp:1432
AbcSimplex::startOther_
int startOther_
Start of superBasic, free or awkward bounds variables.
Definition: AbcSimplex.hpp:1246
AbcSimplex::sequenceOut
int sequenceOut() const
Definition: AbcSimplex.hpp:697
AbcSimplex::permuteIn
void permuteIn()
Permutes in from ClpModel data - assumes scale factors done and AbcMatrix exists but is in original o...
AbcSimplex::firstFree
int firstFree() const
First Free_.
Definition: AbcSimplex.hpp:742
AbcSimplex::scaleToExternal
double * scaleToExternal() const
Scale from primal internal to external (in external order) Or other way for dual.
Definition: AbcSimplex.hpp:493
AbcSimplex::primalColumnPivot
AbcPrimalColumnPivot * primalColumnPivot() const
primal column pivot choice
Definition: AbcSimplex.hpp:323
AbcSimplex::clearPivoted
void clearPivoted(int sequence)
Definition: AbcSimplex.hpp:957
AbcSimplex::housekeeping
int housekeeping()
This does basis housekeeping and does values for in/out variables.
AbcSimplex::inverseColumnScale2
double * inverseColumnScale2() const
Definition: AbcSimplex.hpp:506
AbcSimplex::checkDualSolutionPlusFake
void checkDualSolutionPlusFake()
This sets largest infeasibility and most infeasible and sum and number of infeasibilities AND sumFake...
AbcSimplex::gutsOfInitialize
void gutsOfInitialize(int numberRows, int numberColumns, bool doMore)
Initializes arrays.
AbcSimplex::active
bool active(int iRow) const
Definition: AbcSimplex.hpp:990
ClpModel::columnLower_
double * columnLower_
Column Lower.
Definition: ClpModel.hpp:1277
AbcSimplex::putBackSolution
void putBackSolution(ClpSimplex *simplex)
Put back solution into ClpSimplex.
AbcSimplex::createStatus
void createStatus()
Set up status array (can be used by OsiAbc).
AbcSimplex::objectiveChange_
double objectiveChange_
Objective change.
Definition: AbcSimplex.hpp:1190
AbcSimplex::setColBounds
void setColBounds(int elementIndex, double newlower, double newupper)
Set a single column lower and upper bound.
Definition: AbcSimplex.hpp:1107
AbcSimplex::AbcSimplexUnitTest
friend void AbcSimplexUnitTest(const std::string &mpsDir)
A function that tests the methods in the AbcSimplex class.
AbcSimplex::acceptablePivot
double acceptablePivot() const
Acceptable pivot for this iteration.
Definition: AbcSimplex.hpp:293
AbcSimplex::internalStatus
unsigned char * internalStatus() const
Definition: AbcSimplex.hpp:662
AbcSimplex::lastFirstFree
int lastFirstFree() const
Last firstFree_.
Definition: AbcSimplex.hpp:747
AbcSimplex::numberFlagged_
int numberFlagged_
Current number of variables flagged.
Definition: AbcSimplex.hpp:1219
AbcSimplex::swapFactorization
AbcSimplexFactorization * swapFactorization(AbcSimplexFactorization *factorization)
Swaps factorization.
AbcSimplex::maximumNumberTotal_
int maximumNumberTotal_
Maximum numberTotal.
Definition: AbcSimplex.hpp:1217
AbcSimplex::cost
double cost(int sequence)
Definition: AbcSimplex.hpp:836
ClpDataSave
This is a tiny class where data can be saved round calls.
Definition: ClpModel.hpp:1402
AbcSimplex::abcCost_
double * abcCost_
Working scaled copy of objective ? where perturbed copy or can we always work with perturbed copy (in...
Definition: AbcSimplex.hpp:1357
AbcSimplex::swapPrimalStuff
void swapPrimalStuff()
Swaps primal stuff.
AbcSimplex::originalLower
double originalLower(int iSequence) const
Return original lower bound.
Definition: AbcSimplex.hpp:846
AbcSimplex::checkDjs
void checkDjs(int type=1) const
For debug - summarizes dj situation (1 recomputes duals first, 2 checks duals as well)
AbcSimplex::numberOrdinary_
int numberOrdinary_
Number of ordinary (lo/up) in tableau row.
Definition: AbcSimplex.hpp:1295
AbcSimplex::inverseRowScale2
double * inverseRowScale2() const
Definition: AbcSimplex.hpp:502
AbcSimplex::rawObjectiveValue
double rawObjectiveValue() const
Raw objective value (so always minimize in primal)
Definition: AbcSimplex.hpp:1017
AbcSimplex::btranAlpha_
double btranAlpha_
Btran alpha.
Definition: AbcSimplex.hpp:1192
AbcSimplex::atUpperBound
@ atUpperBound
Definition: AbcSimplex.hpp:76
AbcSimplex::arrayForReplaceColumn
int arrayForReplaceColumn() const
Definition: AbcSimplex.hpp:523
AbcSimplex::currentDualBound
double currentDualBound() const
Current dualBound (will end up as dualBound_)
Definition: AbcSimplex.hpp:313
AbcSimplex::lowerBasic
double * lowerBasic() const
Definition: AbcSimplex.hpp:640
AbcSimplex::setDualRowPivotAlgorithm
void setDualRowPivotAlgorithm(AbcDualRowPivot &choice)
Sets row pivot choice algorithm in dual.
AbcSimplex::tightenPrimalBounds
int tightenPrimalBounds()
Tightens primal bounds to make dual faster.
AbcSimplex::fakeSuperBasic
int fakeSuperBasic(int iSequence)
Returns 1 if fake superbasic 0 if free or true superbasic -1 if was fake but has cleaned itself up (s...
Definition: AbcSimplex.hpp:768
AbcSimplex::arrayForFlipRhs
int arrayForFlipRhs() const
Definition: AbcSimplex.hpp:531
AbcSimplex::lastDualError_
double lastDualError_
Last dual error.
Definition: AbcSimplex.hpp:1184
AbcSimplex::atLowerBound
@ atLowerBound
Definition: AbcSimplex.hpp:75
AbcSimplex::abcPerturbation
double * abcPerturbation() const
Perturbation.
Definition: AbcSimplex.hpp:653
AbcSimplex::abcSolution_
double * abcSolution_
Working scaled primal solution may have saved from last factorization at end.
Definition: AbcSimplex.hpp:1360
AbcSimplex::moveStatusToClp
void moveStatusToClp(ClpSimplex *clpModel)
Move status and solution to ClpSimplex.
AbcSimplex::unpack
void unpack(CoinIndexedVector &rowArray) const
Unpacks one column of the matrix into indexed array Uses sequenceIn_.
Definition: AbcSimplex.hpp:381
AbcSimplex::upperTheta_
double upperTheta_
upper theta from dual column
Definition: AbcSimplex.hpp:1426
AbcSimplex::setFactorizationFrequency
void setFactorizationFrequency(int value)
AbcSimplex::checkArrays
void checkArrays(int ignoreEmpty=0) const
For debug - prints summary of arrays which are out of kilter.
AbcNonLinearCost
Definition: AbcNonLinearCost.hpp:71
ClpMatrixBase.hpp
AbcSimplex::gutsOfDelete
void gutsOfDelete(int type)
Does most of deletion for arrays etc(0 just null arrays, 1 delete first)
AbcSimplex::reducedCostAddress
double & reducedCostAddress(int sequence)
Definition: AbcSimplex.hpp:814
AbcSimplex::setCurrentDualTolerance
void setCurrentDualTolerance(double value)
Definition: AbcSimplex.hpp:278
AbcSimplex::setToBaseModel
void setToBaseModel(AbcSimplex *model=NULL)
Reset to base model (just size and arrays needed) If model NULL use internal copy.
AbcSimplex::clearFlagged
void clearFlagged(int sequence)
Definition: AbcSimplex.hpp:971
AbcSimplex::makeBaseModel
void makeBaseModel()
Array persistence flag If 0 then as now (delete/new) 1 then only do arrays if bigger needed 2 as 1 bu...
AbcSimplex::costSaved_
double * costSaved_
Saved scaled copy of objective.
Definition: AbcSimplex.hpp:1369
AbcSimplex::isFixed
@ isFixed
Definition: AbcSimplex.hpp:80
AbcSimplex::arrayForBtran_
int arrayForBtran_
Definition: AbcSimplex.hpp:1435
AbcSimplex::abcNonLinearCost_
AbcNonLinearCost * abcNonLinearCost_
Very wasteful way of dealing with infeasibilities in primal.
Definition: AbcSimplex.hpp:1414
ClpModel.hpp
AbcSimplex::setFakeBound
void setFakeBound(int sequence, FakeBound fakeBound)
Definition: AbcSimplex.hpp:942
AbcSimplex::setAvailableArray
void setAvailableArray(int which) const
Say array going available.
Definition: AbcSimplex.hpp:924
AbcSimplex::lastDualBound_
double lastDualBound_
Last dual bound.
Definition: AbcSimplex.hpp:1178
AbcSimplex::internalStatusSaved_
unsigned char * internalStatusSaved_
Saved status.
Definition: AbcSimplex.hpp:1336
AbcSimplex::costBasic
double * costBasic() const
Definition: AbcSimplex.hpp:648
ROW_LOWER_SAME
#define ROW_LOWER_SAME
Definition: ClpModel.hpp:1339
AbcSimplex::lowerBasic_
double * lowerBasic_
Working scaled copy of basic lower bounds.
Definition: AbcSimplex.hpp:1375
ClpSimplex::bestPossibleImprovement_
double bestPossibleImprovement_
Best possible improvement using djs (primal) or obj change by flipping bounds to make dual feasible (...
Definition: ClpSimplex.hpp:1752
AbcSimplex::costRegion
double * costRegion(int which) const
Definition: AbcSimplex.hpp:627
AbcSimplex::setNumberOrdinary
void setNumberOrdinary(int number)
Set number of ordinary (lo/up) in tableau row.
Definition: AbcSimplex.hpp:308
AbcSimplex::lastCleaned_
int lastCleaned_
Last time cleaned up.
Definition: AbcSimplex.hpp:1301
AbcSimplex::bothFake
@ bothFake
Definition: AbcSimplex.hpp:87
AbcSimplex::refreshUpper
void refreshUpper(unsigned int type=~(ROW_LOWER_SAME|COLUMN_LOWER_SAME))
AbcSimplex::getAvailableArray
int getAvailableArray() const
Returns first available empty array (and sets flag)
ClpModel::optimizationDirection_
double optimizationDirection_
Direction of optimization (1 - minimize, -1 - maximize, 0 - ignore.
Definition: ClpModel.hpp:1245
AbcSimplex::checkPrimalSolution
void checkPrimalSolution(bool justBasic)
This sets largest infeasibility and most infeasible and sum and number of infeasibilities (Primal)
AbcSimplex::allSlackBasis
void allSlackBasis()
Sets up all slack basis and resets solution to as it was after initial load or readMps.
AbcSimplex::stateOfProblem_
int stateOfProblem_
Definition: AbcSimplex.hpp:1286
AbcSimplex::clearArraysPublic
void clearArraysPublic(int which)
Clears an array and says available (-1 does all) when no possibility of going parallel.
Definition: AbcSimplex.hpp:875
AbcSimplex::restoreGoodStatus
void restoreGoodStatus(int type)
Restores previous good status and says trouble.
AbcSimplex::getFakeBound
FakeBound getFakeBound(int sequence) const
Definition: AbcSimplex.hpp:948
AbcSimplex::solutionSaved_
double * solutionSaved_
Saved scaled primal solution.
Definition: AbcSimplex.hpp:1371
AbcSimplex::setColUpper
void setColUpper(int elementIndex, double elementValue)
Set a single column upper bound Use DBL_MAX for infinity.
Definition: AbcSimplex.hpp:1101
AbcSimplex::stateOfIteration_
int stateOfIteration_
Where we are in iteration.
Definition: AbcSimplex.hpp:1205
ClpSimplex::sequenceIn_
int sequenceIn_
Sequence of In variable.
Definition: ClpSimplex.hpp:1843
AbcSimplex::tempArray_
double * tempArray_
Useful array of numberTotal length.
Definition: AbcSimplex.hpp:1329
AbcSimplex::maximumNumberTotal
int maximumNumberTotal() const
Maximum Total.
Definition: AbcSimplex.hpp:220
AbcSimplex::lowerFake
@ lowerFake
Definition: AbcSimplex.hpp:85
AbcSimplex::arrayForDualColumn
int arrayForDualColumn() const
Definition: AbcSimplex.hpp:514
AbcSimplex::reversePivotVariable_
int * reversePivotVariable_
Reverse abcPivotVariable_ for moving around.
Definition: AbcSimplex.hpp:1393
AbcSimplex::ftAlpha_
double ftAlpha_
FT alpha.
Definition: AbcSimplex.hpp:1197
AbcSimplex::translate
void translate(int type)
Translates ClpModel to AbcSimplex See DO_ bits in stateOfProblem_ for type e.g.
AbcSimplex::saveData
ClpDataSave saveData()
Save data.
AbcSimplex::refreshLower
void refreshLower(unsigned int type=~(ROW_LOWER_SAME|COLUMN_UPPER_SAME))
AbcSimplex::isFree
@ isFree
Definition: AbcSimplex.hpp:77
AbcSimplex::maximumAbcNumberRows_
int maximumAbcNumberRows_
Maximum number rows.
Definition: AbcSimplex.hpp:1213
AbcSimplex::pivotVariable
int * pivotVariable() const
Basic variables pivoting on which rows may be same as toExternal but may be as at invert.
Definition: AbcSimplex.hpp:465
AbcSimplex::moveToBasic
void moveToBasic(int which=15)
Moves basic stuff to basic area.
AbcSimplex::upperBasic
double * upperBasic() const
Definition: AbcSimplex.hpp:644
AbcSimplex::isObjectiveLimitTestValid
bool isObjectiveLimitTestValid() const
Return true if the objective limit test can be relied upon.
AbcSimplex::fakeDjs
double * fakeDjs() const
Fake djs.
Definition: AbcSimplex.hpp:658
AbcCommon.hpp
ClpDisasterHandler
Base class for Clp disaster handling.
Definition: ClpEventHandler.hpp:138
AbcSimplex::resize
void resize(int newNumberRows, int newNumberColumns)
Resizes rim part of model.
AbcSimplexFactorization
This just implements AbcFactorization when an AbcMatrix object is passed.
Definition: AbcSimplexFactorization.hpp:26
AbcSimplex::arrayForFtran_
int arrayForFtran_
Definition: AbcSimplex.hpp:1436
AbcSimplex::setRowUpper
void setRowUpper(int elementIndex, double elementValue)
Set a single row upper bound Use DBL_MAX for infinity.
AbcSimplex::initialSumInfeasibilities_
double initialSumInfeasibilities_
Initial sum of infeasibilities.
Definition: AbcSimplex.hpp:1201
AbcSimplex::setRowLower
void setRowLower(int elementIndex, double elementValue)
Set a single row lower bound Use -DBL_MAX for -infinity.
AbcSimplex::numberFreeNonBasic_
int numberFreeNonBasic_
Number of free nonbasic variables.
Definition: AbcSimplex.hpp:1299
AbcSimplex::setColumnSetBounds
void setColumnSetBounds(const int *indexFirst, const int *indexLast, const double *boundList)
Set the bounds on a number of columns simultaneously The default implementation just invokes setColL...
AbcSimplex::startAtLowerOther_
int startAtLowerOther_
Start of variables at lower bound with upper.
Definition: AbcSimplex.hpp:1240
AbcSimplex::upperSaved_
double * upperSaved_
Saved scaled copy of upper bounds.
Definition: AbcSimplex.hpp:1367
AbcSimplex::~AbcSimplex
~AbcSimplex()
Destructor.
AbcSimplex::AbcSimplex
AbcSimplex(bool emptyMessages=false)
Default constructor.
AbcSimplex::getSolution
int getSolution()
Given an existing factorization computes and checks primal and dual solutions.
AbcSimplex::flagged
bool flagged(int sequence) const
Definition: AbcSimplex.hpp:975
AbcSimplex::computePrimals
int computePrimals(CoinIndexedVector *array1, CoinIndexedVector *array2)
Computes primals from scratch. Returns number of refinements.
AbcSimplex::abcPrimalColumnPivot_
AbcPrimalColumnPivot * abcPrimalColumnPivot_
primal column pivot choice
Definition: AbcSimplex.hpp:1387
AbcSimplex::costRegion
double * costRegion() const
Definition: AbcSimplex.hpp:606
AbcSimplex::setupPointers
void setupPointers(int maxRows, int maxColumns)
Sets up all extra pointers.
ClpModel::numberColumns_
int numberColumns_
Number of columns.
Definition: ClpModel.hpp:1259
AbcSimplex::abcBaseModel_
AbcSimplex * abcBaseModel_
Saved version of solution.
Definition: AbcSimplex.hpp:1407
AbcSimplex::lowerRegion
double * lowerRegion(int which) const
Definition: AbcSimplex.hpp:619
AbcSimplex::getRowPrice
const double * getRowPrice() const
Get pointer to array[getNumRows()] of dual prices.
AbcSimplex::upperAddress
double & upperAddress(int sequence)
Return address of row or column upper bound.
Definition: AbcSimplex.hpp:832
AbcSimplex::FakeBound
FakeBound
Definition: AbcSimplex.hpp:83
AbcSimplex::costAddress
double & costAddress(int sequence)
Return address of row or column cost.
Definition: AbcSimplex.hpp:841
AbcSimplex::lastFirstFree_
int lastFirstFree_
Last firstFree_.
Definition: AbcSimplex.hpp:1209
AbcSimplex::setColumnUpper
void setColumnUpper(int elementIndex, double elementValue)
Set a single column upper bound Use DBL_MAX for infinity.
AbcDualRowPivot
Dual Row Pivot Abstract Base Class.
Definition: AbcDualRowPivot.hpp:23
AbcSimplex::setFactorization
void setFactorization(AbcSimplexFactorization &factorization)
Passes in factorization.
AbcSimplex::checkMoveBack
void checkMoveBack(bool checkDuals)
For debug - moves solution back to external and computes stuff (always checks djs)
AbcSimplex::setUsedArray
void setUsedArray(int which) const
Say array going to be used.
Definition: AbcSimplex.hpp:917
AbcSimplex::abcMatrix
AbcMatrix * abcMatrix() const
Abc Matrix.
Definition: AbcSimplex.hpp:328
AbcSimplex::gutsOfPrimalSolution
int gutsOfPrimalSolution(int type)
Computes solutions - 1 do duals, 2 do primals, 3 both (returns number of refinements)
ClpSimplex.hpp
AbcSimplex::setSequenceOut
void setSequenceOut(int sequence)
Definition: AbcSimplex.hpp:706
ClpSimplex::acceptablePivot_
double acceptablePivot_
Acceptable pivot value just after factorization.
Definition: ClpSimplex.hpp:1814
AbcSimplex::setRowBounds
void setRowBounds(int elementIndex, double lower, double upper)
Set a single row lower and upper bound.
AbcSimplex::superBasic
@ superBasic
Definition: AbcSimplex.hpp:78
AbcSimplex::lowerRegion
double * lowerRegion() const
Definition: AbcSimplex.hpp:598
AbcSimplex::internalStatus_
unsigned char * internalStatus_
Working status ? may be signed ? link pi_ to an indexed array? may have saved from last factorization...
Definition: AbcSimplex.hpp:1334
AbcSimplex::freeSequenceIn
int freeSequenceIn() const
Free chosen vector.
Definition: AbcSimplex.hpp:752
AbcSimplex::rawObjectiveValue_
double rawObjectiveValue_
Sum of costs (raw objective value)
Definition: AbcSimplex.hpp:1163
AbcSimplex::computeObjective
void computeObjective()
Computes nonbasic cost and total cost.
AbcSimplex::abcProgress_
AbcSimplexProgress abcProgress_
For dealing with all issues of cycling etc.
Definition: AbcSimplex.hpp:1422
AbcSimplex::primal
int primal(int ifValuesPass)
Primal algorithm - see AbcSimplexPrimal.hpp for method.
AbcSimplex::permuteOut
void permuteOut(int whatsWanted)
Permutes out - bit settings same as stateOfProblem.
AbcSimplex::computeObjectiveValue
void computeObjectiveValue(bool useWorkingSolution=false)
Compute objective value from solution and put in objectiveValue_.
AbcSimplex::setObjectiveCoefficient
void setObjectiveCoefficient(int elementIndex, double elementValue)
Set an objective function coefficient.
ClpSimplex::primalTolerance_
double primalTolerance_
Current primal tolerance for algorithm.
Definition: ClpSimplex.hpp:1802
AbcSimplex::abcLower_
double * abcLower_
Working scaled copy of lower bounds has original scaled copy at end.
Definition: AbcSimplex.hpp:1348
AbcMatrix
Definition: AbcMatrix.hpp:22
AbcSimplex::deleteBaseModel
void deleteBaseModel()
Switch off base model.
ClpSimplex::cleanStatus
void cleanStatus()
Clean up status.
AbcSimplex::copyFromSaved
void copyFromSaved(int type=31)
Copies all saved versions to working versions and may do something for perturbation.
AbcSimplex::solutionBasic
double * solutionBasic() const
Return region.
Definition: AbcSimplex.hpp:632
ClpModel::objectiveValue_
double objectiveValue_
Objective value.
Definition: ClpModel.hpp:1249
AbcSimplex::sumNonBasicCosts_
double sumNonBasicCosts_
Sum of nonbasic costs.
Definition: AbcSimplex.hpp:1161
rowUseScale_
#define rowUseScale_
Definition: AbcSimplex.hpp:413
AbcSimplexUnitTest
void AbcSimplexUnitTest(const std::string &mpsDir)
A function that tests the methods in the AbcSimplex class.
AbcSimplex::factorizationFrequency
int factorizationFrequency() const
Factorization frequency.
AbcSimplex::arrayForFtran
int arrayForFtran() const
Definition: AbcSimplex.hpp:539
AbcSimplex::originalUpper
double originalUpper(int iSequence) const
Return original lower bound.
Definition: AbcSimplex.hpp:854
AbcSimplex::setPrimalColumnPivotAlgorithm
void setPrimalColumnPivotAlgorithm(AbcPrimalColumnPivot &choice)
Sets column pivot choice algorithm in primal.
AbcSimplex::noFake
@ noFake
Definition: AbcSimplex.hpp:84
AbcSimplex
Definition: AbcSimplex.hpp:62
ClpSolve.hpp
AbcSimplex::baseModel
AbcSimplex * baseModel() const
See if we have base model.
Definition: AbcSimplex.hpp:146
AbcSimplex::cleanFactorization
int cleanFactorization(int ifValuesPass)
Get a clean factorization - i.e.
AbcSimplex::factorization
AbcSimplexFactorization * factorization() const
factorization
Definition: AbcSimplex.hpp:200
AbcSimplex::abcMatrix_
AbcMatrix * abcMatrix_
Working matrix.
Definition: AbcSimplex.hpp:1345
AbcSimplex::upper
double upper(int sequence)
Definition: AbcSimplex.hpp:827
AbcSimplex::doAbcDual
int doAbcDual()
ClpSimplex::pivotRow
int pivotRow() const
Pivot Row for use by classes e.g. steepestedge.
Definition: ClpSimplex.hpp:1080
AbcSimplex::numberOrdinary
int numberOrdinary() const
Number of ordinary (lo/up) in tableau row.
Definition: AbcSimplex.hpp:303
AbcSimplex::getBasis
CoinWarmStartBasis * getBasis() const
Returns a basis (to be deleted by user)
AbcSimplex::startFixed_
int startFixed_
Start of fixed variables.
Definition: AbcSimplex.hpp:1248
AbcSimplex::setSequenceIn
void setSequenceIn(int sequence)
Set sequenceIn or Out.
Definition: AbcSimplex.hpp:702
AbcSimplex::setStateOfProblem
void setStateOfProblem(int value)
State of problem.
Definition: AbcSimplex.hpp:475
AbcSimplex::startAtUpperOther_
int startAtUpperOther_
Start of variables at upper bound with lower.
Definition: AbcSimplex.hpp:1244
AbcSimplex::fillPerturbation
void fillPerturbation(int start, int number)
fills in perturbationSaved_ from start with 0.5+random
AbcSimplex::pivoted
bool pivoted(int sequence) const
Definition: AbcSimplex.hpp:961
AbcSimplex::abcPerturbation_
double * abcPerturbation_
Perturbation (fixed) - is just scaled random numbers If perturbationFactor_<0 then virtual perturbati...
Definition: AbcSimplex.hpp:1339
AbcSimplex::originalModel
void originalModel(AbcSimplex *miniModel)
This copies back stuff from miniModel and then deletes miniModel.
AbcSimplex::setColumnBounds
void setColumnBounds(int elementIndex, double lower, double upper)
Set a single column lower and upper bound.
AbcSimplex::stateOfProblem
int stateOfProblem() const
State of problem.
Definition: AbcSimplex.hpp:470
AbcSimplex::setInternalStatus
void setInternalStatus(int sequence, AbcSimplex::Status newstatus)
Definition: AbcSimplex.hpp:674
AbcSimplex::solutionBasic_
double * solutionBasic_
Working scaled basic primal solution.
Definition: AbcSimplex.hpp:1381
AbcSimplex::scaleToExternal_
double * scaleToExternal_
Scale from primal internal to external (in external order) Or other way for dual.
Definition: AbcSimplex.hpp:1317
AbcSimplex::djBasic
double * djBasic() const
Definition: AbcSimplex.hpp:636
AbcSimplex::sumFakeInfeasibilities_
double sumFakeInfeasibilities_
Sum of infeasibilities when using fake perturbation tolerance.
Definition: AbcSimplex.hpp:1180
AbcSimplex::initialDenseFactorization
bool initialDenseFactorization() const
AbcSimplex::currentDualTolerance_
double currentDualTolerance_
Current dualTolerance (will end up as dualTolerance_)
Definition: AbcSimplex.hpp:1172
AbcSimplex::currentDualBound_
double currentDualBound_
Current dualBound (will end up as dualBound_)
Definition: AbcSimplex.hpp:1174
AbcSimplex::offsetRhs_
double * offsetRhs_
Offset for accumulated offsets*matrix.
Definition: AbcSimplex.hpp:1327
AbcSimplex::getInternalColumnStatus
AbcSimplex::Status getInternalColumnStatus(int sequence) const
Definition: AbcSimplex.hpp:670
AbcSimplex::getInternalStatus
AbcSimplex::Status getInternalStatus(int sequence) const
Definition: AbcSimplex.hpp:666
AbcSimplex::freeSequenceIn_
int freeSequenceIn_
Free chosen vector.
Definition: AbcSimplex.hpp:1211
AbcSimplex::numberFlipped_
int numberFlipped_
Definition: AbcSimplex.hpp:1439
AbcSimplex::arrayForDualColumn_
int arrayForDualColumn_
Definition: AbcSimplex.hpp:1431
AbcSimplex::operator=
AbcSimplex & operator=(const AbcSimplex &rhs)
Assignment operator. This copies the data.
AbcSimplex::djSaved_
double * djSaved_
Saved scaled dual solution.
Definition: AbcSimplex.hpp:1373
COLUMN_LOWER_SAME
#define COLUMN_LOWER_SAME
Definition: ClpModel.hpp:1342
AbcSimplex::checkDualSolution
void checkDualSolution()
This sets largest infeasibility and most infeasible and sum and number of infeasibilities (Dual)
ClpModel::rowLower_
double * rowLower_
Row lower.
Definition: ClpModel.hpp:1269
AbcSimplex::setColLower
void setColLower(int elementIndex, double elementValue)
Set a single column lower bound Use -DBL_MAX for -infinity.
Definition: AbcSimplex.hpp:1095
AbcSimplex::lower
double lower(int sequence)
Definition: AbcSimplex.hpp:818
AbcSimplex::setPivoted
void setPivoted(int sequence)
Definition: AbcSimplex.hpp:953
AbcSimplex::stateDualColumn_
int stateDualColumn_
State of dual waffle -2 - in initial large tolerance phase -1 - in medium tolerance phase n - in corr...
Definition: AbcSimplex.hpp:1227
AbcSimplex::swappedAlgorithm_
int swappedAlgorithm_
Nonzero (probably 10) if swapped algorithms.
Definition: AbcSimplex.hpp:1305
AbcSimplex::arrayForBtran
int arrayForBtran() const
Definition: AbcSimplex.hpp:535
AbcSimplex::columnScale2
double * columnScale2() const
Definition: AbcSimplex.hpp:510
AbcSimplex::scaleFromExternal_
double * scaleFromExternal_
Points from external to internal.
Definition: AbcSimplex.hpp:1314
ABC_NUMBER_USEFUL
#define ABC_NUMBER_USEFUL
Useful arrays (all of row+column+2 length)
Definition: AbcSimplex.hpp:1419
AbcSimplex::djBasic_
double * djBasic_
Working scaled basic dual solution (want it to be zero)
Definition: AbcSimplex.hpp:1383
AbcSimplex::printStuff
void printStuff() const
Print stuff.
AbcSimplex::setMultipleSequenceIn
void setMultipleSequenceIn(int sequenceIn[4])
set multiple sequence in
AbcSimplex::setInitialDenseFactorization
void setInitialDenseFactorization(bool onOff)
Normally the first factorization does sparse coding because the factorization could be singular.
AbcSimplex::setColumnLower
void setColumnLower(int elementIndex, double elementValue)
Set a single column lower bound Use -DBL_MAX for -infinity.
AbcSimplex::doAbcPrimal
int doAbcPrimal(int ifValuesPass)
AbcSimplex::objectiveOffset_
double objectiveOffset_
Objective offset (from offset_)
Definition: AbcSimplex.hpp:1165
AbcSimplex::clearActive
void clearActive(int iRow)
Definition: AbcSimplex.hpp:986
AbcSimplex::maximumTotal
int maximumTotal() const
Definition: AbcSimplex.hpp:224
AbcSimplex::minimizationObjectiveValue
double minimizationObjectiveValue() const
Gets objective value with all offsets but as for minimization.
Definition: AbcSimplex.hpp:269
AbcSimplex::putStuffInBasis
void putStuffInBasis(int type)
Puts more stuff in basis 1 bit set - do even if basis exists 2 bit set - don't bother staying triangu...
AbcSimplex::checkSolutionBasic
void checkSolutionBasic() const
For debug - checks solutionBasic.
AbcSimplex::computeDuals
int computeDuals(double *givenDjs, CoinIndexedVector *array1, CoinIndexedVector *array2)
Computes duals from scratch.
AbcSimplex::saveData_
ClpDataSave saveData_
For saving stuff at beginning.
Definition: AbcSimplex.hpp:1424
AbcSimplex::largestGap_
double largestGap_
Largest gap.
Definition: AbcSimplex.hpp:1176
AbcSimplex::getReducedCost
const double * getReducedCost() const
Get a pointer to array[getNumCols()] of reduced costs.
AbcSimplex::abcDualRowPivot_
AbcDualRowPivot * abcDualRowPivot_
dual row pivot choice
Definition: AbcSimplex.hpp:1385
AbcSimplex::getAvailableArrayPublic
int getAvailableArrayPublic() const
Returns first available empty array (and sets flag) when no possibility of going parallel.
Definition: AbcSimplex.hpp:881
AbcSimplex::atFakeBound
bool atFakeBound(int sequence) const
ClpModel::numberColumns
int numberColumns() const
Definition: ClpModel.hpp:332
AbcSimplex::clearArrays
void clearArrays(int which)
Clears an array and says available (-1 does all)
AbcSimplex::clpModel_
ClpSimplex * clpModel_
A copy of model as ClpSimplex with certain state.
Definition: AbcSimplex.hpp:1409
AbcSimplex::lowerAddress
double & lowerAddress(int sequence)
Return address of row or column lower bound.
Definition: AbcSimplex.hpp:823
AbcSimplex::basic
@ basic
Definition: AbcSimplex.hpp:79
AbcSimplex::currentAcceptablePivot
double currentAcceptablePivot() const
Acceptable pivot for this iteration.
Definition: AbcSimplex.hpp:757
AbcSimplex::arrayForFlipBounds
int arrayForFlipBounds() const
Definition: AbcSimplex.hpp:527
AbcSimplex::perturbationFactor_
double perturbationFactor_
Perturbation factor If <0.0 then virtual if 0.0 none if >0.0 use this as factor.
Definition: AbcSimplex.hpp:1170
AbcSimplex::lastPrimalError_
double lastPrimalError_
Last primal error.
Definition: AbcSimplex.hpp:1182
AbcSimplex::scaleFromExternal
double * scaleFromExternal() const
Points from external to internal.
Definition: AbcSimplex.hpp:487
ClpSimplex::sequenceOut_
int sequenceOut_
Sequence of Out variable.
Definition: ClpSimplex.hpp:1847
AbcSimplex::setupDualValuesPass
void setupDualValuesPass(const double *fakeDuals, const double *fakePrimals, int type)
Sets dual values pass djs using unscaled duals type 1 - values pass type 2 - just use as infeasibilit...
AbcSimplex::Status
Status
enums for status of various sorts.
Definition: AbcSimplex.hpp:74
AbcSimplex::clpObjectiveValue
double clpObjectiveValue() const
Objective value.
Definition: AbcSimplex.hpp:459
AbcSimplex::setColSetBounds
void setColSetBounds(const int *indexFirst, const int *indexLast, const double *boundList)
Set the bounds on a number of columns simultaneously
Definition: AbcSimplex.hpp:1119
AbcSimplex::setInternalColumnStatus
void setInternalColumnStatus(int sequence, AbcSimplex::Status newstatus)
Definition: AbcSimplex.hpp:680
CoinAbcCommon.hpp
AbcSimplex::djRegion
double * djRegion(int which) const
Definition: AbcSimplex.hpp:615
AbcSimplex::usefulArray
CoinPartitionedVector * usefulArray(int index)
Useful arrays (0,1,2,3,4,5,6,7)
Definition: AbcSimplex.hpp:241
AbcSimplex::restoreData
void restoreData(ClpDataSave saved)
Restore data.
AbcSimplex::abcFactorization_
AbcSimplexFactorization * abcFactorization_
factorization
Definition: AbcSimplex.hpp:1395
AbcSimplex::setFlagged
void setFlagged(int sequence)
To flag a variable.
AbcSimplex::setClpSimplexObjectiveValue
void setClpSimplexObjectiveValue()
Sets objectiveValue_ from rawObjectiveValue_.
AbcSimplex::minimumThetaMovement_
double minimumThetaMovement_
Minimum theta movement.
Definition: AbcSimplex.hpp:1199
AbcSimplex::startAtUpperNoOther_
int startAtUpperNoOther_
Start of variables at upper bound with no lower.
Definition: AbcSimplex.hpp:1242
AbcSimplex::upperTheta
double upperTheta() const
upper theta from dual column
Definition: AbcSimplex.hpp:519
AbcSimplex::sequenceIn
int sequenceIn() const
Return sequence In or Out.
Definition: AbcSimplex.hpp:693
AbcSimplex::arrayForTableauRow
int arrayForTableauRow() const
Definition: AbcSimplex.hpp:543
AbcSimplex::internalFactorize
int internalFactorize(int solveType)
Factorizes using current basis.
AbcSimplex::setRowSetBounds
void setRowSetBounds(const int *indexFirst, const int *indexLast, const double *boundList)
Set the bounds on a number of rows simultaneously
AbcSimplex::initialNumberInfeasibilities_
int initialNumberInfeasibilities_
Initial number of infeasibilities.
Definition: AbcSimplex.hpp:1307
AbcSimplex::checkConsistentPivots
void checkConsistentPivots() const
For debug - check pivotVariable consistent.
AbcSimplex::maximumAbcNumberColumns_
int maximumAbcNumberColumns_
Maximum number columns.
Definition: AbcSimplex.hpp:1215
AbcSimplex::abcProgress
AbcSimplexProgress * abcProgress()
For dealing with all issues of cycling etc.
Definition: AbcSimplex.hpp:862
AbcSimplex::ordinaryVariables_
int ordinaryVariables_
Set to 1 if no free or super basic.
Definition: AbcSimplex.hpp:1297
AbcSimplex::defaultFactorizationFrequency
void defaultFactorizationFrequency()
If user left factorization frequency then compute.
AbcSimplex::arrayForFlipRhs_
int arrayForFlipRhs_
Definition: AbcSimplex.hpp:1434
AbcTolerancesEtc
Definition: CoinAbcCommon.hpp:254
AbcSimplex::gutsOfSolution
int gutsOfSolution(int type)
Computes solutions - 1 do duals, 2 do primals, 3 both (returns number of refinements)
AbcSimplex::currentDualTolerance
double currentDualTolerance() const
Current dualTolerance (will end up as dualTolerance_)
Definition: AbcSimplex.hpp:274
AbcSimplex::gutsOfCopy
void gutsOfCopy(const AbcSimplex &rhs)
Does most of copying.
NUMBER_THREADS
#define NUMBER_THREADS
Definition: AbcSimplex.hpp:1028
AbcSimplex::numberTotalWithoutFixed
int numberTotalWithoutFixed() const
Number of variables without fixed to zero (includes spare rows)
Definition: AbcSimplex.hpp:236
AbcSimplex::dual
int dual()
Dual algorithm - see AbcSimplexDual.hpp for method.
AbcSimplex::djRegion
double * djRegion() const
Definition: AbcSimplex.hpp:594
AbcSimplex::setValuesPassAction
void setValuesPassAction(double incomingInfeasibility, double allowedInfeasibility)
For advanced use.
AbcSimplex::lowerSaved_
double * lowerSaved_
Saved scaled copy of lower bounds.
Definition: AbcSimplex.hpp:1365
AbcSimplex::computeInternalObjectiveValue
double computeInternalObjectiveValue()
Compute minimization objective value from internal solution without perturbation.
AbcSimplex::getRowActivity
const double * getRowActivity() const
Get pointer to array[getNumRows()] of row activity levels (constraint matrix times the solution vecto...
AbcSimplex::maximumAbcNumberRows
int maximumAbcNumberRows() const
Maximum rows.
Definition: AbcSimplex.hpp:215
AbcSimplex::gutsOfResize
void gutsOfResize(int numberRows, int numberColumns)
resizes arrays
ClpModel::numberRows
int numberRows() const
Number of rows.
Definition: ClpModel.hpp:319
AbcSimplex::numberTotal
int numberTotal() const
Number of variables (includes spare rows)
Definition: AbcSimplex.hpp:231
AbcSimplex::numberDisasters_
int numberDisasters_
Definition: AbcSimplex.hpp:1440
AbcSimplex::multipleSequenceIn_
int multipleSequenceIn_[4]
Multiple sequence in.
Definition: AbcSimplex.hpp:1428
ClpModel::rowUpper_
double * rowUpper_
Row upper.
Definition: ClpModel.hpp:1271
AbcSimplex::abcDj_
double * abcDj_
Working scaled dual solution may have saved from last factorization at end.
Definition: AbcSimplex.hpp:1363
AbcSimplex::swapDualStuff
void swapDualStuff(int lastSequenceOut, int lastDirectionOut)
Swaps dual stuff.
AbcSimplex::arrayForTableauRow_
int arrayForTableauRow_
Definition: AbcSimplex.hpp:1437
AbcSimplex::perturbationBasic_
double * perturbationBasic_
basic perturbation
Definition: AbcSimplex.hpp:1343
ClpModel::dropNames
void dropNames()
Drops names - makes lengthnames 0 and names empty.
ClpModel::dblParam_
double dblParam_[ClpLastDblParam]
Array of double parameters.
Definition: ClpModel.hpp:1247
AbcSimplex::moveInfo
void moveInfo(const AbcSimplex &rhs, bool justStatus=false)
Move status and solution across.
AbcSimplex::normalDualColumnIteration_
int normalDualColumnIteration_
Iteration at which to do relaxed dualColumn.
Definition: AbcSimplex.hpp:1221
AbcSimplex::setActive
void setActive(int iRow)
To say row active in primal pivot row choice.
Definition: AbcSimplex.hpp:982
AbcSimplex::perturbationSaved_
double * perturbationSaved_
saved perturbation
Definition: AbcSimplex.hpp:1341
AbcSimplex::sequenceWithin
int sequenceWithin(int sequence) const
Returns sequence number within section.
Definition: AbcSimplex.hpp:732
AbcSimplex::abcUpper_
double * abcUpper_
Working scaled copy of upper bounds has original scaled copy at end.
Definition: AbcSimplex.hpp:1351
AbcPrimalColumnPivot
Primal Column Pivot Abstract Base Class.
Definition: AbcPrimalColumnPivot.hpp:26
AbcSimplex::movement_
double movement_
Movement of variable.
Definition: AbcSimplex.hpp:1188
AbcSimplex::perturbationSaved
double * perturbationSaved() const
Perturbation (fixed) - is just scaled random numbers.
Definition: AbcSimplex.hpp:288
AbcSimplex::currentAcceptablePivot_
double currentAcceptablePivot_
Acceptable pivot for this iteration.
Definition: AbcSimplex.hpp:1186
AbcSimplex::numberTotal_
int numberTotal_
Number of variables (includes spare rows)
Definition: AbcSimplex.hpp:1234
AbcSimplex::inverseColumnUseScale_
double * inverseColumnUseScale_
use this instead of inverseColumnScale
Definition: AbcSimplex.hpp:1321