Path: utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!munnari.oz.au!sirius.ucs.adelaide.edu.au!fang!jug From: jug@itd.dsto.oz (Jim Grundy) Newsgroups: comp.object Subject: Re: Constraint Logic Programming Message-ID: <576@fang.dsto.oz> Date: 17 Jan 90 16:46:34 GMT References: <25ae8b54.b1d@polyslo.CalPoly.EDU> Sender: news@fang.dsto.oz Reply-To: jug@itd.dsto.oz Lines: 36 From article <25ae8b54.b1d@polyslo.CalPoly.EDU>, by jdudeck@polyslo.CalPoly.EDU (John R. Dudeck): > > Some of us read this newsgroup to learn about things we otherwise don't > encounter. Would somebody like to give a 2-paragraph explanation of > what CLP is, say, compared to PROLOG? > > Does the TRILOGY language from Complete Logic Systems, Vancouver, B.C., > have anything to do with CLP? Your everyday logic programming language like PROLOG operates with a search based operational sematics (resolution in the case of PROLOG). This allows PROLOG programs to solve a fairly narrow class of logic problems. Now constraint logic programming adds to this an array of domain specific problem solving algorithms, for say the domains of real numbers and sets. For example a gausian elimination engine may be added for the purpose of solving systems of equations. The ai comunity has developed a bunch of contraint solvers over other domains over the years. Lets look at the following example in some sort of hybred prolog that also contains a gausian elemination engine. resistor(V, I, V / I). parrallel(V, R1, R2, I1 + I2) :- resistor(V, I1, R1), resistor(V, I2, R2). serial(I, R1, R2, V1 + V2) :- resistor(V1, I, R1), resistor(V2, I, R2). par_ser(I, R1, R2, R3, R4, V1 + V2) :- parrallel(V1, R1, R2, I), parrallel(V2, R3, R4, I). Now par_ser(5, 10, 10, 10, 10, A) evaluates to A=50. This examle is a molested version of an example appearing in: Darlington J. & Gou Yi-ke 1988, Towards Constraint Functional Programming, Department of Computer Science Imperial Colledge, London. Anyway I think thats what clp is anyone else got a better idea? JIM