[gecode-users] question about lexical ordering constraint and others

Kish Shen kisshen at cisco.com
Tue May 10 18:35:15 CEST 2011


Hi,

I have a few (more) question about various Gecode constraints that I am 
interfacing to ECLiPSe:

1) the constraint for lexical ordering

rel(Home, IntVarArgs, IntRelType, IntVarArgs)

requires the two arrays to be the same size. It seems the same 
restriction applies in the global constraint catalog for the lexical 
ordering constraints as well. However, the existing ECLiPSe lexical 
ordering constraints does not have this restriction -- i.e. the two 
sequences of numbers being compared can be different lengths. What is 
the reason for the same length restriction?

The lexical ordering for sequences of different length used in ECLiPSe 
seems to be the natural one, where missing numbers in the shorter 
sequence are replaced by 'bottom', i.e. a value smaller than any number.
So (using . to separate numbers in a sequence)

1.3 > 1.2.5

1.2.5 > 1.2

etc.

Could such a definition of ordering be used in the Gecode version as well?

2. What IntConLevel is supported in the binpacking constraint? I can't 
find a specification for this in the reference documentation (in 
doc-latest) [beyond the default of ICL_DEF]

3. For various versions of the same constraint (e.g. cumulative), some 
arguments can be IntArgs or IntVarArgs. In general, does it make a 
difference if I always use the version with IntVarArgs, even if all the 
IntVar has only one element in their domain (i.e. they are integers)?
I guess what I am asking is if (in general) Gecode does a check of its 
IntVarArgs argument to see if they are all integers and calls a more 
efficient implementation for the constraint if there is one? [I was 
specifically looking at the cumulative constraint, but there are 
obviously others].

The reaosn I ask is that in interfacing such constraints to ECLiPSe, I 
currently don't check if such arguments are all integers or if they 
contain some domain variables (IntVar). I can do this check, but if it 
is done in Gecode already, there is no reason for me to do so.


Thanks in advance for any help and information!

Cheers,

Kish

-- 
This e-mail may contain confidential and privileged material for the
sole use of the intended recipient. Any review, use, distribution or
disclosure by others is strictly prohibited. If you are not the intended
recipient (or authorized to receive for the recipient), please contact
the sender by reply e-mail and delete all copies of this message.
Cisco Systems Limited (Company Number: 02558939), is registered in
England and Wales with its registered office at 1 Callaghan Square,
Cardiff, South Glamorgan CF10 5BT.



More information about the users mailing list