Changeset 2084


Ignore:
Timestamp:
Sep 28, 2014 6:32:07 AM (5 years ago)
Author:
forrest
Message:

modify is.. meanings

File:
1 edited

Legend:

Unmodified
Added
Removed
  • stable/2.8/Cbc/src/OsiCbc/OsiCbcSolverInterface.cpp

    r2075 r2084  
    122122bool OsiCbcSolverInterface::isAbandoned() const
    123123{
    124   return modelPtr_->solver()->isAbandoned();
     124  if (modelPtr_->status()!=-1)
     125    return modelPtr_->isAbandoned();
     126  else
     127    return modelPtr_->solver()->isAbandoned();
    125128}
    126129
    127130bool OsiCbcSolverInterface::isProvenOptimal() const
    128131{
    129   if (modelPtr_->status()==0)
     132  if (modelPtr_->status()!=-1)
    130133    return modelPtr_->isProvenOptimal();
    131134  else
     
    135138bool OsiCbcSolverInterface::isProvenPrimalInfeasible() const
    136139{
    137   if (modelPtr_->status()==0)
     140  if (modelPtr_->status()!=-1)
    138141    return modelPtr_->isProvenInfeasible();
    139142  else
     
    143146bool OsiCbcSolverInterface::isProvenDualInfeasible() const
    144147{
     148  if (modelPtr_->status()!=-1)
     149  return modelPtr_->isProvenDualInfeasible();
     150  else
    145151  return modelPtr_->solver()->isProvenDualInfeasible();
    146152}
     
    157163bool OsiCbcSolverInterface::isIterationLimitReached() const
    158164{
    159   return modelPtr_->solver()->isIterationLimitReached();
     165  if (modelPtr_->status()!=-1)
     166    return modelPtr_->isNodeLimitReached();
     167  else
     168    return modelPtr_->solver()->isIterationLimitReached();
    160169}
    161170
Note: See TracChangeset for help on using the changeset viewer.