Article View: comp.lang.prolog
Article #1191Manipulating cyclic graphs in prolog
From: Mark Johnson
Date: Thu, 13 Sep 1990 11:25
Date: Thu, 13 Sep 1990 11:25
19 lines
1530 bytes
1530 bytes
Here's a question I'd like to throw out to the prolog community. The specific issue I'd like to raise is that it is difficult to find an efficent term representation of labelled cyclic graphs (for access and update). Representing the nodes of such a graph as a label and a list of edges, where an edge is a pair consisting of a label and a node, results in a ``cyclic structure'', with all the logical and implementational problems discussed in this newsgroup a while ago. And an obvious solution: to store the nodes in an array, and change the representation of an edge to be a pair consisting of a label and an index into this array, suffers from the lack of an efficient way of implementing for arrays. So how can cyclic graphs be efficiently implemented in Prolog? Suggestions welcome, Mark Johnson.
Technical Details
Message-ID:
<MARK.90Sep13132523@geier.philosophie.uni-stuttgart.de>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!snorkelwacker!ira.uka.de!rusux1!markReferences:
<90239.175243SCHMIED@DB0TUI11.BITNET> <1990Sep11.150245.26833@sics.se> <1990Sep12.170553.14414@cl.cam.ac.uk> <3996@bingvaxu.cc.binghamton.edu> <1990Sep13.071715.4852@sics.se>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!snorkelwacker!ira.uka.de!rusux1!mark From: mark@geier.philosophie.uni-stuttgart.de (Mark Johnson) Newsgroups: comp.lang.prolog Subject: Manipulating cyclic graphs in prolog Message-ID: <MARK.90Sep13132523@geier.philosophie.uni-stuttgart.de> Date: 13 Sep 90 11:25:23 GMT References: <90239.175243SCHMIED@DB0TUI11.BITNET> <1990Sep11.150245.26833@sics.se> <1990Sep12.170553.14414@cl.cam.ac.uk> <3996@bingvaxu.cc.binghamton.edu> <1990Sep13.071715.4852@sics.se> Sender: zrf80385@rusux1.rus.uni-stuttgart.de Organization: IMS, University of Stuttgart Lines: 19 In-reply-to: matsc@sics.se's message of 13 Sep 90 07:17:15 GMT