B. Download the file digraphData.zip. This file contains several random
digraphs for testing you digraph class.
There are 6 files named grN_s.txt, where N is the number of
nodes and s is the sparsity factor, defined as the number of
edges divided by N^2. Each file begins with the number of nodes
and number of edges, followed by a node pair for each edge. Nodes are
numbered 0, 1,... N-1. You can use these graphs
to test your digraph class. I would suggest drawing a couple of the
smaller ones so you can verify that your dfs is
working. It will be pretty hard for you (or me!) to verify dfs for
the larger graphs, as dfs orderings are not unique.
I also include the program I used to generate the graphs. You are welcome
to experiment with it. Frankly, I'm not terribly
happy with the graphs it generates. They are proper graphs, and the
are random, but in a curious way.
Test the functionality of your class DiGraph using the small graphs gr5_9 gr10_5. Your output should do the displays in the following order, with appropriate headings: