instantiation problem

From: Martin Lorenz <mlo_at_tzi.de>
Date: Mon 08 Mar 2004 03:52:13 PM GMT
Message-ID: <404C96AD.9020806@tzi.de>
Dear colleagues,

allthough my prolog skills are not the worst i am somehow stuck in a
dead-end street...

I try to formulate the following problem:

i have a set of facts with numerical values like
p(10,10).
p(20,10).
p(40,60).
etc...

Now I need to pose some query which is able to instantiate p/2 with
values that are up to X (at most 4 in my case) off the values given by
the facts AND I will need to infer the deviation value that led to the
given instantiation thus having some p/3

?- p(X,Y,D).
X=21
Y=13
D=2 (<-just as an example)
Yes.

Maybe I am simply thinking along the wrong path, so I would be thankful
for any hint.

tnx
mlo
-- 
-------------------------------------------------
                                    Martin Lorenz
      University of Bremen
TZI - Center for Computing Technologies

Universitaetsallee 21-23, Room 17, D-28359 Bremen
PO Box 330 440, D-28334 Bremen, Germany

Phone: +49-421-218-7835    Fax:  +49-421-218-7196
eMail: mlo_at_tzi.de     www: http://www.tzi.de/~mlo
-------------------------------------------------
Received on Mon Mar 08 16:02:21 2004

This archive was generated by hypermail 2.1.8 : Wed 16 Nov 2005 06:07:27 PM GMT GMT