Re: [gecode-users] Problem to formulate a constraint

2013-05-28 Thread Guido Tack
Hi, yes, you should channel your c_a and c_b arrays to BoolVars, then you can simply post the constraints directly using the minimodel abstractions: BoolVarArgs b_a(...); channel(home, b_a, c_a); BoolVarArgs b_b(...); channel(home, b_b, c_b); for (int j=0; jhttp://www.csse.monash.edu/~guidot/

Re: [gecode-users] Problem to formulate a constraint

2013-05-26 Thread Uwe Nowak
Hi! Sorry for spamming the mailing list... At the moment I am focussing on the 3rd ide of modelling. Then I have to formulate constraints as c=j <==> x_{j+u} = v By substituting i=j-u I get c=i+u <==> x_i = v Which looks pretty much like the channel constraint, except that on the right side t

Re: [gecode-users] Problem to formulate a constraint

2013-05-25 Thread Uwe Nowak
Hi! Thank you for your answer. As I stated, I am a beginner to gecode and constraint programming at all. I did not try reification, but by this keyword I managed to solve the problem. However, I still think, that I am formulating my constraint in a bad way. I managed to reduce my (sub)probl

Re: [gecode-users] Problem to formulate a constraint

2013-05-23 Thread Christian Schulte
Hi, Did you try reification? While not great, it should not be too hard to pull this off. Or am I missing something here? Best Christian -- Christian Schulte, Professor of Computer Science, KTH, www.ict.kth.se/~cschulte/ -Original Message- From: users-boun...@gecode.org [mailto:users-b