Hi,

 

This depends very much on whether you want to express your condition:

-          For each and every element in the array, or

-          Just for a particular element at a certain position in the array 
which is statically known, or

-          Just for a particular element where the index is not yet know, or

-          How large the array would be in practice, or

-          …

 

Same more info might help.

 

Best

Christian

 

--

Christian Schulte, KTH, web.it.kth.se/~cschulte/

 

From: users-boun...@gecode.org [mailto:users-boun...@gecode.org] On Behalf Of 
Richard Portelli
Sent: Tuesday, June 10, 2014 08:21 PM
To: users@gecode.org
Subject: [gecode-users] Cleaner way for if/then constraint condition

 

Hello,

I am looking for the "best" way to implement if/then type of constraint 
propagation.

An example would be : I have an array of 10 integers with sum =100. If one 
element is equal to 10, the following one should be 11.

Adding a lot of these constraint is it ressource intensive or not necessary?

Thanks for your help,

Cheers,
Richard

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

Reply via email to