Subject: Re: [SWIPL] another question

From: Steffen Moeller <[email-masked]>
Date: Thu, 31 May 2001 18:48:32 +0100 (BST)

I'm (a bit) afraid to say that I think your concept on what Prolog is
needs a quick review.

On Thu, 31 May 2001, Partsakoulakis Ioannis wrote:

> I want to ask how can I define a predicate
> a(+Term,+ListOfTerms,-ListOfInstances) such that if term Term is unifiable
> with a term in ListOfTemrs then ListOfInstances will contain the
> correspinding instance of Term. For example if ask
>
> ?- a( p(1,X), [p(Y,2),p(2,1),p(1,3)], L ).
>
> I want to take
>
> L = [p(1,2),p(1,3)].

Before I think of why or what you want to do (please specify) I can say
that neither X nor Y are instantiated. You probably want a reply like

X=2, Y=1, L=[p(1,2)];
X=3, Y=1, L=[p(1,3)];
No.

But this is something that Prolog just does not do out of the box.

So your questions can probably be rephrased as
"Hey folks, does anybody know a nice constraint solver for SWI-Prolog?"

Cheers,

Steffen

>
> Can somebody help me?
>
> Thanks,
>
> Yannis.
>
>
> ----------------
> * To UNSUBSCRIBE, please use the HTML form at
>
>     http://www.swi.psy.uva.nl/projects/SWI-Prolog/index.html#mailinglist
>
> or send mail to [email-masked] using the Subject: "unsubscribe"
> (without the quotes) and *no* message body.
>
> ** An ARCHIVE of this list is maintained at
>
>     http://www.swi.psy.uva.nl/projects/SWI-Prolog/mailinglist/archive/
>
>

    Steffen Moeller <[email-masked]>    ICQ 37032340