home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / lang / prolog / 2287 < prev    next >
Encoding:
Text File  |  1992-12-22  |  1.8 KB  |  46 lines

  1. Newsgroups: comp.lang.prolog
  2. Path: sparky!uunet!brunix!brunix!mj
  3. From: mj@cs.brown.edu (Mark Johnson)
  4. Subject: Re: Occurs check
  5. Message-ID: <1992Dec21.195646.3776@cs.brown.edu>
  6. Sender: news@cs.brown.edu
  7. Organization: Brown University Department of Computer Science
  8. References: <TORKEL.92Dec20104928@bast.sics.se> <1992Dec21.153147.26177@cs.brown.edu> <TORKEL.92Dec21175440@bast.sics.se>
  9. Date: Mon, 21 Dec 1992 19:56:46 GMT
  10. Lines: 34
  11.  
  12. In article <TORKEL.92Dec21175440@bast.sics.se> torkel@sics.se (Torkel Franzen) writes:
  13. >(Mark Johnson) writes:
  14. >
  15. >   >This is a nice way of viewing things, but I don't know any Prolog that
  16. >   >gives you all of the constraints C.  Consider the following program:
  17. >   >p(a) :- q(X,X).
  18. >   >q(Y, f(Y)).
  19. >    ....
  20. >   >That is, sicstus only returns constraints related to variables appearing
  21. >   >the goal.  But the constraints that only have cyclic solutions may be
  22. >   >associated with other variables.
  23. ...
  24. >  However, your example doesn't have anything to do with circular terms
  25. >in particular. You might as well define q by the clause q(b,b).
  26.  
  27. Only that the constraints that q introduces, viz. X=f(X),
  28. are not satisfiable wrt the standard equality theory.
  29. The answer Sicstus prolog returns gives the user no indication
  30. of this.  BTW, I don't think this is a problem with Sicstus, only
  31. that it doesn't solve all the problems involved with cyclic solutions.
  32.  
  33. Mark
  34.  
  35. P.S.  I'm interested in this approach.  I know of work by 
  36. Hoefeld and Smolka ``Definite Relations over Constraint Languages'',
  37. and Chen and D.S. Warren ``C-Logic of Complex Objects'' and
  38. ``Abductive Logic Programming'' that describe the decomposition
  39. into a relational and constraint components. Any other pointers
  40. to relevant literature?
  41.  
  42.  
  43. Mark Johnson
  44. Cognitive Science, Box 1978
  45. Brown University
  46.