bug-prolog
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug on OS.X


From: Noé Lutz
Subject: bug on OS.X
Date: Fri, 4 Feb 2005 10:53:23 +0100

Hi there,

We discovered a bug in gnu prolog 1.2.16 running on OS.X 10.3:

Darwin applepie 7.7.0 Darwin Kernel Version 7.7.0: Sun Nov  7 16:06:51
PST 2004; root:xnu/xnu-517.9.5.obj~1/RELEASE_PPC  Power Macintosh
powerpc

We installed gprolog from a binary distribution, but we simply can't
remember where we got it... sorry.
This code does not produce the expected result, namely add the
constraint that the difference between X and Y is bigger or equal N:

CODE:
apart(X,Y,N) :-
        Y+N #=< X.
apart(X,Y,N) :-
        X+N #=< Y.


EXECUTION:
fd_domain([X,Y],0,5), apart(X,Y,3), fd_labeling([X,Y]).

We expect the following result (obtained on a windows machine)
X = 3
Y = 0 ? a

X = 4
Y = 0

X = 4
Y = 1

X = 5
Y = 0

X = 5
Y = 1

X = 5
Y = 2

X = 0
Y = 3

X = 0
Y = 4

X = 0
Y = 5

X = 1
Y = 4

X = 1
Y = 5

X = 2
Y = 5

... but we got this instead:

X = 3
Y = 0 ? a

X = 4
Y = 0

X = 5
Y = 0

Thanks
Yerly & Noé

-- 
-lll-




reply via email to

[Prev in Thread] Current Thread [Next in Thread]