Changeset 1288


Ignore:
Timestamp:
Oct 16, 2008 11:54:33 AM (11 years ago)
Author:
forrest
Message:

add isObjectiveLimitTestValid

Location:
trunk/Clp/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Clp/src/ClpSimplex.cpp

    r1287 r1288  
    1156011560  return small;
    1156111561}
     11562// Return true if the objective limit test can be relied upon
     11563bool
     11564ClpSimplex::isObjectiveLimitTestValid() const
     11565{
     11566  if (problemStatus_ == 0) {
     11567    return true;
     11568  } else if (problemStatus_ == 1) {
     11569    // ok if dual
     11570    return (algorithm_<0);
     11571  } else if (problemStatus_==2) {
     11572    // ok if primal
     11573    return (algorithm_>0);
     11574  } else {
     11575    return false;
     11576  }
     11577}
    1156211578// Create C++ lines to get to current state
    1156311579void
  • trunk/Clp/src/ClpSimplex.hpp

    r1287 r1288  
    540540  inline void setAlgorithm(int value)
    541541  {algorithm_=value; }
     542  /// Return true if the objective limit test can be relied upon
     543  bool isObjectiveLimitTestValid() const ;
    542544  /// Sum of dual infeasibilities
    543545  inline double sumDualInfeasibilities() const
Note: See TracChangeset for help on using the changeset viewer.