Closed Thread Icon

Topic awaiting preservation: Topological Ordering Pages that link to <a href="https://ozoneasylum.com/backlink?for=7084" title="Pages that link to Topic awaiting preservation: Topological Ordering" rel="nofollow" >Topic awaiting preservation: Topological Ordering\

 
Author Thread
supreme_commander
Nervous Wreck (II) Inmate

From: QLD
Insane since: Mar 2003

posted posted 10-21-2003 14:57

Hey
Just wondering if anyone knows or has the C coding for toplogical sorting of a graph, (matrix, multidemension array)
If anyone does could you post it for me

Would be most appreciated

Thanks

Petskull
Maniac (V) Mad Scientist

From: 127 Halcyon Road, Marenia, Atlantis
Insane since: Aug 2000

posted posted 10-21-2003 16:53

um.... what?

please elaborate, It sounds like you might be talking about something cool...

btw, this isn't DHTML/Javascript, so find it in the main forum...


Code - CGI - links - DHTML - Javascript - Perl - programming - Magic - http://www.twistedport.com
ICQ: 67751342

hyperbole
Paranoid (IV) Inmate

From: Madison, Indiana, USA
Insane since: Aug 2000

posted posted 10-21-2003 19:03

I used to have a book by Nichlaus Wirth called "Data Structures + Algoriths = Programs". I t describes a topological sort. I don't have the book any more, or I would post the code for you.

If you can find an open source copy of the 'ar' utility for Linux (or UNIX), it uses a topological sort to order the modules in the library as it creates them,

I don't know if the following will help, but I found this at the Duke University web site:

code:
Topological Sort in Words

Each node gets a color.

* White nodes haven't been dealt with yet.
* Black nodes have been completely dealt with.
* Gray nodes are in progress.

Flow:

* Make all nodes white.
* Pick a node u to ``visit'' and make it gray.
* Pick a child of u to visit.
* Continue until we run out of white kids.
* Add the last visited node to a list and backtrack.




A quick search of google for "topological sort" yeilds lots of results you might try reading them.




-- not necessarily stoned... just beautiful.

Petskull
Maniac (V) Mad Scientist

From: 127 Halcyon Road, Marenia, Atlantis
Insane since: Aug 2000

posted posted 10-21-2003 21:47

ah, topological!!

I read topographical and thought you were talking about some OpenGL shit...

...now, while it still doesn't belong in DHTML/Javascript, it no longer drips of cool....


Code - CGI - links - DHTML - Javascript - Perl - programming - Magic - http://www.twistedport.com
ICQ: 67751342

« BackwardsOnwards »

Show Forum Drop Down Menu