jianxinlee
September 10th, 2002, 10:12 PM
Many books have explained graph a lot, but none can tell me something about how to build a graph(May be books I read are not enough, so I need your recommendation!).
Now I have to build a graph which can manage things like the picture(1), picture(2) in the file attached, and picture(3) must not appeared. The arrow in picture indicates the direction of the graph. At first I only know two points(the entry and the exit), and an array of edge lines(one line consist of two points).
The node in graph need to be like this:
// Edge is the edge line in pictures
struct
{
CArray<Edge*, Edge*> m_apOut; // the output of the node
CArray<Edge*, Edge*> m_apIn; // the input of the node
};
So please help me! I'm waiting!!!
:confused:
Now I have to build a graph which can manage things like the picture(1), picture(2) in the file attached, and picture(3) must not appeared. The arrow in picture indicates the direction of the graph. At first I only know two points(the entry and the exit), and an array of edge lines(one line consist of two points).
The node in graph need to be like this:
// Edge is the edge line in pictures
struct
{
CArray<Edge*, Edge*> m_apOut; // the output of the node
CArray<Edge*, Edge*> m_apIn; // the input of the node
};
So please help me! I'm waiting!!!
:confused: