Skip to main content

Generalizing AllDifferent: The SomeDifferent Constraint

  • Conference paper
Principles and Practice of Constraint Programming - CP 2006 (CP 2006)

Part of the book series: Lecture Notes in Computer Science ((LNPSE,volume 4204))

Abstract

We introduce the SomeDifferent constraint as a generalization of AllDifferent. SomeDifferent requires that values assigned to some pairs of variables will be different. It has many practical applications. For example, in workforce management, it may enforce the requirement that the same worker is not assigned to two jobs which are overlapping in time. Propagation of the constraint for hyper-arc consistency is NP hard. We present a propagation algorithm with worst case time complexity O(n 3 β n) where n is the number of variables and β≈3.5 (ignoring a trivial dependence on the representation of the domains). We also elaborate on several heuristics which greatly reduce the algorithm’s running time in practice. We provide experimental results, obtained on a real-world workforce management problem and on synthetic data, which demonstrate the feasibility of our approach.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 84.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 109.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Appa, G., Magos, D., Mourtos, I.: On the system of two all_different predicates. Info. Process. Letters 94(3), 99–105 (2005)

    Article  MATH  MathSciNet  Google Scholar 

  2. Barnier, N., Brisset, P.: Graph coloring for air traffic flow management. In: Proc. of 4th CP-AI-OR workshop, pp. 133–147 (2002)

    Google Scholar 

  3. Beigel, R., Eppstein, D.: 3-coloring in time O(1.3289n). J. of Algorithms 54(2), 168–204 (2005)

    Article  MATH  MathSciNet  Google Scholar 

  4. Bodlaender, H.L., Kratsch, D.: An exact algorithm for graph coloring with polynomial memory. Technical Report UU-CS-2006-015. Department of Information and Computing Sciences. Utrecht University (2006)

    Google Scholar 

  5. Brelaz, D.: New methods to color the vertices of a graph. Communication of ACM 22(4), 251–256 (1979)

    Article  MATH  MathSciNet  Google Scholar 

  6. Byskov, J.M.: Exact algorithms for graph colouring and exact satisfiability. Ph.D thesis, University of Aarhus, Aarhus, Denmark (2005)

    Google Scholar 

  7. Dechter, R.: Constraint Processing. Morgan Kaufmann Publishers, San Francisco (2003)

    Google Scholar 

  8. Eppstein, D.: Small maximal independent sets and faster excat graph coloring. J. Graph Algorithms and Applications 7(2), 131–140 (2003)

    MATH  MathSciNet  Google Scholar 

  9. Grönkvist, M.: A constraint programming model for tail assignment. In: Proc. of 1st CP-AI-OR Conf., pp. 142–156 (2004)

    Google Scholar 

  10. Klotz, W.: Graph coloring algorithms. Technical Report Mathematik-Bericht 2002/5 TU Clausthal (2002)

    Google Scholar 

  11. Lawler, E.L.: A note on the complexity of the chromatic number problem. Info. Process. Letters 5(3), 66–67 (1976)

    Article  MATH  MathSciNet  Google Scholar 

  12. Naveh, Y., Emek, R.: Random stimuli generation for functional hardware verification as a cp application. In: van Beek, P. (ed.) CP 2005. LNCS, vol. 3709, pp. 882–882. Springer, Heidelberg (2005)

    Chapter  Google Scholar 

  13. Quimper, C.-G., van Beek, P., López-Ortiz, A., Golynski, A., Sadjad, S.B.S.: An efficient bounds consistency algorithm for the global cardinality constraint. In: Rossi, F. (ed.) CP 2003. LNCS, vol. 2833, pp. 600–614. Springer, Heidelberg (2003)

    Chapter  Google Scholar 

  14. Régin, J.-C.: A filtering algorithm for constraints of difference in CSPs. Technical Report R.R.LIRMM 93-068; (1993) Conf. version at AAAI 1994

    Google Scholar 

  15. Sellmann, M.: Approximated Consistency for Knapsack Constraints. In: Rossi, F. (ed.) CP 2003. LNCS, vol. 2833, pp. 679–693. Springer, Heidelberg (2003)

    Chapter  Google Scholar 

  16. Sellmann, M.: Cost-based filtering for shorter path constraints. In: Rossi, F. (ed.) CP 2003. LNCS, vol. 2833, pp. 694–708. Springer, Heidelberg (2003)

    Chapter  Google Scholar 

  17. Sellmann, M.: Approximated consistency for the automatic recording problem. In: van Beek, P. (ed.) CP 2005. LNCS, vol. 3709, pp. 822–826. Springer, Heidelberg (2005)

    Chapter  Google Scholar 

  18. Tsang, E., Ford, J., Mills, P., Bradwell, R., Williams, R., Scott, P.: ZDC-rostering: A personnel scheduling system based on constraint programming. Technical Report 406, University of Essex, Colchester, UK (2004)

    Google Scholar 

  19. van Hoeve, W.-J.: The Alldifferent constraint: a systematic overview. Under construction (2006), http://www.cs.cornell.edu/~vanhoeve

  20. West, D.B.: Introduction to graph theory. Prentice Hall, Englewood Cliffs (2000)

    Google Scholar 

  21. Yang, R.: Solving a workforce management problem with constraint programming. In: The 2nd International Conference on the Practical Application of Constraint Technology, pp. 373–387, The Practical Application Company Ltd. (1996)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2006 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Richter, Y., Freund, A., Naveh, Y. (2006). Generalizing AllDifferent: The SomeDifferent Constraint. In: Benhamou, F. (eds) Principles and Practice of Constraint Programming - CP 2006. CP 2006. Lecture Notes in Computer Science, vol 4204. Springer, Berlin, Heidelberg. https://doi.org/10.1007/11889205_34

Download citation

  • DOI: https://doi.org/10.1007/11889205_34

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-46267-5

  • Online ISBN: 978-3-540-46268-2

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics