I am playing with a 2d bin packing model. I tried this using:
for j in range(n): for i in range(j): model.Add(b[i] == b[j]).OnlyEnforceIf(b2[(i,j)]) # not