Specifications, Models, and Implementations of Data Abstractions

Abstract We consider the specification and verification of modules in hierarchically structured programs, as proposed by Parnas and Hoare. We argue that a specification for such a module is a set of sentences in some logical language in which the names to be exported by the module appear as nonlogical symbols. We further argue that an implementation of one module in terms of another module is a translation of the nonlogical symbols of the first specification into the language of the second. Equality must also be interpreted. We proposed necessary conditions which any such notion of ‘correct implementation’ ought to satisfy. These criteria provide a basis for judging the logical adequacy of any proposed specification language and definition of implementation. We then study DLP, a specification language obtained by adding uninterpreted procedure symbols to Pratt's first order dynamic logic. We present a definition of ‘implementation’ for DLP, and we show it satisfies these conditions. The main theorem, called the implementation Theorem, extends the Interpretation Theorem from first-order logic to DLP. The proof of this theorem is complicated by the necessity of dealing with modalities, parameters to procedures, interpretations of equality, and interpretations of sorts as tuples.

[1]  Lawrence Snyder,et al.  On the Many Facets of Lists , 1977, Theor. Comput. Sci..

[2]  Joseph E. Stoy,et al.  Denotational Semantics: The Scott-Strachey Approach to Programming Language Theory , 1981 .

[3]  Edsger W. Dijkstra,et al.  A Discipline of Programming , 1976 .

[4]  Michael D. Rychener Control requirements for the design of production system architectures , 1977 .

[5]  Alfred Tarski,et al.  Introduction to Logic and to the Methodology of Deductive Sciences , 1943 .

[6]  Ellis Horowitz,et al.  Abstract data types and software validation , 1978, CACM.

[7]  Hartmut Ehrig,et al.  Algebraic Implementation of Abstract Data Types: Concept, Syntax, Semantics and Correctness , 1980, ICALP.

[8]  David R. Musser A Proof Rule for Functions , 1977 .

[9]  Jack Belzer,et al.  Encyclopedia of Computer Science and Technology , 2002 .

[10]  Claus H. Correll Proving programs correct through refinement , 1978 .

[11]  Donald E. Knuth,et al.  The Early Development of Programming Languages. , 1977 .

[12]  Herbert B. Enderton,et al.  A mathematical introduction to logic , 1972 .

[13]  Lawrence Robinson,et al.  Proof techniques for hierarchically structured programs , 1977, CACM.

[14]  Stephen N. Zilles,et al.  Specification techniques for data abstractions , 1975 .

[15]  Tony Hoare,et al.  Hierarchical Program Structures , 1972 .

[16]  Craig Schaffert,et al.  Abstraction mechanisms in CLU , 1977, Commun. ACM.

[17]  Daniel J. Lehmann,et al.  Data types , 1977, 18th Annual Symposium on Foundations of Computer Science (sfcs 1977).

[18]  Vaughan R. Pratt,et al.  SEMANTICAL CONSIDERATIONS ON FLOYD-HOARE LOGIC , 1976, FOCS 1976.

[19]  Mary Shaw,et al.  An introduction to the construction and verification of Alphard programs , 1976, ICSE '76.

[20]  D. Hofstadter,et al.  Godel, Escher, Bach: An Eternal Golden Braid , 1979 .

[21]  Andrzej Salwicki On the algorithmic theory of stacks , 1980, Fundam. Informaticae.

[22]  S. Maclane,et al.  Categories for the Working Mathematician , 1971 .

[23]  David Harel,et al.  Nondeterminism in logics of programs , 1978, POPL.

[24]  David Lorge Parnas,et al.  A technique for software module specification with examples , 1972, CACM.

[25]  Joseph R. Shoenfield,et al.  Mathematical logic , 1967 .

[26]  Samuel N. Kamin Final data type specifications: a new data type specification method , 1980, POPL '80.

[27]  Mitchell Wand,et al.  Final Algebra Semantics and Data Type Extensions , 1979, J. Comput. Syst. Sci..

[28]  Edsger W. Dijkstra,et al.  Notes on structured programming , 1970 .

[29]  Lawrence Robinson,et al.  An example of hierarchical design and proof , 1978, CACM.

[30]  Rohit Parikh A decidability result for a second order process logic , 1978, 19th Annual Symposium on Foundations of Computer Science (sfcs 1978).