Hi,
I have a question regarding how to avoid some combinations of variables
to test. I give here a simple example:
1. I have four IntVar a,b,c and d.
2. I want to allow a=2*b=2*c only if a==1 and d==0.
If have try to encode this constraint with a code that looks like:
        BoolVar tmp;
        tmp=expr(home,(a!=1)&&(a==2*b)&&(a==2*c)&&(d==0));
        rel(home,!tmp);
But it seems that it does not try the only combination allowed.
Is this the correct way ?
Thanks.
-- 
Dr. Pascal Francq
Belgium

_______________________________________________
Gecode users mailing list
users@gecode.org
https://www.gecode.org/mailman/listinfo/gecode-users

Reply via email to