Complexity results for answer set programming with bounded predicate arities and implications

  • Thomas Eiter
  • Wolfgang Faber
  • Michael Fink
  • Stefan Woltran
Article

Abstract

Answer set programming is a declarative programming paradigm rooted in logic programming and non-monotonic reasoning. This formalism has become a host for expressing knowledge representation problems, which reinforces the interest in efficient methods for computing answer sets of a logic program. The complexity of various reasoning tasks for general answer set programming has been amply studied and is understood quite well. In this paper, we present a language fragment in which the arities of predicates are bounded by a constant. Subsequently, we analyze the complexity of various reasoning tasks and computational problems for this fragment, comprising answer set existence, brave and cautious reasoning, and strong equivalence. Generally speaking, it turns out that the complexity drops significantly with respect to the full non-ground language, but is still harder than for the respective ground or propositional languages. These results have several implications, most importantly for solver implementations: Virtually all currently available solvers have exponential (in the size of the input) space requirements even for programs with bounded predicate arities, while our results indicate that for those programs polynomial space should be sufficient. This can be seen as a manifestation of the “grounding bottleneck” (meaning that programs are first instantiated and then solved) from which answer set programming solvers currently suffer. As a final contribution, we provide a sketch of a method that can avoid the exponential space requirement for programs with bounded predicate arities.

Keywords

Answer set programming Computational complexity 

Mathematics Subject Classifications (2000)

68N17 68Q17 

