Connecting Tech Pros Worldwide Help | Site Map

How to create a Graph with linked-list representation ??

Newbie
 
Join Date: Aug 2009
Posts: 10
#1: Aug 12 '09
INPUT = no of vertices. RPRESENTATION -- Adjacency list.
DEGREE of each of the vertices = generate randomly within the function.
Randomly decide (within the function) which of the vertices are adjacent to a particular vertex.

I want to write a function in 'C' to implement the above, kindly provide me the algo./logic

Thanks
JosAH's Avatar
Expert
 
Join Date: Mar 2007
Posts: 10,611
#2: Aug 12 '09

re: How to create a Graph with linked-list representation ??


Quote:

Originally Posted by msingh00 View Post

INPUT = no of vertices. RPRESENTATION -- Adjacency list.
DEGREE of each of the vertices = generate randomly within the function.
Randomly decide (within the function) which of the vertices are adjacent to a particular vertex.

I want to write a function in 'C' to implement the above, kindly provide me the algo./logic

Thanks

So you want us to do the thinking and you just want to do the implementation? That's not how it works here: you do the work and when you're stuck you're welcome to come to us and we try to help you out. When I (to name one) have to do the thinking I charge about Euro 200.00 per hour.

kind regards,

Jos (moderator)

ps. I deleted your other (identical) post in the 'algorithms' forum.
Member
 
Join Date: Mar 2008
Posts: 101
#3: Aug 13 '09

re: How to create a Graph with linked-list representation ??


Sorry, I could nt understand ur question but if u want to create the graph with given adjacency list then i think boost(graph) library may help.
Reply