From a7b4667e6c3e5034804fd29d17fcb07436b1ee8b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADtor=20Santos=20Costa?= Date: Sun, 5 Oct 2014 23:51:06 +0100 Subject: [PATCH] looking at operators. --- packages/gecode/clp_examples/3jugs.yap | 10 +++++----- packages/gecode/clpfd.yap | 4 +--- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/packages/gecode/clp_examples/3jugs.yap b/packages/gecode/clp_examples/3jugs.yap index 94dfaa918..f5749f530 100644 --- a/packages/gecode/clp_examples/3jugs.yap +++ b/packages/gecode/clp_examples/3jugs.yap @@ -29,11 +29,11 @@ problem(Z, X, InFlow, OutFlow, N) :- End = 15, M = 999, d( M, DD ), - D = array[1..N,1..N] of DD, % distance - RHS = array[1..N] of _, % requirements (right hand statement) - X = array[1..N, 1..N] of 0..1, % the resulting matrix, 1 if connected, 0 else - OutFlow = array[1..N] of 0..1, - InFlow = array[1..N] of 0..1, + D <== array[1..N,1..N] of DD, % distance + RHS <== array[1..N] of _, % requirements (right hand statement) + X <== array[1..N, 1..N] of 0..1, % the resulting matrix, 1 if connected, 0 else + OutFlow <== array[1..N] of 0..1, + InFlow <== array[1..N] of 0..1, % objective to minimize Z in 0..M, diff --git a/packages/gecode/clpfd.yap b/packages/gecode/clpfd.yap index a75fb23e6..78f4798ed 100644 --- a/packages/gecode/clpfd.yap +++ b/packages/gecode/clpfd.yap @@ -50,8 +50,6 @@ Constraints supported are: op(700, xf, #=<), op(700, xf, #=), op(700, xf, #\=), - op(700, xfx, in), - op(700, xfx, ins), op(500, yfx, '<=>'), op(500, yfx, '=>'), op(450, xfx, ..), % should bind more tightly than \/ @@ -236,7 +234,7 @@ The product of constant _Cs_ by _Vs_ must be in relation :- use_module(library(gecode)). :- use_module(library(maplist)). -:- reexport(library(matrix), [(<==)/2, op(600, xfx, '<=='), +:- reexport(library(matrix), [(<==)/2, op(800, xfx, '<=='), op(700, xfx, in), op(700, xfx, ins), op(450, xfx, ..), % should bind more tightly than \/