Hello Fred,
> { // 1A + 1B > 0
> IntArgs coeffs(2); coeffs[0] = 1; coeffs[1] = 1;
> linear(*this, coeffs, s, IRT_GT, int(0));
> }
I am not sure how you got this to compile, because this should be
"IRT_GR".
> { // 1A + 0B > 0
> IntArgs coeffs(2); coeffs[0] = 1; coeffs[1] = 0;
> linear(*this, coeffs, s, IRT_GT, int(0));
> }
> { // 1A + 1B > 0
> IntArgs coeffs(2); coeffs[0] = 0; coeffs[1] = 1;
> linear(*this, coeffs, s, IRT_GT, int(0));
> }
> { // 0A + 0B <= 0
> IntArgs coeffs(2); coeffs[0] = 0; coeffs[1] = 0;
> linear(*this, coeffs, s, IRT_LE, int(0));
> }
Here you want IRT_LQ ( <= ) instead of IRT_LE ( < ).
_______________________________________________
Gecode users mailing list
[email protected]
https://www.gecode.org/mailman/listinfo/gecode-users