Skip to main content
Log in

Adas and the equational theory of if-then-else

  • Published:
algebra universalis Aims and scope Submit manuscript

Abstract

Programming languages admit the ternary operator ifp thenf elseg wherep is a test which may not halt. Here,p ranges over a suitable 3-valued logic. Guzmán and Squier recently introduced “C-algebras” and an equational 3-valued generalization of Boolean algebra based on “or”, “andrd and “not”. We incorporate their results and introduce as well the concept of “ada” (for Algebra of Disjoint Alternatives) which results whenC-algebras are equipped with an oracle for the halting problem. The 3-element ada is functionally complete. For if-then-else over a Boolean algebra or over an ada, eight equations generate all. The resulting variety may be represented as a variety of modules over a Boolean algebra. Over aC-algebra, a ninth equation is required.

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.

Institutional subscriptions

Similar content being viewed by others

References

  1. Bergman, G.,Actions of Boolean rings on sets. Algebra Universalis28 (1991), 153–187.

    Google Scholar 

  2. Bloom, S. L. andTindell, R.,Varieties of “if-then-else”. SIAM J. Comput.12 (1983), 677–707.

    Google Scholar 

  3. Cohn, P. M.,Universal Algebra. Harper and Row, 1965.

  4. Dijkstra, E. W.,A Discipline of Programming. Prentice Hall, 1976.

  5. Foster, A. L.,p-rings and their Boolean-vector representation. Acta Mathematica84 (1951), 231–261.

    Google Scholar 

  6. Foster, A. L.,Generalized “Boolean” theory of universal algebras, Part II. Identities and subdirect sums of functionally complete algebras. Math. Zeit.59 (1953), 191–199.

    Google Scholar 

  7. Gries, D.,The Science of Programming. Springer-Verlag, 1981.

  8. Guessarian, I. andMeseguer, J.,On the axiomalization of if-then-else. SIAM J. Comput.16 (1987), 332–357.

    Google Scholar 

  9. Guzmán, F. andSquier, C.,The algebra of conditional logic. Algebra Universalis27 (1990), 88–110.

    Google Scholar 

  10. Hoare, C. A. R.,Communicating Sequential Processes. Prentice-Hall, 1985.

  11. Hu, T.-K.,Stone duality for primal algebra theory. Math. Z.110 (1969), 180–198.

    Google Scholar 

  12. Huntington, E. V.,Sets of independent postulates for the algebra of logic. Trans. Amer. Math. Soc.5 (1904), 288–309.

    Google Scholar 

  13. Johnson, J. S. andManes, E. G.,On modules over a semiring. J. Algebra15 (1970), 57–67.

    Google Scholar 

  14. Kleene, S.,Introduction to Metamathematics. Van Nostrand, 1952.

  15. Lawvere, F. W.,Functorial Semantics of Algebraic Theories. Dissertation, Mathematics Department, Columbia University, 1963.

  16. Manes, E. G.,Guard modules. Algebra Universalis21 (1985), 103–110.

    Google Scholar 

  17. Manes, E. G.,Predicate Transformer Semantics. Cambridge University Press, 1993.

  18. Manes, E. G. andArbib, M. A.,Algebraic Approaches to Program Semantics. Springer-Verlag, 1986.

  19. McCarthy, J.,A basis for a mathematical theory of computation. In P. Braffort and D. Hirschberg (eds.),Computer Programming and Formal Systems. North-Holland (1963), 33–70.

  20. McCarthy, J.,Predicate calculus with “undefined” as a truth value. Stanford A. I. memo, Feb., 1979.

  21. McCoy, N. H. andMontgomery, D.,A representation of generalized Boolean rings. Duke Math. J.3 (1937), 455–459.

    Google Scholar 

  22. Mekler, A. H. andNelson, E. M.,Equational bases for if-then-else. SIAM J. Comput.16 (1987), 465–485.

    Google Scholar 

  23. Mitchell, B.,Theory of Categories. Academic Press, 1965.

  24. Stone, M. H.,The theory of representations of Boolean algebras. Trans. Amer. Math. Soc.40 (1936), 37–111.

    Google Scholar 

  25. Taylor, W.,Equational Logic. Houston J. Math.5 (1979), 86pp.

Download references

Author information

Authors and Affiliations

Authors

Rights and permissions

Reprints and permissions

About this article

Cite this article

Manes, E.G. Adas and the equational theory of if-then-else. Algebra Universalis 30, 373–394 (1993). https://doi.org/10.1007/BF01190447

Download citation

  • Received:

  • Accepted:

  • Issue Date:

  • DOI: https://doi.org/10.1007/BF01190447

Keywords

Navigation