Skip to main content
Log in

On look-ahead heuristics in disjunctive logic programming

  • Published:
Annals of Mathematics and Artificial Intelligence Aims and scope Submit manuscript

Abstract

Disjunctive logic programming (DLP), also called answer set programming (ASP), is a convenient programming paradigm which allows for solving problems in a simple and highly declarative way. The language of DLP is very expressive and able to represent even problems of high complexity (every problem in the complexity class \({{\Sigma}_{2}^{P}} = {\rm NP}^{{\rm NP}}\)). During the last decade, efficient systems supporting DLP have become available. Virtually all of these systems internally rely on variants of the Davis–Putnam procedure (for deciding propositional satisfiability [SAT]), combined with a suitable model checker. The heuristic for the selection of the branching literal (i.e., the criterion determining the literal to be assumed true at a given stage of the computation) dramatically affects the performance of a DLP system. While heuristics for SAT have received a fair deal of research, only little work on heuristics for DLP has been done so far. In this paper, we design, implement, optimize, and experiment with a number of heuristics for DLP. We focus on different look-ahead heuristics, also called “dynamic heuristics” (the DLP equivalent of unit propagation [UP] heuristics for SAT). These are branching rules where the heuristic value of a literal Q depends on the result of taking Q true and computing its consequences. We motivate and formally define a number of look-ahead heuristics for DLP programs. Furthermore, since look-ahead heuristics are computationally expensive, we design two techniques for optimizing the burden of their computation. We implement all the proposed heuristics and optimization techniques in DLV—the state-of-the-art implementation of disjunctive logic programming, and we carry out experiments, thoroughly comparing the heuristics and optimization techniques on a large number of instances of well-known benchmark problems. The results of these experiments are very interesting, showing that the proposed techniques significantly improve the performance of the DLV system.

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

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Similar content being viewed by others