References

  1. 1.
    Abiteboul, S., Hull, R., Vianu, V.: Foundations of Databases. Addison-Wesley (1995)Google Scholar
  2. 2.
    Apt, K.R., Blair, H.A., Walker, A.: Towards a theory of declarative knowledge. In: Minker, J. (ed.) Foundations of Deductive Databases and Logic Programming, pp. 89–148. Morgan Kaufmann Publishers, Inc. (1988)Google Scholar
  3. 3.
    Baral, C.: Knowledge Representation, Reasoning and Declarative Problem Solving. Cambridge University Press (2002)Google Scholar
  4. 4.
    Ben-Eliyahu, R., Dechter, R.: Propositional semantics for disjunctive logic programs. Ann. Math. Artif. Intell. 12, 53–87 (1994)MATHCrossRefMathSciNetGoogle Scholar
  5. 5.
    Ben-Eliyahu-Zohary, R., Palopoli, L.: Reasoning with minimal models: efficient algorithms and applications. Artif. Intell. 96, 421–449 (1997)MATHCrossRefMathSciNetGoogle Scholar
  6. 6.
    Bonatti, P.A.: Resolution for skeptical stable model semantics. J. Autom. Reason. 27(4), 391–421 (2001)MATHCrossRefMathSciNetGoogle Scholar
  7. 7.
    Buccafurri, F., Leone, N., Rullo, P.: Enhancing disjunctive datalog by constraints. IEEE Trans. Knowl. Data Eng. 12(5), 845–860 (2000)CrossRefGoogle Scholar
  8. 8.
    Dantsin, E., Eiter, T., Gottlob, G., Voronkov, A.: Complexity and expressive power of logic programming. ACM Comput. Surv. 33(3), 374–425 (2001)CrossRefGoogle Scholar
  9. 9.
    Eiter, T., Fink, M.: Uniform equivalence of logic programs under the stable model semantics. In: Palamidessi, C. (ed.) Proceedings of the 19th International Conference on Logic Programming (ICLP’03). LNCS, vol. 2916, pp. 224–238. Springer (2003)Google Scholar
  10. 10.
    Eiter, T., Gottlob, G.: On the computational cost of disjunctive logic programming: propositional case. Ann. Math. Artif. Intell. 15(3/4), 289–323 (1995)MATHCrossRefMathSciNetGoogle Scholar
  11. 11.
    Eiter, T., Polleres, A.: Towards automated integration of guess and check programs in answer set programming: a meta-interpreter and applications. Theory Pract. Log. Program. 6(1–2), 23–60 (2006)MATHCrossRefMathSciNetGoogle Scholar
  12. 12.
    Eiter, T., Gottlob, G., Mannila, H.: Disjunctive datalog. ACM Trans. Database Syst. 22(3), 364–418 (1997)CrossRefGoogle Scholar
  13. 13.
    Eiter, T., Leone, N., Saccà, D.: Expressive power and complexity of partial models for disjunctive deductive databases. Theor. Comp. Sci. 206(1–2), 181–218 (1998)MATHCrossRefGoogle Scholar
  14. 14.
    Eiter, T., Faber, W., Leone, N., Pfeifer, G.: Computing preferred answer sets by meta-interpretation in answer set programming. Theory Pract. Log. Program. 3, 463–498 (2003)MATHCrossRefMathSciNetGoogle Scholar
  15. 15.
    Eiter, T., Faber, W., Fink, M., Pfeifer, G., Woltran, S.: Complexity of answer set checking and bounded predicate arities for non-ground answer set programming. In: Proceedings of the 9th International Conference on Principles of Knowledge Representation and Reasoning (KR’04), pp. 377–387. AAAI Press (2004)Google Scholar
  16. 16.
    Eiter, T., Fink, M., Tompits, H., Woltran, S.: Strong and uniform equivalence in answer-set programming: characterizations and complexity results for the non-ground case. In: Proceedings of the 20th National Conference on Artificial Intelligence (AAAI’05), pp. 695–700. AAAI Press (2005)Google Scholar
  17. 17.
    Eiter, T., Fink, M., Tompits, H., Traxler, P., Woltran, S.: Replacements in non-ground answer-set programming. In: Doherty, P., Mylopoulos, J., Welty, C.A. (eds.) Proceedings of the 10th International Conference on Principles of Knowledge Representation and Reasoning (KR’06), pp. 340–351. AAAI Press (2006)Google Scholar
  18. 18.
    Eiter, T., Fink, M., Tompits, H., Woltran, S.: Complexity results for checking equivalence of stratified logic programs. In: Veloso, M.M. (ed.) Proceedings of the 20th International Joint Conference on Artificial Intelligence (IJCAI’07), pp. 330–335. AAAI Press (2007)Google Scholar
  19. 19.
    Eiter, T., Fink, M., Woltran, S.: Semantical characterizations and complexity of equivalences in answer set programming. ACM Trans. Comput. Log. 8(3) (2007)Google Scholar
  20. 20.
    Faber, W., Konczak, K.: Strong order equivalence. Ann. Math. Artif. Intell. 47(1–2), 43–78 (2006)MATHCrossRefMathSciNetGoogle Scholar
  21. 21.
    Faber, W., Greco, G., Leone, N.: Magic sets and their application to data integration. J. Comput. Syst. Sci. 73(4), 584–609 (2007). doi: 10.1016/j.jcss.2006.10.012 Google Scholar
  22. 22.
    Faber, W., Tompits, H., Woltran, S.: Characterizing notions of strong equivalence for logic programs with ordered disjunctions. In: Delgrande, J., Kießling, W. (eds.) Proceedings of the 3rd Multidisciplinary Workshop on Advances in Preference Handling (M-PREF’07) (2007)Google Scholar
  23. 23.
    Fernández, J., Minker, J.: Bottom-up computation of perfect models for disjunctive theories. J. Log. Program. 25(1), 33–51 (1995)MATHCrossRefGoogle Scholar
  24. 24.
    Gebser, M., Liu, L., Namasivayam, G., Neumann, A., Schaub, T., Truszczynski, M.: The first answer set programming system competition. In: Baral, C., Brewka, G., Schlipf, J. (eds.) Proceedings of the 9th International Conference on Logic Programming and Nonmonotonic Reasoning (LPNMR’07). LNCS, vol. 4483, pp. 3–17. Springer (2007)Google Scholar
  25. 25.
    Gebser, M., Schaub, T., Thiele, S.: GrinGo: a new grounder for answer set programming. In: Baral, C., Brewka, G., Schlipf, J. (eds.) Proceedings of the 9th International Conference on Logic Programming and Nonmonotonic Reasoning (LPNMR’07). LNCS, vol. 4483, pp. 266–271. Springer (2007)Google Scholar
  26. 26.
    Gelfond, M.: Representing knowledge in A-Prolog. In: Kakas, A., Sadri, F. (eds.) Computational Logic: From Logic Programming into the Future. LNCS/LNAI, vol. 2408, pp. 413–451. Springer (2002)Google Scholar
  27. 27.
    Gelfond, M., Lifschitz, V.: The stable model semantics for logic programming. In: Logic Programming: Proceedings Fifth Intl Conference and Symposium, pp. 1070–1080. MIT Press, Cambridge, MA (1988)Google Scholar
  28. 28.
    Gelfond, M., Lifschitz, V.: Classical negation in logic programs and disjunctive databases. New Gener. Comput. 9, 365–385 (1991)CrossRefGoogle Scholar
  29. 29.
    Gottlob, G., Leone, N., Veith, H.: Succinctness as a source of expression complexity. Ann. Pure Appl. Log. 97(1–3), 231–260 (1999)MATHCrossRefMathSciNetGoogle Scholar
  30. 30.
    Gottlob, G., Leone, N., Scarcello, F.: The complexity of acyclic conjunctive queries. J. ACM 48(3), 431–498 (2001)CrossRefMathSciNetGoogle Scholar
  31. 31.
    Greco, S.: Optimization of disjunction queries. In: De Schreye, D. (ed.) Proceedings of the 16th International Conference on Logic Programming (ICLP’99), pp. 441–455. The MIT Press, Las Cruces, NM, USA (1999)Google Scholar
  32. 32.
    Greco, S.: Binding propagation techniques for the optimization of bound disjunctive queries. IEEE Trans. Knowl. Data Eng. 15(2), 368–385 (2003) (extended Abstract appeared as [31])CrossRefMathSciNetGoogle Scholar
  33. 33.
    Johnson, C.A.: Computing only minimal answers in disjunctive deductive databases. Tech. Rep. cs.LO/0305007, arXiv.org (2003)Google Scholar
  34. 34.
    Johnson, D.S.: A catalog of complexity classes. In: van Leeuwen, J. (ed.) Handbook of Theoretical Computer Science, Chap 2 (1990)Google Scholar
  35. 35.
    Leone, N., Pfeifer, G., Faber, W., Eiter, T., Gottlob, G., Perri, S., Scarcello, F.: The DLV system for knowledge representation and reasoning. ACM Trans. Comput. Log. 7(3), 499–562 (2006)CrossRefMathSciNetGoogle Scholar
  36. 36.
    Lifschitz, V.: Answer set programming and plan generation. Artif. Intell. 138, 39–54 (2002)MATHCrossRefMathSciNetGoogle Scholar
  37. 37.
    Lifschitz, V., Pearce, D., Valverde, A.: Strongly equivalent logic programs. ACM Trans. Comput. Log. 2(4), 526–541 (2001)CrossRefMathSciNetGoogle Scholar
  38. 38.
    Lin, F.: Reducing strong equivalence of logic programs to entailment in classical propositional logic. In: Fensel, D., Giunchiglia, F., McGuiness, D., Williams, M.A. (eds.) Proceedings of the 8th International Conference on Principles of Knowledge Representation and Reasoning (KR’02), pp. 170–176. Morgan Kaufmann (2002)Google Scholar
  39. 39.
    Liu, L., Truszczynski, M.: Properties of programs with monotone and convex constraints. In: Veloso, M., Kambhampati, S. (eds.) Proceedings of the 20th National Conference on Artificial Intelligence (AAAI’05), pp. 701–706. AAAI Press (2005)Google Scholar
  40. 40.
    Lobo, J., Minker, J., Rajasekar, A.: Foundations of Disjunctive Logic Programming. The MIT Press (1992)Google Scholar
  41. 41.
    Marek, V.W., Remmel, J.B.: On the expressibility of stable logic programming. Theory Pract. Log. Program. 3, 551–567 (2003)MATHCrossRefMathSciNetGoogle Scholar
  42. 42.
    Marek, V.W., Truszczyński, M.: Autoepistemic logic. J. Assoc. Comput. Mach. 38(3), 588–619 (1991)MATHMathSciNetGoogle Scholar
  43. 43.
    Marek, V.W., Truszczyński, M.: Stable models and an alternative logic programming paradigm. In: Apt, K., Marek, V.W., Truszczyński, M., Warren, D.S. (eds.) The Logic Programming Paradigm—A 25-Year Perspective, pp. 375–398. Springer (1999)Google Scholar
  44. 44.
    Minker, J.: On indefinite data bases and the closed world assumption. In: Loveland, D. (ed.) Proceedings of the 6th Conference on Automated Deduction (CADE ’82). LNCS, vol. 138, pp. 292–308. Springer (1982)Google Scholar
  45. 45.
    Minker, J.: Overview of disjunctive logic programming. Ann. Math. Artif. Intell. 12, 1–24 (1994)CrossRefMathSciNetGoogle Scholar
  46. 46.
    Minker, J.: Logic and databases: a 20 year retrospective. In: Proceedings of the International Workshop on Logic in Databases (LID’96). LNCS, vol. 1154, pp. 3–57. Springer (1996)Google Scholar
  47. 47.
    Minker, J., Rajasekar, A.: A fixpoint semantics for disjunctive logic programs. J. Log. Program. 9(1), 45–74 (1990)CrossRefMathSciNetMATHGoogle Scholar
  48. 48.
    Minker, J., Ruiz, C.: Semantics for disjunctive logic programs with explicit and default negation. Fundam. Inform. 20(1/2/3), 145–192 (1994)MATHMathSciNetGoogle Scholar
  49. 49.
    Minker, J., Seipel, D.: Disjunctive logic programming: a survey and assessment. In: Computational Logic: Logic Programming and Beyond, Essays in Honour of Robert A. Kowalski, Part I. LNCS, vol. 2407, pp. 472–511. Springer (2002)Google Scholar
  50. 50.
    Minker, J., Zanon, G.: An extension to linear resolution with selection function. Inf. Process. Lett. 14(3), 191–194 (1982)MATHCrossRefMathSciNetGoogle Scholar
  51. 51.
    Niemelä, I.: Logic programming with stable model semantics as constraint programming paradigm. Ann. Math. Artif. Intell. 25(3–4), 241–273 (1999)MATHCrossRefGoogle Scholar
  52. 52.
    Niemelä, I. (ed.): Language Extensions and Software Engineering for ASP. Tech. Rep. WP3, Working Group on Answer Set Programming (WASP), IST-FET-2001-37004 (2005). Available at http://www.tcs.hut.fi/Research/Logic/wasp/wp3/wasp-wp3-web/
  53. 53.
    Oikarinen, E., Janhunen, T.: Modular equivalence for normal logic programs. In: Brewka, G., Coradeschi, S., Perini, A., Traverso, P. (eds.) Proceedings of the 17th European Conference on Artificial Intelligence (ECAI’06), pp. 412–416. IOS Press (2006)Google Scholar
  54. 54.
    Papadimitriou, C.H.: Computational Complexity. Addison-Wesley (1994)Google Scholar
  55. 55.
    Pearce, D., Tompits, H., Woltran, S.: Encodings for equilibrium logic and logic programs with nested expressions. In: Brazdil, P., Jorge, A. (eds.) Proceedings of the 10th Portuguese Conference on Artificial Intelligence (EPIA’01). LNCS, vol. 2258, pp. 306–320. Springer (2001)Google Scholar
  56. 56.
    Provetti, A., Son, T.C. (eds.): Proceedings AAAI 2001 Spring Symposium on Answer Set Programming: Towards Efficient and Scalable Knowledge Representation and Reasoning, AAAI Press, Stanford, CA (2001)Google Scholar
  57. 57.
    Przymusinski, T.C.: On the declarative semantics of deductive databases and logic programs. In: Minker, J. (ed.) Foundations of Deductive Databases and Logic Programming, pp. 193–216. Morgan Kaufmann Publishers, Inc. (1988)Google Scholar
  58. 58.
    Reiter, R.: On closed world data bases. In: Gallaire, H., Minker, J. (eds.) Logic and Data Bases, pp. 55–76. Plenum Press, New York (1978)Google Scholar
  59. 59.
    Sagiv, Y.: Optimising DATALOG programs. In: Minker, J. (ed.) Foundations of Deductive Databases and Logic Programming, pp. 659–698. Morgan Kaufmann (1988)Google Scholar
  60. 60.
    Schlipf, J.S.: The expressive powers of logic programming semantics. J. Comput. Syst. Sci. 51(1), 64–86 (1995)MATHCrossRefMathSciNetGoogle Scholar
  61. 61.
    Seipel, D., Minker, J., Ruiz, C.: A characterization of the partial stable models for disjunctive databases. In: Proceedings of the International Logic Programming Symposium, pp. 245–259. MIT Press (1997)Google Scholar
  62. 62.
    Seipel, D., Minker, J., Ruiz, C.: Model generation and state generation for disjunctive logic programs. J. Log. Program. 32(1), 49–69 (1997)MATHCrossRefMathSciNetGoogle Scholar
  63. 63.
    Shen, Y.D., Yuan, L.Y., You, J.H.: SLT-resolution for the well-founded semantics. J. Autom. Reas. 28(1), 53–97 (2002)MATHCrossRefMathSciNetGoogle Scholar
  64. 64.
    Shmueli, O.: Decidability and expressiveness aspects of logic queries. In: Proceedings of the 6th ACM SIGACT-SIGMOD-SIGART Symposium on Principles of Database Systems (PODS’87), pp. 237–249. ACM Press (1987)Google Scholar
  65. 65.
    Syrjänen, T.: Lparse 1.0 User’s Manual (2002) http://www.tcs.hut.fi/Software/smodels/lparse.ps.gz
  66. 66.
    Turner, H.: Strong equivalence made easy: nested expressions and weight constraints. Theory Pract. Log. Program. 3(4–5), 602–622 (2003)Google Scholar
  67. 67.
    Vardi, M.: On the complexity of bounded-variable queries. In: Proceedings of the 14th ACM SIGACT-SIGMOD-SIGART Symposium on Principles of Database Systems (PODS’95), pp. 266–276. ACM Press (1995)Google Scholar
  68. 68.
    Woltran, S. (ed.): Answer set programming: model applications and proofs-of-concept. Tech. Rep. WP5, Working Group on Answer Set Programming (WASP), IST-FET-2001-37004 (2005). Available at http://www.kr.tuwien.ac.at/projects/WASP/report.html
  69. 69.
    Yahya, A.H.: Duality for goal-driven query processing in disjunctive deductive databases. J. Autom. Reas. 28(1), 1–34 (2002)MATHCrossRefMathSciNetGoogle Scholar

Copyright information

© Springer Science+Business Media B.V. 2008

Authors and Affiliations

  • Thomas Eiter
    • 1
  • Wolfgang Faber
    • 2
  • Michael Fink
    • 1
  • Stefan Woltran
    • 1
  1. 1.Institute of Information SystemsVienna University of TechnologyViennaAustria
  2. 2.Department of MathematicsUniversity of CalabriaRendeItaly

Personalised recommendations