[gecode-users] help ----puzzles of defining Variable

Guido Tack tack at ps.uni-sb.de
Mon Aug 3 08:26:18 CEST 2009


Kayler Yao wrote:
> 2. But i still not understand your reply well about the first  
> question. whether your means are that distinct constraint is only  
> used for IntVarArgs, as written in the manual of Gecode ---
> " void 	Gecode::distinct (Space &home, const IntVarArgs &x,  
> IntConLevel icl=ICL_DEF)"
> But i found that  i can also use IntVarArray in distinct constraint  
> through testing, and also see it in the example "money.cpp" supplied  
> by the manual of Gecode 3.1.0. As follows:
>   " IntVarArray le;
>    distinct(*this, le, opt.icl()) "
> I know they are Array, from their definition i have no idea to  
> understand the reason why they can all be used in distinct  
> constraint .

Read 4.2.2 in the tutorial.

Guido

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.ps.uni-sb.de/pipermail/users/attachments/20090803/99c49fcb/attachment.htm>


More information about the gecode-users mailing list