Hmm, I had a quick look at the code and I think it should rewrite to the int/int case. I am travelling right now, so I will look more carefully when I am back in a week or so.
Cheers Christian -- Christian Schulte, www.gecode.org/~schulte Professor of Computer Science, KTH, cschu...@kth.se Expert Researcher, SICS, cschu...@sics.se -----Original Message----- From: users-boun...@gecode.org [mailto:users-boun...@gecode.org] On Behalf Of Kish Shen Sent: Thursday, August 27, 2015 05:48 PM To: users@gecode.org Subject: Re: [gecode-users] propagation consistency of count (single value) constraint As a follow up to my previous post on this, then from the reference documentation, for count(home, x, y, IRT_EQ, z) where y and z are int, then there is only one consistency level supported, and it is not domain consistent. We have a rostering program (originally written for our ic solvder), which I used to test the Gecode interface, and it uses count constraints, and changing the consistency level affected the execution times significantly for certasin problem instances. I took a look again at the code, and the count constraints are with y and z being integers. (the execution times are faster with ICL_BND than ICL_DOM) The count single vsalue constraint is posted to Gecode using only one propagator, the version with y and z being IntVar (and if they are integers, they are posted as IntVar with a singleton domain). This is done for all constraints that have variants that accept both IntVar and int, as this avoid me having to write a lot of code to distinguish the argument types, and I remember asking about this here a while ago and I think Chirstian said that Gecode will figure out the best propagator to use for the argument. So my questions are: is the propagator posted the one with y and z being int? If so, is there more than consistency level for the propagator, as my result seem to suggest? The difference is very significant, e.g. for one instance: ICL_BND: 0.73s ICL_DOM: 198s the ICL_BND times are more than 100 times faster, and the only difference between the two runs are the count constraint posted with ICL_BND rather than ICL_DOM (running on the same machine, of course). Cheers, Kish _______________________________________________ Gecode users mailing list users@gecode.org https://www.gecode.org/mailman/listinfo/gecode-users _______________________________________________ Gecode users mailing list users@gecode.org https://www.gecode.org/mailman/listinfo/gecode-users