graph

Perform connected_components with Boost adjacency_list where VertexList=listS

I use Boost Graph Library in a project and it is declared as: typedef adjacency_list <listS, listS, undirectedS, TrackInformation, LinkInformation> TracksConnectionGraph; Things are going fine until I have to call connected_components on my graph. typedef std::map<TracksConnectionGraph::vertex_descriptor, TracksConnectionGraph::vert...

Quickgraph / Graphsharp nodes layout from left to right

Hello, I am using quickgraph/graphsharp library and try to get such a layout in which i could have all nodes aligned left to right with no overlapping... how it would be possible. Thanks, http://quickgraph.codeplex.com http://graphsharp.codeplex.com (graphsharp based on quickgraph) ...

How to implement a static graph in C

Hello, I need to store a graph for the map of a game inside a game server written in C. The graph has ~200 nodes and 3 kinds of edges that can connect two nodes (these three kind can also overlap: a node can be connected by 2 edges of two different types for example). The maximum degree of a node is something like 5-6 nodes. What I wou...

Create a Graph from points in a Grid that contains holes

I've got a continuous plane (2-D) containing polygonal obstacles. I am uniformly sampling the plane at discrete positions to create a uniform grid of points. The grid does not have points where obstacles lie (i.e. holes where ever an obstacle is) as shown in the image below. (Please view the image at http://i48.tinypic.com/2efnblg.png f...

Graph Hamiltonian Path with DNA Computing

I recently found a "DNA Computing" Algorithm (not genetic programming or genetic algorithms) that attempts to find the Hamiltonian Path in a graph, but I'm a little confused by the pseudo code... note that the notation is a little messed up because I copied it from a PDF paper on DNA computing: Input: for each node v and edge (u; v), ...

finding the longest road in a Settlers of Catan game algorithmically

I'm writing a Settlers of Catan clone for a class. One of the extra credit features is automatically determining which player has the longest road. I've thought about it, and it seems like some slight variation on depth-first search could work, but I'm having trouble figuring out what to do with cycle detection, how to handle the joining...

Fusion Chart Free Time Line graph

I need a graph exactly like the above figure using Multi-series line graph with time gap of one hour from 9am till 11pm for a singe day. Please help me. ...

3D Graph plotting for C++

Hi, I need to plot my simulation (which I do in a C++ application) for use in a Latex document (so I would prefer some vector output like EPS). My function is of 2 arguments, so I am after a 3D plot, ideally with colouring indicating the function value (similar to what Mathematica does). Could anyone recommend any library? ...

How to get a facebook profile picture under https?

Is it possible to get an facebook profile picture under https using the new Graph API? We run a site under https, but the profile picture returned by the facebook Graph API is always served as http (when using https://graph.facebook.com/XXX/picture, the request is redirects to http://...). The result is the dreaded mixed-content messag...

Algorithms for Directed Cyclic Graph Traversal (JavaScript)

I have a connected, directed, cyclic graph. The task is to discover every single node in the graph without falling into an infinite loop, as a regular tree traversal algorithm will do. You can assume that I already know what node to start at so as to reach all points in the directed graph, and that for each node I have a function that w...

[R] putting text on the X Axis of Graphs

I need to plot a graph where the X values are all names -e.g. states of America and the Y values are numberic and in descending order- e.g. population of the states of America. Currently, when I use the plot function, it plots a graph but a) The Y values are not in descending order and b) the X Axis displays a bunch of ascending number...

Line Chart Report with 2 Different Scales?

I have a line chart with two lines in it. Sometimes the values between them differ by a hundred or more. That leaves the bottom line looking very flat. I want both of these to remain on the same graph but is there a way to have a different scale for each line? I was told that it is possible to have one (scale) on the left and one on ...

How would I visualize the amount of time that's passed between dates?

If I had a product and wanted to visualize the amount of time that has passed between releases of that product, what type of graph would I use? What I'm trying to show is the average amount of time that has passed between release cycles, as well as (approximately) how far through the current release cycle we currently are. The best I co...

How do I create a stacked column chart purely through programming with excel vba?

I am trying to create a stacked column chart in VBA where there is a bar graph and each bar graph shows the breakdown of subcategories on the graph (See right side of picture). For the normal bar graph all I had to do was create a new series and set the Values and XValues properties. I'm not sure how to tell it about the values for the...

exact graph algorithms

in data structures and algorithms, what is meant by "Exact Graph Algorithms" ? can you give me some examples? ...

Ada: plotting 2d graphs

Hi, it would be interesting to be able to plot a 2D graph within an Ada code rather than having to save values say to file and use an external drawing software afterwards. A search on the web has taken me to two packages: Win_IO and JEWL. I have been able to use WIN_IO though but the documentation is quite poor and having just started us...

Viewing graph into PDF

how can i show bar graph or pie chart into PDF? is there any way to do this by Zend_PDF class? pls help me ...

Incorrect results for average distance using Dijkstra (java)

The graph is unweighed, an element of the array of HashSets neighbours[] is a node neighbours[1] is node 1 (they start from 0 mind you) with its unique neighbouring nodes say 2 3 4 5. (so neighbours[5] will contain 1). And I have the following method I did with great deal of help as I dont get the algo much beyond theory. The number it ...

Matplotlib: move graph to the right

I have two graphs with in one image, each with 5 points. Their value on the X axis is not important, all that I require is that they're all equally distributed on it. import matplotlib.pyplot as plt data = [43,51,44,73,60] data2 = [34,25,42,53,61] fig = plt.figure(1) ax = fig.add_subplot(111) ax.plot(data, '-o', color='#000000', lw=...

Develop Graph on J2ME

Hi All, I going to develop Graph on my j2me application i've taken Canvas & I wann to draw graph on particular data then ho i can draw graph ... Thanks, Neel, ...