Skip to main content
Log in

A functional programming approach to the specification and verification of concurrent systems

  • Published:
Formal Aspects of Computing

Abstract

Networks of communicating processes can be viewed as networks of stream transformers and programmed in a lazy functional language. Thus the correctness of concurrent systems can be reduced to the correctness of functional programs. In this paper such correctness is proved formally in theμ-calculus extended with recursion equations for functional programs. Theμ-calculus is chosen since it allows the definition of properties by least fixed points (induction) as well as by greatest fixed points (coinduction), and since greatest fixed points are useful for formalising properties, such as fairness, of infinitely proceeding programs. Moreover, non-deterministic processes are represented as incompletely specified deterministic processes, that is, as properties of stream transformers. This method is illustrated by proving the correctness of the alternating bit protocol.

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. Abramsky, S.: Reasoning about Concurrent Systems. InDistributed Computing, F. J. Chambers, D. A. Duce and G. P. Jones (eds), pp. 307–319, Academic Press, 1984.

  2. Aczel, P.: An Introduction to Inductive Definitions. InHandbook of Mathematical Logic, J. Barwise (ed.), pp. 739–782, North-Holland, 1977.

  3. Aczel, P.: Frege Structures and the Notions of Proposition, Truth and Set. InThe Kleene Symposium, pp. 31–59, North-Holland, 1980.

  4. Augustsson, L.: Compiling Lazy Functional Languages, Part II. PhD thesis, Chalmers University of Technology, 1987.

  5. Brock, J. D. and Ackerman, W. B.: Scenarios: a Model of Non-Determinate Computation. InFormalisation of Programming Concepts, J. Diaz and I. Ramos (eds), LNCS 107, Springer-Verlag, 1981.

  6. Broy, M.: A Fixed Point Approach to Applicative Multiprogramming. InTheoretical Foundations of Programming Methodology, M. Broy and E. M. Schmidt (eds), pp. 565–623, Reidel, Dordrecht, 1982.

  7. Broy, M.: Nondeterministic Data Flow Programs: How to Avoid the Merge Anomaly.Science of Computer Programming, 10, 65–85 (1988).

    Google Scholar 

  8. de Roever, W. P.: On Backtracking and Greatest Fixed Points. InFormal Description of Programming Concepts, E. J. Neuhold (ed.), pp. 621–639, North-Holland, 1978.

  9. Dybjer, P.: Program Verification in a Logical Theory of Constructions. InFunctional Programming Languages and Computer Architecture, J. Jouannaud, (ed.), pp. 334–349, LNCS 201, Springer-Verlag, 1985. Appears in revised form as Programming Methodology Group Report 26, June 1986.

  10. Dybjer, P.: Comparing Integrated and External Logics of Functional Programs.Science of Computer Programming (to appear).

  11. Gordon, M.: HOL: A Proof Generating System for Higher-Order Logic. InVLSI Specification, Verification and Synthesis, G. Birtwistle and X. Subrahmanyan (eds), pp. 73–128, Kluwer Academic Publishers, 1988.

  12. Gordon, M., Milner, R. and Wadsworth, C.:Edinburgh LCF. LNCS 70, Springer-Verlag, 1979.

  13. Hitchcock, P. and Park, D.: Induction Rules and Termination Proofs. InAutomata, Languages, and Programming, M. Nivat (ed.), pp. 225–251, North-Holland, 1973.

  14. Holmström, S.: Hennessy-Milner Logic with Recursion as a Specification Language, and a Refinement Calculus Based on It.Formal Aspects of Computing (to appear).

  15. Johnsson, T.: Compiling Lazy Functional Languages. PhD thesis, Chalmers University of Technology, 1987.

  16. Kahn, G.: The Semantics of a Simple Language for Parallel Processing. InInformation Processing 74, pp. 471–475, North Holland, 1974.

  17. Kahn, G. and MacQueen, D.: Coroutines and Networks of Parallel Processes. InInformation Processing 77, pp. 993–998, North-Holland, 1977.

  18. Keller, R. M.: Denotational Models for Parallel Programs with Indeterminate Operators. InFormal Description of Programming Concepts, E. J. Neuhold (ed.), pp. 337–366, North-Holland, 1978.

  19. Landin, P.: A Correspondence Between ALGOL 60 and Church's Lambda Notation: Part I.CACM, 8(2), 89–101 (1965).

    Google Scholar 

  20. Larsen, K. G.: Proof Systems for Hennessy-Milner Logic with Recursion. InCAAP '88, LNCS 299, Springer-Verlag, 1988.

  21. Milner, R.:Communication and Concurrency. Prentice-Hall, London, 1989.

    Google Scholar 

  22. Park, D.: Fixpoint Induction and Proofs of Program Properties. InMachine Intelligence 5, pp. 59–78, Edinburgh University Press, 1970.

  23. Park, D.: Finiteness is Mu-Ineffable.Theoretical Computer Science, 3, 173–181 (1976).

    Google Scholar 

  24. Park, D.: Concurrency and Automata on Infinite Sequences. InProceedings of the 5th GI-conference on Theoretical Computer Science, P. Deussen (ed.), pp. 167–183, LNCS 104, Springer-Verlag, 1981.

  25. Park, D.: The ‘Fairness’ Problem and Nondeterministic Computing Networks. InFoundations of Computer Science IV.2, pp. 133–161, Mathematical Centre Tracts 159, Amsterdam, 1983.

  26. Paulson, L. C.: The Foundation of a Generic Theorem Prover.Journal of Automated Reasoning 5 (3), pp. 363–397, Klüwer Academic Publishers, 1989.

    Google Scholar 

  27. Turner, D. A.: An Overview of Miranda.Sigplan Notices, December (1986).

Download references

Author information

Authors and Affiliations

Authors

Rights and permissions

Reprints and permissions

About this article

Cite this article

Dybjer, P., Sander, H.P. A functional programming approach to the specification and verification of concurrent systems. Formal Aspects of Computing 1, 303–319 (1989). https://doi.org/10.1007/BF01887211

Download citation

  • Received:

  • Revised:

  • Issue Date:

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

Key words

Navigation