graph

How to load my data into a GraphML file for easy use in Prefuse?

Hi everyone, I'm trying to generate some graphs with prefuse, and it seems like the easiest way to load the data into prefuse is to use a GraphML file. Is there an easy way to write these files from my data? Or is there an easier way to load my data into prefuse? Thanks ...

What's a good way to select a random set of twitterers?

Considering the set of Twitter users "nodes" and the relation u follows v as the "edges", we have a graph from which I would like to select a subset of the users at random. I could be wrong, but from reading the API docs I think it's impossible to get a collection of users except by getting the followers or friends of an already-known us...

suggestions for a 3D graph rendering library?

Hello coders! So I'm not sure how stackoverflow friendly this question is since it doesn't have a quick clear cut answer but here we go... I have a java program that generates data for a directed graph. Now I need to render this graph. The data needs to be laid out in 3D, and I want to be able to define which plane an edge lives in. (...

What is better adjacency lists or adjacency matrix for graph problems in c++?

What is better adjacency lists or adjacency matrix for graph problems in c++? And what are the advantages and disadvantages of each? EDIT:can anyone provide a link with a clean code for say Breadth first search in linked lists format ?? ...

Longest path approximation algorithm from a given node

Hi guys! I'm looking for an approximation algorithm for the following problem - I have an unweighted, undirected graph, with cycles, and want to find the longest path starting from a given node. I do value speed over performance (so a O(n^5) algorithm would probably be an overkill). This is not homework (I swear!) or work related, but ...

Mathematica + GraphPlot + GraphicsGrid with EdgeLabels

I had some very strange problems with GraphicsGrid. The individual PraphPlot:s looks nice and ok, but the code GraphicsGrid[{{GraphPlot[{{a -> b, "ab"}, {a -> c, "7"}}]}, {GraphPlot[{{a -> b, "5"}, {a -> c, "2"}}]}}] just produces 2 big clots of garbage. If I remove the edge labels, everything works as expected. I am using Mathema...

Find Boost BGL vertex by a key

Hi, I am looking for a way to access vertex properties by using a key instead of vertex reference itself. For example, if I have class Data { public: std::string name; unsigned int value; }; typedef boost::adjacency_list< boost::vecS, boost::vecS, boost::directedS, Data > Graph; typedef boost::graph_traits<Graph>::vertex_d...

How can I use templated typedefs, that are _in_ a class, from outside the class (e.g. by another class), in relation to boost::graph

Hi, I found a very useful answer on how to create templated graphs using boost::graph under http://stackoverflow.com/questions/671714/modifying-vertex-properties-in-a-boostgraph/950173#950173 For me, this is very convenient as long as I do all the work on the graph in the Graph-class itself. However, it might be necessary to access in...

How to create graphs in Delphi application

I need to create graphs on the fly about specific process, with some informative texts and colors. In the Unix world there's Graphviz including 'dot' for layout generation, is there something similar which could be used with Delphi? I'm using Delphi 2007. Also Python alternative could be considered, but I'd prefer pure Delphi in this ...

Connecting arcs between lines in Dot (GraphViz)

I've got to do up a state space graph for my AI course, and I was hoping to use GraphViz to make it (so much faster than Dia). The one thing I can't seem to figure out how to do is how to do an "And" connection, which is basically an arc between two lines connecting to the same node. Is this possible? ...

breadth-first-search on huge graph with little ram

I currently have a graph that has about 10 million nodes and 35 million edges. For now the complete graph is loaded into memory at program start. This takes a couple of minutes (it is Java after all) and needs about half a gigabyte of RAM. For now it runs on a machine with a dual core processor and 4 gigabytes of RAM. When the graph is ...

Plotting Library for OpenGL

I need to draw a scientific graph (for example, a line or bar graph) and then render it in my application, which uses OpenGL for all display-related purposes. What is the best way to do this? Does anyone know of a plotting library for OpenGL? I haven't been able to find one, and the best thing I've come up with so far is to use LibGD...

Algorithm for finding all cycles in a directed graph on C++ using Adjacency matrix

Given graph adjacency matrix (for ex. g[][]), graph is directed. Needs find count of all graph cycles (if exists) and print them. I tried to wrote this algorithm in Java, sometimes it works correctly. If graph has complex cycles, algorithm return crazy cycles. Please, look at my code and help to resolve this problem public static final...

Library to render Directed Graphs (similar to graphviz) on Google App Engine

I am looking for a Java or Python library that can render graphs in the Dot language as image file. The problem is that I need a library that I can use on Google App Engine. Basically I am looking for a library that can convert the text description of a directed graph into an image of the graph. For example: Covert this edge list: [A...

Good Scatter-plot plugin for JQuery (sample pic included)?

Hi all, I'm looking for a solid graphing plugin for JQuery that can give me an attractive scatterplot for use on my site. I really don't need a lot of fancy functionality -- just the ability to plot points on a graph based on the X-axis and Y-axis values I give it. The only somewhat peculiar requirement I have is that the dots have the...

Random maps/graphs and OSM

Hi all, just wondering if you have any suggestions here. I need a lot of sample maps/graphs to test my shortest path search solution (I was told I should have >100 of them). My code is supposed to work in a simulator, which uses OpenStreetMap maps of urban setting, limiting the total number of junctions to a few thousand. the problem is...

calculate array element persistence algorithm

I have a large array 15x15x2200. THis is merely a collection of 15x15 sparse matrices depicting the links between 15 nodes and how they vary over 2200 time units. I need to calculate for how much time does each link persist. By this I mean, suppose A[4,11] is 0 till time unit 5 and stays 1 till time unit 20 and then becomes 0 and again b...

a graph,chart component for classic ASP

Can anyone recommend a graph,chart component for classic ASP. Free or not free is fine ...

Plotting axes with different scales for one data set in R

I have a large data set I am plotting in R, and I'd like to have an axis on each side of the graph show the data in two different scales. So for example, on the left vertical axis I'd like to plot the data directly (e.g. plot(y ~ x) ) and on the right axis, I'd like to have a linear scaling of the left axis. (e.g. plot( y*20 ~ x). So t...

how to use cewolf in web application to obtain graphical o/p?

hi all, I need a output as graph in web application,like getting graph o/p after executing a query.Heard about cewolf,will it suit for my application?if yes could u tel me how to use it or if there any other tools u suggest.I am totally confused,can anyone help me out? ...