Log in

HSJ-Solver: a new method based on GHD for answering conjunctive queries and solving constraint satisfaction problems

  • Published:
Applied Intelligence Aims and scope Submit manuscript

Abstract

Evaluating conjunctive queries (CQs) is NP-hard in general; however, acyclic CQs or nearest acyclic CQs can be evaluated in polynomial time. Many structural methods for characterising such classes are proposed in the literature. However, exploiting these methods to answer CQs is not efficient in practice when the relations have a realistic size. In this work, we propose a new method called HSJ-Solver for evaluating CQs and for solving constraint satisfaction problems (CSPs) represented by a generalised hypertree decomposition (GHD). Experiments carried out on CSP benchmarks show that using HSJ-Solver significantly improves the achieved performance.

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

Access this article

Subscribe and save

Springer+ Basic
EUR 32.99 /Month
  • Get 10 units per month
  • Download Article/Chapter or Ebook
  • 1 Unit = 1 Article or 1 Chapter
  • Cancel anytime
Subscribe now

Buy Now

Price includes VAT (Brazil)

Instant access to the full article PDF.

Fig. 1
Algorithm 1
Fig. 2
Algorithm 2
Algorithm 3
Algorithm 4
Algorithm 5
Algorithm 6
Algorithm 7
Algorithm 8

Similar content being viewed by others

References

  1. Phokion G, Moshe Y (2000) Conjunctive-Query containment and constraint satisfaction. J Comput Syst Sci 61:302–332

    Article  MathSciNet  MATH  Google Scholar 

  2. Robertson N, Seymour P D (1986) Graph minors.ii. algorithmic aspects of treewidth. J Algorithms 7:309–322

    Article  MathSciNet  MATH  Google Scholar 

  3. Gyssens M, Jeavons P, Cohen D A (1994) Decomposing constraint satisfaction problems using database techniques. Artif Intell 66:57–89

    Article  MathSciNet  MATH  Google Scholar 

  4. Gottlob G, Leone N, Scarcello F (2000) A comparison of structural CSP decomposition methods. Artif Intell 124:243–282

    Article  MathSciNet  MATH  Google Scholar 

  5. Cohen DA, Jeavons P, Gyssens M (2005) A unified theory of structural tractability for constraint satisfaction and spread cut decomposition. In: Proceedings of the 19th international joint conference on artificial intelligence, pp 72-77

  6. Adler I, Gottlob G, Grohe M (2005) Hypertree width and related hypergraph invariants. In: The 3rd European conference on combinatorics, graph theory and applications (EuroComb 05), pp 5–10

  7. Grohe M, Marx D (2006) Constraint solving via fractional edge covers. In: Proceedings of SODA 2006, pp 289-298

  8. Habbas Z, Amroun K, Singer D (2016) Generalized Hypertree Decomposition for solving non binary CSP with compressed table constraints. RAIRO J 50:241–267

    Article  MathSciNet  MATH  Google Scholar 

  9. Amroun K, Habbas Z, Aggoune-Mtalaa W (2016) A compressed generalized hypertree decomposition-based solving technique for non binary constraint satisfaction problems. AI Communications J 29(2):371–392

    Article  MathSciNet  MATH  Google Scholar 

  10. Abiteboul S, Hull R, Vianu V (1995) FoundationsofDatabases. Addison-Wesley Reading

  11. Ullman J D (1989) Principles of Database and Knowledge Base Systems, Computer Science Press. 1 edition

  12. Yannakakis M (1981) Algorithms for Acyclic Database Schemes. In: Proceedings of Very Large Data Bases’81. pp 82-92

  13. Fagin R (1983) Degrees of acyclicity for hypergraphs and relational database schemes. J ACM. 30:514–550

    Article  MathSciNet  MATH  Google Scholar 

  14. Beeri C, Fagin R, Maier D, Yannakakis M (1983) On the desirability of Acyclic database schemes. J ACM 30:479–513

    Article  MathSciNet  MATH  Google Scholar 

  15. Montanari U (1974) Networks of constraints: Fundamental properties and applications to pictures processing. Inform Sci 7:95–132

    Article  MathSciNet  MATH  Google Scholar 

  16. Maier D (1986) The theory of relational databases rochville. Md. Computer Science Press

  17. Marc H G (1979) On the universal relation. Technical report, University of Toronto

  18. Bernstein PA, Goodman N (1981) The power of natural semijoins. SIAM J Comput 10 (4):751–771

    Article  MathSciNet  MATH  Google Scholar 

  19. Gottlob G, Grohe M, Musliu N, Samer M, Scarcello F (2005) Hypertree decomposition: structure, algorithms and applications. In: Conference: Proceedings of the 31st international conference on Graph-Theoretic Concepts in Computer Science. pp 1-15

  20. Gottlob G, Leone N, Scarcello F (1999) On tractable queries and constraints. In: Proceedings of the 10th international conference on database and expert systems applications. pp 1–15

  21. Gottlob G, Samer M (2009) A Backtracking-Based Algorithm for hypertree decomposition. ACM Journal of Experimental Algorithmics (JEA), 13

  22. Dermaku A, Ganzow T, Gottlob G, McMahan B, Musliu N, Samer M (2008) Heuristic Methods for hypertree decompositions. In: Proceeding of the 7th Mexican International Conference on Artificial Intelligence: Advances in Artificial Intelligence. pp 1-11

  23. Noll LC, Fowler G, Vo P, Hash FNV http://www.isthe.com/chongo/tech/comp/fnv/index.html Accessed on august 21, 19

  24. Lecoutre C, Likitvivatanavong C, Roland H C (2015) STR3: A path-optimal filtering algorithm for table constraints. Artif Intell 220:1–27

    Article  MathSciNet  MATH  Google Scholar 

  25. Demeulenaere J, Hartert R, Lecoutre C, Perez G, Perron L, Régin JC, Schaus P (2016) Compact-table: efficiently filtering table constraints with reversible sparse bit-sets. In: Poceedings of the 22th international conference on principles and practice of constraint programming. pp 207-223

  26. IMDB (2022) http://imdb.com Accessed on July 22, 2022

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Zineb Younsi.

Additional information

Publisher’s note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Rights and permissions

Springer Nature or its licensor (e.g. a society or other partner) holds exclusive rights to this article under a publishing agreement with the author(s) or other rightsholder(s); author self-archiving of the accepted manuscript version of this article is solely governed by the terms of such publishing agreement and applicable law.

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Younsi, Z., Amroun, K., Bouarab-Dahmani, F. et al. HSJ-Solver: a new method based on GHD for answering conjunctive queries and solving constraint satisfaction problems. Appl Intell 53, 17226–17239 (2023). https://doi.org/10.1007/s10489-022-04361-y

Download citation

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s10489-022-04361-y

Keywords

Navigation