Re: [eclipse-clp-users] (no subject)

From: Carmen Gervet <cgervet_at_bu.edu>
Date: Wed, 4 Jun 2008 12:44:58 -0400
Hi,

It seems that what you want to do is to concatenate two lists of sets. You
use bounds as a shorthand for the actual list of sets but Z's domain is not
a set union it is a concatenation of the 2 lists of sets.

The icset library (as far as I know) and its predecessors do not handle
holes in set domains, ie. do not represent set domains as union of set
intervals (computationally too expensive to maintain and propagate). Think
of the analogy with real interval arithmetic, it is similar to handling
union of real intervals as one domain and reasoning over them. Too costly to
propagate and maintain.

I would suggest you either enumerate what those set intervals represent (OK
if bounds are not too far apart) and do simple list manipulation to create
an enumerated set domain, or create the actual union (approximation) and add
constraints stating which subsets should be out.

Carmen

On Wed, Jun 4, 2008 at 7:32 AM, <mkhiari_at_etu.info.unicaen.fr> wrote:

> Hie,
>
> We would like to use IntegerSet variables whose initial domains
> are not a single interval, but a UNION of intervals.
>
> Is there a simple way to state this in ECLiPSe, since union
> is defined for IntegerSets but not for Sets of IntegerSets ?
> (and we don't want to have to enumerate each of the intervals)
> Example :
>
> X :: [1, 2] .. [1, 2, 3], (= {{1,2},{1,2,3}})
> Y :: [5]..[5,6],(= {{5},{5,6}}
>
> using all_union([X,Y],Z), we obtain Z = [1,2,5]..[1,2,3,5,6] which is
> explicitly noted Z = {{1,2,5},{1,2,5,3},{1,2,5,6},{1,2,5,3,6}} while on
> reality we want to build the set Z = {{1,2},{1,2,3},{5},{5,6}}. Is there a
> way to build such a set?
>
> yours sincerely,
>
> Mehdi
>
>
>
> -------------------------------------------------------------------------
> Check out the new SourceForge.net Marketplace.
> It's the best place to buy or sell services for
> just about anything Open Source.
> http://sourceforge.net/services/buy/index.php
> _______________________________________________
> ECLiPSe-CLP-Users mailing list
> ECLiPSe-CLP-Users_at_lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/eclipse-clp-users
>
Received on Wed Jun 04 2008 - 09:45:07 CEST

This archive was generated by hypermail 2.2.0 : Thu Feb 02 2012 - 02:31:58 CET