References

  1. Baral, C.: Knowledge Representation, Reasoning and Declarative Problem Solving. Cambridge University Press (2003)

  2. Baral, C., Gelfond, M.: Logic programming and knowledge representation. J. Log. Program. 19/20, 73–148 (1994)

    Article  MathSciNet  Google Scholar 

  3. Ben-Eliyahu, R., Dechter, R.: Propositional semantics for disjunctive logic programs. Ann. Math. Artif. Intell. 12, 53–87 (1994)

    Article  MATH  MathSciNet  Google Scholar 

  4. Cadoli, M., Eiter, T., Gottlob, G.: Default logic as a query language. IEEE Trans. Knowl. Data Eng. 9(3), 448–463 (1997)

    Article  Google Scholar 

  5. Calimeri, F., Faber, W., Leone, N., Pfeifer, G.: Pruning operators for disjunctive logic programming systems. Fundam. Inform. 71(2–3), 183–214 (2006)

    MATH  MathSciNet  Google Scholar 

  6. Crawford, J.M., Auton, L.D.: Experimental results on the crossover point in random 3SAT. Artif. Intell. 81(1–2), 31–57 (1996)

    Article  MathSciNet  Google Scholar 

  7. Dubois, O., Dequen, G.: A backbone-search heuristic for efficient solving of hard 3-SAT formulae. In: Nebel, B. (ed.) Proc. 17th International Joint Conference on Artificial Intelligence IJCAI-01, pp. 248–253. Morgan Kaufmann (2001)

  8. Eiter, T., Faber, W., Leone, N., Pfeifer, G.: Declarative problem-solving using the DLV system. In: Minker, J. (ed.) Logic-Based Artificial Intelligence, pp. 79–103. Kluwer Academic Publishers (2000)

  9. Eiter, T., Gottlob, G.: On the computational cost of disjunctive logic programming: propositional case. Ann. Math. Artif. Intell. 15(3/4), 289–323 (1995)

    Article  MATH  MathSciNet  Google Scholar 

  10. Eiter, T., Gottlob, G.: The complexity of logic-based abduction. J. Assoc. Comput. Mach. 42(1), 3–42 (1995)

    MATH  MathSciNet  Google Scholar 

  11. Eiter, T., Gottlob, G., Mannila, H.: Disjunctive datalog. ACM Trans. Database Syst. 22(3), 364–418 (1997)

    Article  Google Scholar 

  12. Faber, W.: Enhancing efficiency and expressiveness in answer set programming systems. Ph.D. thesis, Institut für Informationssysteme, Technische Universität Wien (2002)

  13. Faber, W., Leone, N., Maratea, M., Ricca, F.: Experimenting with look-back heuristics for hard ASP programs. In: Baral, C., Brewka, G., Schlipf, J.S. (eds.) Logic Programming and Nonmonotonic Reasoning—9th International Conference, LPNMR 2007, Tempe, AZ, USA, May 2007, Proceedings, Lecture Notes in AI (LNAI), vol. 4483, pp. 110–122. Springer Verlag (2007)

  14. Faber, W., Leone, N., Mateis, C., Pfeifer, G.: Using database optimization techniques for nonmonotonic reasoning. In: INAP Organizing Committee (ed.) Proc. 7th International Workshop on Deductive Databases and Logic Programming (DDLP’99), pp. 135–139. Prolog Association of Japan (1999)

  15. Faber, W., Leone, N., Pfeifer, G.: Pushing goal derivation in DLP computations. In: Gelfond, M., Leone, N., Pfeifer, G. (eds.) Proc. 5th International Conference on Logic Programming and Nonmonotonic Reasoning (LPNMR’99). Lecture Notes in AI (LNAI), vol. 1730, pp. 177–191. Springer Verlag, El Paso, TX, USA (1999)

    Google Scholar 

  16. Faber, W., Leone, N., Pfeifer, G.: Experimenting with heuristics for answer set programming. In: Proc. Seventeenth International Joint Conference on Artificial Intelligence (IJCAI) 2001, pp. 635–640. Morgan Kaufmann Publishers, Seattle, WA, USA (2001)

    Google Scholar 

  17. Faber, W., Leone, N., Pfeifer, G.: Optimizing the computation of heuristics for answer set programming systems. In: Eiter, T., Faber, W., Truszczyński, M., (eds.) Logic Programming and Nonmonotonic Reasoning—6th International Conference, LPNMR’01, Vienna, Austria, September 2001, Proceedings, Lecture Notes in AI (LNAI), vol. 2173, pp. 288–301. Springer Verlag (2001)

  18. Faber, W., Ricca, F.: Solving hard ASP programs efficiently. In: Baral, C., Greco, G., Leone, N., Terracina, G. (eds.) Logic Programming and Nonmonotonic Reasoning—8th International Conference, LPNMR’05, Diamante, Italy, September 2005, Proceedings, Lecture Notes in Computer Science, vol. 3662, pp. 240–252. Springer Verlag (2005)

  19. Freeman, J.W.: Improvements on propositional satisfiability search algorithms. Ph.D. thesis, University of Pennsylvania (1995)

  20. Gebser, M., Kaufmann, B., Neumann, A., Schaub, T.: Conflict-driven answer set solving. In: Twentieth International Joint Conference on Artificial Intelligence (IJCAI-07), pp. 386–392. Morgan Kaufmann Publishers (2007)

  21. Gelfond, M., Lifschitz, V.: Classical Negation in logic programs and disjunctive databases. New Gener. Comput. 9, 365–385 (1991)

    Google Scholar 

  22. Gent, I., Walsh, T.: The QSAT phase transition. In: Proc. 16th AAAI (1999)

  23. Goldberg, E., Novikov, Y.: BerkMin: a fast and robust sat-solver. In: Design, Automation and Test in Europe Conference and Exposition (DATE 2002), pp. 142–149, 4–8 March 2002, Paris, France, IEEE Computer Society (2002)

  24. Hooker, J.N., Vinay, V.: Branching rules for satisfiability. J. Autom. Reason. 15, 359–383 (1995)

    Article  MATH  MathSciNet  Google Scholar 

  25. 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)

    Article  MathSciNet  Google Scholar 

  26. Leone, N., Rosati, R., Scarcello, F.: Enhancing answer set planning. In: Cimatti, A., Geffner, H., Giunchiglia, E., Rintanen, J. (eds.) IJCAI-01 Workshop on Planning under Uncertainty and Incomplete Information, pp. 33–42 (2001)

  27. Leone, N., Rullo, P., Scarcello, F.: Disjunctive stable models: unfounded sets, fixpoint semantics and computation. Inf. Comput. 135(2), 69–112 (1997)

    Article  MATH  MathSciNet  Google Scholar 

  28. Li, C., Anbulagan: Heuristics based on unit propagation for satisfiability problems. In: Proc. Fourteen International Joint Conference on Artificial Intelligence (IJCAI) 1997, pp. 366–371. Nagoya, Japan (1997)

  29. Li, C., Anbulagan: Look-ahead versus look-back for satisfiability problems. In: Smolka, G. (ed.) Proc. Third International Conference on Principles and Practice of Constraint Programming (CP’97), Lecture Notes in Computer Science, vol. 1330, pp. 342–356. Springer (1997)

  30. Li, C.M., Gérard, S.: On the limit of branching rules for hard random unsatisfiable 3-SAT. In: Proc. 14th European Conference on Artificial Intelligence ECAI-2000, pp. 98–102 (2000)

  31. Lierler, Y.: Disjunctive answer set programming via satisfiability. In: Baral, C., Greco, G., Leone, N., Terracina, G. (eds.) Logic Programming and Nonmonotonic Reasoning—8th International Conference, LPNMR’05, Diamante, Italy, September 2005, Proceedings, Lecture Notes in Computer Science, vol. 3662, pp. 447–451. Springer Verlag (2005)

  32. Lin, F., Zhao, Y.: ASSAT: computing answer sets of a logic program by SAT solvers. In: Proc. Eighteenth National Conference on Artificial Intelligence (AAAI-2002). AAAI Press, Edmonton, Alberta, Canada (2002)

    Google Scholar 

  33. Marek, V.W., Subrahmanian, V.: The relationship between logic program semantics and non-monotonic reasoning. In: Proc. 6th International Conference on Logic Programming—ICLP’89, pp. 600–617. MIT Press (1989)

  34. Minker, J.: On indefinite data bases and the closed world assumption. In: Loveland, D.W. (ed.) Proceedings 6th Conference on Automated Deduction (CADE ’82). Lecture Notes in Computer Science, vol. 138, pp. 292–308. Springer, New York (1982)

  35. Minker, J.: Overview of disjunctive logic programming. Ann. Math. Artif. Intell. 12, 1–24 (1994)

    Article  MathSciNet  Google Scholar 

  36. Moskewicz, M.W., Madigan, C.F., Zhao, Y., Zhang, L., Malik, S.: Chaff: engineering an efficient SAT solver. In: Proc. 38th Design Automation Conference, DAC 2001, Las Vegas, NV, USA, June 18–22, 2001, pp. 530–535. ACM (2001)

  37. Niemelä, I., Simons, P.: Efficient implementation of the well-founded and stable model semantics. In: Maher, M.J. (ed.) Proc. 1996 Joint International Conference and Symposium on Logic Programming (ICLP’96). pp. 289–303. MIT Press, Bonn, Germany (1996)

    Google Scholar 

  38. Papadimitriou, C.H.: Computational Complexity. Addison-Wesley (1994)

  39. Przymusinski, T.C.: Stable semantics for disjunctive programs. New Gener. Comput. 9, 401–424 (1991)

    Article  Google Scholar 

  40. Rintanen, J.: Improvements to the evaluation of quantified boolean formulae. In: Dean, T. (ed.) Proc. Sixteenth International Joint Conference on Artificial Intelligence (IJCAI) 1999, pp. 1192–1197. Morgan Kaufmann Publishers, Stockholm, Sweden (1999)

    Google Scholar 

  41. Selman, B., Kautz, H.: ftp://ftp.research.att.com/dist/ai/ (1997)

  42. Simons, P.: Extending and implementing the stable model semantics. Ph.D. thesis, Helsinki University of Technology, Finland (2000)

  43. Simons, P., Niemelä, I., Soininen, T.: Extending and implementing the stable model semantics. Artif. Intell. 138, 181–234 (2002)

    Article  MATH  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Nicola Leone.

Additional information

Some results in this paper have been presented in preliminary form at IJCAI-01 [16], LPNMR’01 [17], and LPNMR’05 [18].

Rights and permissions

Reprints and permissions

About this article

Cite this article

Faber, W., Leone, N., Pfeifer, G. et al. On look-ahead heuristics in disjunctive logic programming. Ann Math Artif Intell 51, 229–266 (2007). https://doi.org/10.1007/s10472-008-9087-4

Download citation

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s10472-008-9087-4

Keywords

Mathematics Subject Classifications (2000)

Navigation