00001
00002
00003
00004 #ifndef CoinPresolveSubst_H
00005 #define CoinPresolveSubst_H
00006 #define SUBST_ROW 21
00007
00008 #include "CoinPresolveMatrix.hpp"
00009
00010 class subst_constraint_action : public CoinPresolveAction {
00011 private:
00012 subst_constraint_action();
00013 subst_constraint_action(const subst_constraint_action& rhs);
00014 subst_constraint_action& operator=(const subst_constraint_action& rhs);
00015
00016 struct action {
00017 double *rlos;
00018 double *rups;
00019
00020 double *coeffxs;
00021 int *rows;
00022
00023 int *ninrowxs;
00024 int *rowcolsxs;
00025 double *rowelsxs;
00026
00027 const double *costsx;
00028 int col;
00029 int rowy;
00030
00031 int nincol;
00032 };
00033
00034 const int nactions_;
00035
00036 const action *const actions_;
00037
00038 subst_constraint_action(int nactions,
00039 action *actions,
00040 const CoinPresolveAction *next) :
00041 CoinPresolveAction(next),
00042 nactions_(nactions), actions_(actions) {}
00043
00044 public:
00045 const char *name() const;
00046
00047 static const CoinPresolveAction *presolve(CoinPresolveMatrix * prob,
00048 int *implied_free,
00049 const CoinPresolveAction *next,
00050 int & fill_level);
00051 static const CoinPresolveAction *presolveX(CoinPresolveMatrix * prob,
00052 const CoinPresolveAction *next,
00053 int fillLevel);
00054
00055 void postsolve(CoinPostsolveMatrix *prob) const;
00056
00057 ~subst_constraint_action();
00058 };
00059
00060
00061
00062
00063
00064 void implied_bounds(const double *els,
00065 const double *clo, const double *cup,
00066 const int *hcol,
00067 CoinBigIndex krs, CoinBigIndex kre,
00068 double *maxupp, double *maxdownp,
00069 int jcol,
00070 double rlo, double rup,
00071 double *iclb, double *icub);
00072 #endif