One binary horn clause is enough | SpringerLink
Skip to main content

One binary horn clause is enough

  • Conference paper
  • First Online:
STACS 94 (STACS 1994)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 775))

Included in the following conference series:

Abstract

This paper proposes an equivalent form of the famous Böhm-Jacopini theorem for declarative languages. C. Böhm and G. Jacopini [1] proved that all programming can be done with at most one single whiledo. That result is cited as a mathematical justification for structured programming. A similar result can be shown for declarative programming. Indeed the simplest class of recursive programs in Horn clause languages can be defined by the following scheme:

where

$$\left\{ {\begin{array}{*{20}c}{\mathcal{A}_1 \leftarrow .} \\{\mathcal{A}_2 \leftarrow } \\{ \leftarrow \mathcal{A}_4 } \\\end{array} } \right.\mathcal{A}_3 . that is \forall x_1 \cdot \cdot \cdot \forall x_m \left[ {\mathcal{A}_1 \wedge \left( {\mathcal{A}_2 \vee \neg \mathcal{A}_3 } \right) \wedge \neg \mathcal{A}_4 } \right]$$

are positive first-order literals. This class is shown here to be as expressive as Turing machines and all simpler classes would be trivial. The proof is based on a remarkable and not enough known codification of any computable function by unpredictable iterations proposed by [5]. Then, we prove effectively by logical transformations that all conjunctive formulas of Horn clauses can be translated into an equivalent conjuctive 4-formula (as above). Some consequences are presented in several contexts (mathematical logic, unification modulo a set of axioms, compilation techniques and other program patterns).

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

Access this chapter

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

Similar content being viewed by others

References

  1. Böhm C., Jacopini G. “Flow diagrams, Turing machines and languages with only two formation rules.” Communications of the Association for Computing Machinery, Vol. 9, pp. 366–371. 1966.

    Google Scholar 

  2. Bouquard J.L. “Logic programming and Attribute grammars.” Ph.D. Thesis, Orléans 1992.

    Google Scholar 

  3. Bratko I. “Prolog Programming for Artificial Intelligence”. Addison-Wesley Publishers limited. 1986.

    Google Scholar 

  4. William F. Clocksin and Christopher S. Mellish, “Programming in Prolog”. Springer-Verlag. 1981.

    Google Scholar 

  5. Conway J.H. “Unpredictable Iterations.” Proc. 1972 Number Theory Conference. University of Colorado, pp 49–52. 1972.

    Google Scholar 

  6. Clark K.L., Tärnlund S.A. “A First Order Theory of Data and Programs.” in Proc. IFIP 77. pp. 939–944. 1977.

    Google Scholar 

  7. Dauchet M. “Simulation of Turing Machines by a regular rewrite rule.” Journal of Theoretical Computer Science. nℴ103. 409–420. 1992.

    Google Scholar 

  8. Devienne P., Lebègue P., Routier J.C. “Halting Problem of One Binary Horn Clause is Undecidable.” Proceedings of STACS'93, LNCS nℴ665, pp. 48–57, Springer-Verlag. Würzburg. February 1993.

    Google Scholar 

  9. Devienne P., Lebègue P., Routier J.C. “The Emptiness Problem of One Binary Recursive Horn Clause is Undecidable.” In proceedings of ILPS'93, Vancouver. MIT Press. pp 250–265. October 1993.

    Google Scholar 

  10. Goldfarb W. and Lewis H.R. “The decision problem for formulas with a small number of atomic subformulas” J. Symbolic Logic 38(3), pp. 471–480, 1973.

    Google Scholar 

  11. Guy R.K. “ Conway's Prime Producing Machine.” Mathematics Magazine. nℴ56. 26–33. 1983.

    Google Scholar 

  12. Hanschke P., Würtz J. “Satisfiability of the Smallest Binary Program.” Information Processing Letters, vol. 45, nℴ5. pp. 237–241. April 1993.

    Google Scholar 

  13. Harel D. “On folk theorems” CACM, vol. 23, nℴ7. pp. 379–389. 1980.

    Google Scholar 

  14. Kowalski R. A. “Logic for Problem Solving.” North Holland. New York. 1979.

    Google Scholar 

  15. Marcinkowski J., Leszek Pacholski “Undecidability of the Horn-Clause Implication Problem” Proc. of the 33rd FOCS. 1992.

    Google Scholar 

  16. Minsky M. “Computation: Finite and Infinite Machines.” Prentice-Hall. 1967.

    Google Scholar 

  17. Parrain A., Devienne P., Lebègue P. “Prolog programs transformations and Meta-Interpreters.” Logic program synthesis and transformation, Springer-Verlag, LOPSTR'91, Manchester. 1991.

    Google Scholar 

  18. Robinson J. A. “A Machine-oriented Logic Based on the Resolution Principle.” J. ACM nℴ 12, pp. 23–45. Januar 1965.

    Google Scholar 

  19. Schmidt-Schauss M. “Implication of clauses is undecidable.” Journal of Theoretical Computer Science, nℴ59, pp. 287–296. 1988.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Patrice Enjalbert Ernst W. Mayr Klaus W. Wagner

Rights and permissions

Reprints and permissions

Copyright information

© 1994 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Devienne, P., Lebègue, P., Routier, JC., Würtz, J. (1994). One binary horn clause is enough. In: Enjalbert, P., Mayr, E.W., Wagner, K.W. (eds) STACS 94. STACS 1994. Lecture Notes in Computer Science, vol 775. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-57785-8_128

Download citation

  • DOI: https://doi.org/10.1007/3-540-57785-8_128

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-57785-0

  • Online ISBN: 978-3-540-48332-8

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics