5 research outputs found
Parameter passing in algebraic specification languages
AbstractIn this paper we study the semantics of the parameter passing mechanism in algebraic specification languages. More precisely, this problem is studied for parameterized data types and parameterized specifications. The given results include the extension of the model functor (which is useful for correctness proofs) and the semantic properties of the result of inserting actual parameters into parameterized specifications. In particular, actual parameters can be parameterized and the result is nested parameterized specification. Correctness of an applied (matrix(int)) or a nested (bintree(string())) parameterized specification is shown given correctness of the parts. The formal theory in this paper is restricted to the basic algebraic case where only equations are allowed in the parameter declaration and parameter passing is given by specification morphisms. But we also give the main ideas of a corresponding theory with requirements where we allow different kinds of restrictions in the parameter declaration
Recommended from our members
Algebraic specification : syntax, semantics, structure
Algebraic specification is the technique of using algebras to model properties of a system and using axioms to characterize such algebras. Algebraic specification comprises two aspects: the underlying logic used in the axioms and algebras, and the use of a small, general set of operators to build specifications in a structured manner. We describe these two aspects using the unifying notion of institutions. An institution is an abstraction of a logical system, describing the vocabulary, the kinds of axioms, the kinds of algebras, and the relation between them. Using institutions, one can define general structuring operators which are independent of the underlying logic. In this paper, we survey the different kind of logics, syntax, semantics, and structuring operators that have been used in algebraic specification
Semantics, Implementation and Pragmatics of Clear, a Program Specification Language
Specifications are necessary for communicating decisions and
intentions and for documenting results at many stages of the program
development process. Informal specifications are typically used
today, but they are imprecise and often ambiguous. Formal
specifications are precise and exact but are more difficult to write
and understand. We present work aimed toward enabling the practical
use of formal specifications in program development, concentrating
on the Clear language for structured algebraic specification.
Two different but equivalent denotational semantics for Clear are
given. One is a version of a semantics due to Burstall and Goguen
with a few corrections, in which the category-theoretic notion of a
colimit is used to define Clear's structuring operations
independently of the underlying 'institution' (logical formalism).
The other semantics defines the same operations by means of
straightforward set-theoretic constructions; it is not institutionindependent
but it can be modified to handle all institutions of
apparent interest.
Both versions of the semantics have been implemented. The settheoretic
implementation is by far the more useful of the two, and
includes a parser and typechecker. An implementation is useful for
detecting syntax and type errors in specifications, and can be used
as a front end for systems which manipulate specifications. Several
large specifications which have been processed by the set-theoretic
implementation are presented.
A semi-automatic theorem prover for Clear built on top of the
Edinburgh LCF system is described. It takes advantage of the
structure of Clear specifications to restrict the available
information to that which seems relevant to proving the theorem at
hand. If the system is unable to prove a theorem automatically the
user can attempt the proof interactively using the high-level
primitives and inference rules provided.
We lay a theoretical foundation for the use of Clear in
systematic program development by investigating a new notion of the
implementation of a specification by a lower-level specification.
This notion extends to handle parameterised specifications. We show
that this implementation relation is transitive and commutes with
Clear's structuring operations under certain conditions. This means
that a large specification can be refined to a program in a gradual
and modular fashion, where the correctness of the individual
refinements guarantees the correctness of the resulting program