944,087 Members | Top Members by Rank

Ad:
May 22nd, 2005
0

Directed Graph Problem

Expand Post »
What I want to achive is when given a directed graph, find out if there is one node that can reach every other node and if there is one node that can be reached by every other. Time complexity should be O(n+m).

I'm into finding all strongly connected parts in the graph and then check the connectivity among those. Can that be an appropriate solution or do I have to rethink it all? Maybe you guys have a better solution.
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
li_xia_er is offline Offline
1 posts
since May 2005
May 23rd, 2005
0

Re: Directed Graph Problem

Sounds like a spanning tree problem. I think you invert the direction and go from there, or something like that.
Reputation Points: 113
Solved Threads: 19
Postaholic
server_crash is offline Offline
2,108 posts
since Jun 2004

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Computer Science Forum Timeline: can anyone clear my doubt?
Next Thread in Computer Science Forum Timeline: Creating STL files From vertex and polygon data created in IDL





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC