Exemple #1
0
bool SPxWeightPR::isConsistent() const
{
#ifdef ENABLE_CONSISTENCY_CHECKS
   if (solver() != 0)
   {
      if (rPenalty.dim() != solver()->nRows())
         return MSGinconsistent("SPxWeightPR");
      if (cPenalty.dim() != solver()->nCols())
         return MSGinconsistent("SPxWeightPR");
   }
#endif

   return true;
}
Exemple #2
0
bool UnitVector::isConsistent() const
{
#ifdef ENABLE_CONSISTENCY_CHECKS
   if (mem() != themem)
      return MSGinconsistent("UnitVector");
   if (mem() + 1 != &themem[1])
      return MSGinconsistent("UnitVector");
   if (size() != 1)
      return MSGinconsistent("UnitVector");
   if (max() != 1)
      return MSGinconsistent("UnitVector");

   return SVector::isConsistent();
#else
   return true;
#endif
}
Exemple #3
0
bool Vector::isConsistent() const
{
#ifdef ENABLE_CONSISTENCY_CHECKS
   if (dim() > 0 && val == 0)
      return MSGinconsistent("Vector");
#endif

   return true;
}
bool DSVector::isConsistent() const
{
#ifdef ENABLE_CONSISTENCY_CHECKS
   if ((theelem != 0) && (mem() != theelem))
      return MSGinconsistent("DSVector");
#endif

   return true;
}
bool DVector_exact::isConsistent() const
{
#ifdef ENABLE_CONSISTENCY_CHECKS
   if( val != mem || dimen > memsize || dimen < 0 )
      return MSGinconsistent("DVector_exact");

   return Vector_exact::isConsistent();
#else
   return true;
#endif
}
bool UpdateVector::isConsistent() const
{
#ifdef ENABLE_CONSISTENCY_CHECKS
   if (dim() != thedelta.dim())
      return MSGinconsistent("UpdateVector");

   return DVector::isConsistent() && thedelta.isConsistent();
#else
   return true;
#endif
}
Exemple #7
0
bool SPxDevexPR::isConsistent() const
{
#ifdef ENABLE_CONSISTENCY_CHECKS
   if (thesolver != 0)
      if (weights.dim() != thesolver->coDim()
           || coWeights.dim() != thesolver->dim())
         return MSGinconsistent("SPxDevexPR");
#endif

   return true;
}
Exemple #8
0
bool SVSet::isConsistent() const
{
#ifdef ENABLE_CONSISTENCY_CHECKS
   DLPSV* ps;
   DLPSV* next;
   for (ps = list.first(); ps; ps = next)
   {
      if (!ps->isConsistent())
         return MSGinconsistent("SVSet");
      if (ps->mem() > &last())
         return MSGinconsistent("SVSet");
      next = list.next(ps);
      if (next && ps->mem() + ps->max() + 1 != next->mem()) {
         return MSGinconsistent("SVSet");
      }
   }
   return DataArray < SVector::Element > ::isConsistent() 
      && set.isConsistent() && list.isConsistent();
#else
   return true;
#endif
}