COIN-OR::LEMON - Graph Library

Custom Query (511 matches)

Filters
 
Or
 
  
 
Columns

Show under each result:


Results (97 - 99 of 511)

Ticket Resolution Summary Owner Reporter
#390 done Different compilation flags using CMAKE vs. Autotools Akos Ladanyi Alpar Juttner
Description
  • Autotool uses -g -O2 + a huge set of warning flags by default.
  • Using scripts/bootstrap.sh, we have a choice to optimize or not (-O2 vs. nothing). This script uses -ggdb instead of -g (not a big diffenerce) and the same warning options.
  • The CMAKE environment uses
    • no warning flags at all!!!
    • one of the following debug/optimization settings
      • -g (DEBUG mode),
      • -Os -DNDEBUG (MINRELSIZE mode),
      • -O2 -g (RELWITHDEBINFO mode), or
      • -O3 -DNDEBUG (RELEASE mode)
#623 fixed Different ids assigned to the same edge in an undirected graph Alpar Juttner Francesco Carrabs
Description

Dear LEMON developers, I would like to report a problem regarding multiple ids associated with the same edge in an undirected graph. Let us consider the following code in which I define a complete undirected graph with 3 nodes:

#include <iostream>
#include <lemon/list_graph.h>

using lemon::INVALID;
using namespace std;

int main() {

    lemon::ListGraph g;
    for(int i=0;i<3;i++){
        g.addNode();
    }
    for(int i=0;i<3;i++){
        for(int j=0;j<3;j++){
            if(i<j)
                g.addEdge(g.nodeFromId(i),g.nodeFromId(j));
        }
    }

    cout<<"Edge of the graph: "<<endl;
    for(lemon::ListGraph::EdgeIt e(g); e!=INVALID;++e){
        cout<<"Edge {"<<g.id(g.u(e))<<","<<g.id(g.v(e))<<"}: id= "<<g.id(e) << endl;
    }

    cout<<"IncEdge of the graph: "<<endl;
    for(lemon::ListGraph::NodeIt i(g); i!=INVALID; ++i){
        for(lemon::ListGraph::IncEdgeIt e(g, i); e != INVALID; ++e)
            cout<<"Edge {"<<g.id(g.baseNode(e))<<","<<g.id(g.runningNode(e))<<"}: id= "<<g.id(e)<<endl;
    }
}

Notice that I ask to print the id in two different ways: by iterating on all the edges of the graph and by iterating on the nodes of the graph and, for each node, by considering its incident edges. The output of the previous code is:

Edge of the graph: Edge {1,2}: id= 2 Edge {0,2}: id= 1 Edge {0,1}: id= 0

IncEdge? of the graph: Edge {2,1}: id= 4 Edge {2,0}: id= 2 Edge {1,2}: id= 5 Edge {1,0}: id= 0 Edge {0,2}: id= 3 Edge {0,1}: id= 1

You can notice that to the edge {0,1} are assigned the id 0 (loop on the edges) and 1 (loop on the incident edges).

#187 fixed DijkstraWidestPathOperationTraits Balazs Dezso Peter Kovacs
Description

Do we really need this class in dijkstra.h? Or it should rather be an example in the tutorial?

Btw. I think there is a bug in it, namely < should be > in the less() function. Am I right?

Note: See TracQuery for help on using queries.