title: Is any who has used the QuickGraph library recently available to assist me with a syntax issue found off an old example?
body: <p>I am researching the Quick Graph library for a school project in hopes that I won't have to use a C++/CLI implementation of a graph. For now, I would just like to run an example program that I found off of the QuickGraph discussion board.</p>
  
  <p>I am unable to compile the example I found because of four syntax errors. I think I can solve two of the errors on my own but the first I can't understand why the first two errors are happening.</p>
  
  <p>The code that I am trying to compile, which can also be found here <a href="http://quickgraph.codeplex.com/discussions/12668" rel="nofollow" title="QuickGraph Forum">Quick Graph Demo</a></p>
  
  <pre><code>AdjacencyGraph&lt;string, Edge&lt;string&gt;&gt; graph = new AdjacencyGraph&lt;string, Edge&lt;string&gt;&gt;(true);
  
  // Add some vertices to the graph
  graph.AddVertex("A");
  graph.AddVertex("B");
  graph.AddVertex("C");
  graph.AddVertex("D");
  graph.AddVertex("E");
  graph.AddVertex("F");
  graph.AddVertex("G");
  graph.AddVertex("H");
  graph.AddVertex("I");
  graph.AddVertex("J");
  
  // Create the edges
  Edge&lt;string&gt; a_b = new Edge&lt;string&gt;("A", "B");
  Edge&lt;string&gt; a_d = new Edge&lt;string&gt;("A", "D");
  Edge&lt;string&gt; b_a = new Edge&lt;string&gt;("B", "A");
  Edge&lt;string&gt; b_c = new Edge&lt;string&gt;("B", "C");
  Edge&lt;string&gt; b_e = new Edge&lt;string&gt;("B", "E");
  Edge&lt;string&gt; c_b = new Edge&lt;string&gt;("C", "B");
  Edge&lt;string&gt; c_f = new Edge&lt;string&gt;("C", "F");
  Edge&lt;string&gt; c_j = new Edge&lt;string&gt;("C", "J");
  Edge&lt;string&gt; d_e = new Edge&lt;string&gt;("D", "E");
  Edge&lt;string&gt; d_g = new Edge&lt;string&gt;("D", "G");
  Edge&lt;string&gt; e_d = new Edge&lt;string&gt;("E", "D");
  Edge&lt;string&gt; e_f = new Edge&lt;string&gt;("E", "F");
  Edge&lt;string&gt; e_h = new Edge&lt;string&gt;("E", "H");
  Edge&lt;string&gt; f_i = new Edge&lt;string&gt;("F", "I");
  Edge&lt;string&gt; f_j = new Edge&lt;string&gt;("F", "J");
  Edge&lt;string&gt; g_d = new Edge&lt;string&gt;("G", "D");
  Edge&lt;string&gt; g_h = new Edge&lt;string&gt;("G", "H");
  Edge&lt;string&gt; h_g = new Edge&lt;string&gt;("H", "G");
  Edge&lt;string&gt; h_i = new Edge&lt;string&gt;("H", "I");
  Edge&lt;string&gt; i_f = new Edge&lt;string&gt;("I", "F");
  Edge&lt;string&gt; i_j = new Edge&lt;string&gt;("I", "J");
  Edge&lt;string&gt; i_h = new Edge&lt;string&gt;("I", "H");
  Edge&lt;string&gt; j_f = new Edge&lt;string&gt;("J", "F");
  
  // Add the edges
  graph.AddEdge(a_b);
  graph.AddEdge(a_d);
  graph.AddEdge(b_a);
  graph.AddEdge(b_c);
  graph.AddEdge(b_e);
  graph.AddEdge(c_b);
  graph.AddEdge(c_f);
  graph.AddEdge(c_j);
  graph.AddEdge(d_e);
  graph.AddEdge(d_g);
  graph.AddEdge(e_d);
  graph.AddEdge(e_f);
  graph.AddEdge(e_h);
  graph.AddEdge(f_i);
  graph.AddEdge(f_j);
  graph.AddEdge(g_d);
  graph.AddEdge(g_h);
  graph.AddEdge(h_g);
  graph.AddEdge(h_i);
  graph.AddEdge(i_f);
  graph.AddEdge(i_h);
  graph.AddEdge(i_j);
  graph.AddEdge(j_f);
  
  // Define some weights to the edges
  Dictionary&lt;Edge&lt;string&gt;, double&gt; edgeCost = new Dictionary&lt;Edge&lt;string&gt;, double&gt;      (graph.EdgeCount);
  edgeCost.Add(a_b, 4);
  edgeCost.Add(a_d, 1);
  edgeCost.Add(b_a, 74);
  edgeCost.Add(b_c, 2);
  edgeCost.Add(b_e, 12);
  edgeCost.Add(c_b, 12);
  edgeCost.Add(c_f, 74);
  edgeCost.Add(c_j, 12);
  edgeCost.Add(d_e, 32);
  edgeCost.Add(d_g, 22);
  edgeCost.Add(e_d, 66);
  edgeCost.Add(e_f, 76);
  edgeCost.Add(e_h, 33);
  edgeCost.Add(f_i, 11);
  edgeCost.Add(f_j, 21);
  edgeCost.Add(g_d, 12);
  edgeCost.Add(g_h, 10);
  edgeCost.Add(h_g, 2);
  edgeCost.Add(h_i, 72);
  
  
  edgeCost.Add(i_f, 31);
  edgeCost.Add(i_h, 18);
  edgeCost.Add(i_j, 7);
  edgeCost.Add(j_f, 8);
  
  
  
  // We want to use Dijkstra on this graph
  //Error here "The best overloaded method match for 'QuickGraph.Algorithms.ShortestPath.DijkstraShortestPathAlgorithm&lt;string,QuickGraph.Edge&lt;string&gt;&gt;.DijkstraShortestPathAlgorithm(QuickGraph.IVertexListGraph&lt;string,QuickGraph.Edge&lt;string&gt;&gt;, System.Func&lt;QuickGraph.Edge&lt;string&gt;,double&gt;)' has some invalid arguments"
  
   DijkstraShortestPathAlgorithm&lt;string, Edge&lt;string&gt;&gt; dijkstra = new DijkstraShortestPathAlgorithm&lt;string, Edge&lt;string&gt;&gt;(graph, edgeCost);
  
  // attach a distance observer to give us the shortest path distances
  //Error here "'QuickGraph.Algorithms.Observers.VertexDistanceRecorderObserver&lt;string,QuickGraph.Edge&lt;string&gt;&gt;' does not contain a constructor that takes 0 arguments"
  
   VertexDistanceRecorderObserver&lt;string, Edge&lt;string&gt;&gt; distObserver = new VertexDistanceRecorderObserver&lt;string, Edge&lt;string&gt;&gt;();
   distObserver.Attach(dijkstra);
  
  // Attach a Vertex Predecessor Recorder Observer to give us the paths
   VertexPredecessorRecorderObserver&lt;string, Edge&lt;string&gt;&gt; predecessorObserver = new VertexPredecessorRecorderObserver&lt;string, Edge&lt;string&gt;&gt;();
   predecessorObserver.Attach(dijkstra);
  
  // Run the algorithm with A set to be the source
   dijkstra.Compute("A");
  
  foreach (KeyValuePair&lt;string, int&gt; kvp in distObserver.Distances)
   Console.WriteLine("Distance from root to node {0} is {1}", kvp.Key, kvp.Value);
  
  foreach(KeyValuePair&lt;string, Edge&lt;string&gt;&gt; kvp in predecessorObserver.VertexPredecessors)
   Console.WriteLine("If you want to get to {0} you have to enter through the in edge {1}", kvp.Key, kvp.Value );
  
  // Remember to detach the observers
   distObserver.Detach(dijkstra);
   predecessorObserver.Detach(dijkstra);
  </code></pre>
  
  <p>I'm assuming that the example had worked sometime in the past but some syntax has changed in during any updates that may have happened to the library. The two lines that are giving me error are the lines when the original creator of the code instantiated the DijkstraShortestPathAlgorithm and VertexDistanceRecorderObserver below the edge cost declarations.
  I'm hoping there is someone who has used this library recently to help me make sense of these answers or if possible direct me to some more recent examples of the quick graph. Thanks sincerely in advance.</p>