|
Go to the documentation of this file. 69 themax = (x > themax) ? x : themax; 70 x = (up[i] - vec[i] + delta) / x; 74 else if (x < -epsilon) 76 themax = (-x > themax) ? -x : themax; 77 x = (low[i] - vec[i] - delta) / x; 78 if (x < theval && low[i] > - infinity) 120 themax = (x > themax) ? x : themax; 121 x = (low[i] - vec[i] - delta) / x; 122 if (x > theval && low[i] > - infinity) 125 else if (x < -epsilon) 127 themax = (-x > themax) ? -x : themax; 128 x = (up[i] - vec[i] + delta) / x; 169 assert( delta > epsilon); 171 assert( solver()->maxCycle() > 0); 199 useeps = maxabs * epsilon * 0.001; 200 if (useeps < epsilon) 202 for (j = upd. size() - 1; j >= 0; --j) 214 if (y <= max && y > sel - epsilon && x > stab) 222 else if (x < -useeps) 230 if (y <= max && y > sel - epsilon && -x > stab) 244 else if (max < -epsilon) 264 useeps = maxabs * epsilon * 0.001; 265 if (useeps < epsilon) 267 for (j = upd. size() - 1; j >= 0; --j) 279 if (y >= max && y < sel + epsilon && -x > stab) 295 if (y >= max && y < sel + epsilon && x > stab) 312 if (lastshift != solver()->shift()) 336 Real minStability = 0.0001; 351 assert( delta > epsilon); 353 assert( solver()->maxCycle() > 0); 367 assert( delta > epsilon); 399 ruseeps = rmaxabs * 0.001 * epsilon; 400 if (ruseeps < epsilon) 402 cuseeps = cmaxabs * 0.001 * epsilon; 403 if (cuseeps < epsilon) 405 for (j = pupd. size() - 1; j >= 0; --j) 411 y = upb[i] - pvec[i]; 417 if (y <= max && x >= stab) 426 else if (x < -ruseeps) 428 y = lpb[i] - pvec[i]; 434 if (y <= max && -x >= stab) 445 MSG_DEBUG( std::cout << "DHARRI01 removing value " << pupd[i] << std::endl; ) 449 for (j = cupd. size() - 1; j >= 0; --j) 455 y = ucb[i] - cvec[i]; 461 if (y <= max && x >= stab) 470 else if (x < -cuseeps) 472 y = lcb[i] - cvec[i]; 478 if (y <= max && -x >= stab) 489 MSG_DEBUG( std::cout << "DHARRI02 removing value " << cupd[i] << std::endl; ) 494 if (lastshift == solver()->shift()) 498 if ( solver()->isBasic(enterId)) 509 if ( solver()->isBasic(enterId)) 519 sel = upb[pnr] - pvec[pnr]; 520 if (x < minStability && sel < delta) 529 sel = lpb[pnr] - pvec[pnr]; 530 if (-x < minStability && -sel < delta) 553 else if (val < -epsilon) 562 assert( delta > epsilon); 597 ruseeps = rmaxabs * epsilon * 0.001; 598 cuseeps = cmaxabs * epsilon * 0.001; 599 for (j = pupd. size() - 1; j >= 0; --j) 605 y = lpb[i] - pvec[i]; 611 if (y >= max && x > stab) 620 else if (x < -ruseeps) 622 y = upb[i] - pvec[i]; 628 if (y >= max && -x > stab) 639 MSG_DEBUG( std::cout << "DHARRI03 removing value " << pupd[i] << std::endl; ) 643 for (j = cupd. size() - 1; j >= 0; --j) 649 y = lcb[i] - cvec[i]; 655 if (y >= max && x > stab) 664 else if (x < -cuseeps) 666 y = ucb[i] - cvec[i]; 672 if (y >= max && -x > stab) 683 MSG_DEBUG( std::cout << "DHARRI04 removing value " << x << std::endl; ); 688 if (lastshift == solver()->shift()) 692 if ( solver()->isBasic(enterId)) 703 if ( solver()->isBasic(enterId)) 713 sel = lpb[pnr] - pvec[pnr]; 714 if (x < minStability && -sel < delta) 723 sel = upb[pnr] - pvec[pnr]; 724 if (-x < minStability && sel < delta) 746 assert(max * val >= 0); const R * values() const Returns array values.
int maxDelta(Real *, Real *val, int num, const int *idx, const Real *upd, const Real *vec, const Real *low, const Real *up, Real epsilon) const
Real delta allowed bound violation
const Vector & lbBound() const lower bound for fVec.
void inValidate() makes the id invalid.
void setValue(int i, R x) Sets i 'th element to x.
const R * get_const_ptr() const Conversion to C-style pointer.
UpdateVector & fVec() const feasibility vector.
void shiftLBbound(int i, Real to) shift i 'th lbBound to to.
UpdateVector & pVec() const pricing vector.
const Vector & ubBound() const upper bound for fVec.
SPxId coId(int i) const id of i 'th covector.
virtual Real shift() const total current shift amount.
Real delta() const guaranteed primal and dual bound violation for optimal solution, returning the maximum of feastol() a...
Type type() const returns the type of the id.
Real degenerateEps() const
Generic Ids for LP rows or columns.Both SPxColIds and SPxRowIds may be treated uniformly as SPxIds: ...
UpdateVector & coPvec() const copricing vector.
int index(int n) const Returns index of the n 'th nonzero element.
void shiftLPbound(int i, Real to) shift i 'th lpBound to to.
void clearNum(int n) Sets n 'th nonzero element to 0 (index n must exist).
virtual SPxId selectEnter(Real &val, int)
void shiftUCbound(int i, Real to) shift i 'th ucBound to to.
const Vector & lcBound() const
void shiftUBbound(int i, Real to) shift i 'th ubBound to to.
const Vector & upBound() const
Debugging, floating point type and parameter definitions.
Everything should be within this namespace.
void shiftUPbound(int i, Real to) shift i 'th upBound to to.
Harris pricing with shifting.
void shiftLCbound(int i, Real to) shift i 'th lcBound to to.
const SVector & vector(int i) const i 'th vector.
void setup() Initializes nonzero indices for elements with absolute values above epsilon and sets all other elemen...
int maxCycle() const maximum number of degenerate simplex steps before we detect cycling.
SPxId id(int i) const id of i 'th vector.
const Vector & lpBound() const
Real epsilon() const values are considered to be 0.
const int * indexMem() const Returns array indices.
SSVector & delta() update vector , writeable
const Vector & ucBound() const
int numCycle() const actual number of degenerate simplex steps encountered so far.
int size() const Returns the number of nonzeros.
virtual SPxSolver * solver() const returns loaded LP solver.
int minDelta(Real *, Real *val, int num, const int *idx, const Real *upd, const Real *vec, const Real *low, const Real *up, Real epsilon) const
virtual int selectLeave(Real &val, Real)
|