Hi All,

I am new to gecode and I have a question about how to model a constraint:
sum{a_i*b_i}

where a is an integer variable array and b is a bool variable array.
Basically I want to constrain the sum of some elements in a.

It seems that I cannot directly specify such constraint. Right now what I
can
think of is to use channel constraint to create an integer array with the
same
value as b and use it to specify the constraint I want.

Is this the right way to go?

Thanks~
-- 
Regards,
Dongrui
_______________________________________________
Gecode users mailing list
[email protected]
https://www.gecode.org/mailman/listinfo/gecode-users

Reply via email to