What is a Good Formal Specification?
Most interesting problems can be specified in many different but equivalent ways. Which of these is to be preferred depends on your sense of style. This paper investigates the choices that arise in writing a. formal specification, and suggests some guidelines that may help authors. For reasons of space, only small examples are given. The tension between clarity and brevity is investigated, and it is suggested that clarity must be preferred, though some suggestions are made for writing specifications that are brief but still clear. The most important point is that, if readers of a specification are to have confidence in its integrity, it must contain formal definitions and informal narrative that correspond closely, so that they can be checked. A natural specification is one where the mathematics follows the form of the English description (and not the other way round). The separation between the form of the mathematics and the English is referred to as the “syntactic gap”.
Unable to display preview. Download preview PDF.
- [Bowen 90]The Z bibliography,J Bowen, 1990, Programming Research Group, Oxford.Google Scholar
- [Codd 70]A Relational Model of Data for Large Shared Data Banks,E F Codd, June 1970, Communications of the ACM, vol 13, no 6, pages 377–387.Google Scholar
- [Gray 88]The Formal Specification of a Small Bookshop Information Sys-tem,February 1988, David Gray, IEEE Transactions on Software Engineering, vol 14, no 2, pages 263–272.Google Scholar
- [Hayes 87]Specification Cases Studies,edited by I C Hayes, 1987, Prentice Hall.Google Scholar
- [Hayes 89]Specifications are not (necessarily) executable,I C Hayes and C B Jones, October 1989, University of Queensland, Australia.Google Scholar
- [Kernighan 74]Elements of Programming Style,B W Kernighan and P J Plauger, 1974, McGraw-Hill.Google Scholar
- [King 87]Specification of a Library System,S King and I H Sorenson, September 1987, Programming Research Group, Oxford.Google Scholar
- [Morgan 87]Unix Filing System,C Morgan and B Sufrin, in [Hayes 87], pages 91–140, also in IEEE Transactions on Software Engineering, 1984, vol 10, no 2, pages 128–142.Google Scholar
- [Spivey 89]The Z Notation: a reference manual, J M Spivey, 1989, Prentice Hall.Google Scholar
- [Sufrin 85]A Tutorial Introduction to Relational Algebra,B Sufrin and J Hughes, 1985, in the Z Handbook, Programming Research Group, Oxford.Google Scholar
- [van Gasteren 88]On the Shape of Mathematical Arguments,A J M van Gasteren, 1988, PhD Thesis, University of Eindhoven.Google Scholar
- [Woodcock 88]Software Engineering Mathematics,J Woodcock and M Loonies, 1988, Pitman.Google Scholar