lemon/hao_orlin.h
changeset 607 9ad8d2122b50
parent 412 7030149efed2
child 559 c5fd2d996909
equal deleted inserted replaced
2:cefd4b8eccde 3:7af2f7b0dd96
     1 /* -*- mode: C++; indent-tabs-mode: nil; -*-
     1 /* -*- mode: C++; indent-tabs-mode: nil; -*-
     2  *
     2  *
     3  * This file is a part of LEMON, a generic C++ optimization library.
     3  * This file is a part of LEMON, a generic C++ optimization library.
     4  *
     4  *
     5  * Copyright (C) 2003-2008
     5  * Copyright (C) 2003-2009
     6  * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
     6  * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
     7  * (Egervary Research Group on Combinatorial Optimization, EGRES).
     7  * (Egervary Research Group on Combinatorial Optimization, EGRES).
     8  *
     8  *
     9  * Permission to use, modify and distribute this software is granted
     9  * Permission to use, modify and distribute this software is granted
    10  * provided that this copyright notice appears in all copies. For
    10  * provided that this copyright notice appears in all copies. For
   236         bool first_set = true;
   236         bool first_set = true;
   237 
   237 
   238         for (NodeIt t(_graph); t != INVALID; ++t) {
   238         for (NodeIt t(_graph); t != INVALID; ++t) {
   239           if (reached[t]) continue;
   239           if (reached[t]) continue;
   240           _sets.push_front(std::list<int>());
   240           _sets.push_front(std::list<int>());
   241           
   241 
   242           queue[qlast++] = t;
   242           queue[qlast++] = t;
   243           reached.set(t, true);
   243           reached.set(t, true);
   244 
   244 
   245           while (qfirst != qlast) {
   245           while (qfirst != qlast) {
   246             if (qsep == qfirst) {
   246             if (qsep == qfirst) {
   536         bool first_set = true;
   536         bool first_set = true;
   537 
   537 
   538         for (NodeIt t(_graph); t != INVALID; ++t) {
   538         for (NodeIt t(_graph); t != INVALID; ++t) {
   539           if (reached[t]) continue;
   539           if (reached[t]) continue;
   540           _sets.push_front(std::list<int>());
   540           _sets.push_front(std::list<int>());
   541           
   541 
   542           queue[qlast++] = t;
   542           queue[qlast++] = t;
   543           reached.set(t, true);
   543           reached.set(t, true);
   544 
   544 
   545           while (qfirst != qlast) {
   545           while (qfirst != qlast) {
   546             if (qsep == qfirst) {
   546             if (qsep == qfirst) {