[eclipse-clp-users] Combining lib(cardinal) and lib(fd)

From: Philipp Marcus <marcus_at_...247...>
Date: Mon, 19 Apr 2010 10:49:56 +0200
Hi,

I want to write a constraint like this (using propia, cardinal and fd):

    N `:: [] + [ ["B","F"], ["S"], ["S","F"] ]:[1],
    A in N,
    member("S",A) infers most

i.e. the set N can be either ["B","F"], ["S"] or ["S","F"] but by using 
the constraint -- member("S",A) infers most -- I want to exclude 
["B","F"] from the domain of N.
But this doesn't work the way I've posted it here. ECLiPSe writes out 
the following:

    ?- N `:: []+[["B", "F"], ["S"], ["S", "F"]]:[1], A in N, member("S",
    A) infers most.
    N = N{cardinal([[]:0, [["B", "F"], ["S"], ["S", "F"]]:3], 1, _722,
    _723, _724, ['SUSP-_892-susp'], [], [], [])}
    A = [_1083{_1088}|_1065{_1070}]
    There are 3 delayed goals.
    Yes (0.00s cpu)

I would be really happy if somebody could help me with this problem.
Best regards,
Philipp
Received on Mon Apr 19 2010 - 09:44:00 CEST

This archive was generated by hypermail 2.3.0 : Thu Feb 22 2024 - 18:13:20 CET