Logical specifications for functional programs

  • Theodore S. Norvell
  • Eric C. R. Hehner
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 669)


We present a formal method of functional program development based on step-by-step transformation.

In their most abstract form, specifications are essentially predicates that relate the result of the specified program to the free variables of that program. In their most concrete form, specifications are simply programs in a functional programming language. Development from abstract specifications to programs is calculational.

Using logic in the specification language has many advantages. Importantly it allows nondeterministic specifications to be given, and thus does not force overspecification.


Free Variable Specification Language Functional Program Case Expression Weak Precondition 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. R.J.R. Back. A calculus of refinement for program derivations. Technical Report 54, Department of Computer Science, Åbo Akademi, Finland, 1987.Google Scholar
  2. F.L. Bauer, H. Ehler, A. Horsch, B. Möller, H. Partsch, O. Puakner, and P. Pepper. The Munich Project CIP: Volume II: The Program Transformation System CIP-S. Number 292 in Lecture Notes in Computer Science. Springer-Verlag, 1987.Google Scholar
  3. R.S. Bird. Introduction to the theory of lists. In M. Broy, editor, Logic of Programming and Calculi of Discrete Design, number 36 in NATO ASI Series F. Springer, 1987.Google Scholar
  4. R.S. Bird. A calculus of functions for program derivation. In David A. Turner, editor, Research Topics in Functional Programming, The UT Year of Programming Series. Addison-Wesley, 1990.Google Scholar
  5. Alonzo Church. A formulation of the simple theory of types. J. Symbolic Logic, 5:56–68, 1940.Google Scholar
  6. E.W. Dijkstra. Guarded commands, nondeterminacy, and formal derivation of programs. Communications of the ACM, 18(8):453–457, 1975.Google Scholar
  7. Eric C.R. Hehner. The Logic of Programming. Prentice-Hall International, 1984.Google Scholar
  8. Eric C.R. Hehner. A practical theory of programming. Science of Computer Programming, 14:133–158, 1990.Google Scholar
  9. C.A.R. Hoare. An axiomatic basis for computer programming. Communications of the ACM, 12(10):576–580, 583, 1969.CrossRefGoogle Scholar
  10. Rob Hoogerwoord. The design of functional programs: a calculational approach. PhD Thesis, Technische Universiteit Eindhoven, 1989.Google Scholar
  11. Lambert Meertens. Algorithmics. In J.W. de Bakker, M. Hazewinkel, and J.K. Lenstra, editors, Mathematics and Computer Science, number 1 in CWI Monographs. North-Holland, 1986.Google Scholar
  12. Bernhard Möller. Applicative assertions. In J.L.A. van de Snepscheut, editor, Mathematics of Program Construction, number 375 in Lecture Notes in Computer Science. Springer-Verlag, 1989.Google Scholar
  13. Carroll Morgan. The specification statement. Trans. on Programming Languages and Systems, 10(3):403–419, 1988.Google Scholar
  14. F.L. Morris and C.B. Jones. An early program proof by Alan Turing. Annals of the History of Computing, 6(2):139–143, 1984.Google Scholar
  15. Joseph M. Morris. Programs from specifications. In E. W. Dijkstra, editor, Formal Development of Programs and Proofs, pages 81–115. Addison-Wesley, 1990.Google Scholar
  16. Greg Nelson. A generalization of Dijkstra's calculus. Technical Report 16, Digital Systems Research Center, Palo Alto, CA, U.S.A., April 1987. Also published in Trans. on Programming Languages and Systems, 11(4):517–561, 1989.Google Scholar
  17. D. Hugh Redelmeier. Towards Practical Functional Programming. PhD thesis, University of Toronto, 1984.Google Scholar
  18. David Sands. Complexity analysis for a lazy higher-order language. In Proceedings of the 1989 Glasgow Functional Programming Workshop, Workshops in Computing. Springer-Verlag, 1989.Google Scholar
  19. Harald Søndergaard and Peter Sestoft. Nondeterminism in functional languages. Technical Report 88/18, Department of Computer Science, University of Melbourne, Australia, 1988.Google Scholar
  20. Harald Søndergaard and Peter Sestoft. Referential transparency, definiteness and unfold-ability. Acta Informatica, 27(6):505–518, 1990.Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 1993

Authors and Affiliations

  • Theodore S. Norvell
    • 1
  • Eric C. R. Hehner
    • 1
  1. 1.Department of Computer ScienceUniversity of TorontoCanada

Personalised recommendations