The DisCo Language and Temporal Logic of Actions

Size: px
Start display at page:

Download "The DisCo Language and Temporal Logic of Actions"

Transcription

1 The DisCo Language and Temporal Logic of Actions (September 1990) Hannu-Matti Järvinen and Reino Kurki-Suonio Tampere University of Technology Software Systems Laboratory Box 527, SF Tampere, Finland Abstract DisCo is a specification language for reactive systems, based on the execution model of joint actions. Its main constructs for safety specification are described in this paper in terms of temporal logic of actions. The principles of such a translation are relatively straightforward, and DisCo can therefore be thought of as a language for constructing specifications in this logic. Refinement and modular combination of specifications are supported by constructions that are less general than what would be semantically necessary, but their correctness is syntactically guaranteed, and they are suited for developing design-oriented, executable specifications. Keywords: executable specifications, joint actions, modularity, reactive systems, superposition 1. Introduction The notion of joint action systems was developed in [BK83, BK84, BK88a, BK88b] to describe distributed systems and to support a rigorous methodology for their design. Based on this work and on case studies, an experimental language DisCo (Distributed Cooperation) was designed for the specification and design of reactive systems [KK88, KJ89, JK90a, JKSS90, Ku90]. Examples of related approaches are Unity [CM88] and the relational notation of [LS90]. Unlike in Unity, no special logic or proof system was proposed for joint action systems. Instead, the ideas were formulated in such a way that temporal logic [MP83, Pn86] could be applied. Later, the joint action approach has also been investigated in the framework of refinement calculus [Ba90, BK90]. Although well suited for terminating distributed computations, this framework has drawbacks in connection with reactive systems, where termination is basically indistinguishable from infinite stuttering. Recently, Lamport has put forward a temporal logic of actions [La90], which offers a simple alternative for reasoning about reactive systems. In this paper we investigate how Dis- Co relates to this logic, i.e., how DisCo can be used as a language for constructing systems that are understood in terms of this logic. For simplicity, we consider safety properties only and omit liveness. Like programming languages, DisCo has notions that help the designer to express his intentions in a way that supports the construction of specifications and improves their readability. In terms of logic these introduce simple invariants and theorems, the proofs of which are embedded in syntax (or static semantics, as it is sometimes called). Typical examples are data types, structuring of DisCo objects, and preservation of safety properties in modular combination of systems.

2 - 2 - On the other hand, a language may be restrictive in disallowing certain constructions that would be easy to express in logics. Such restrictions are found to be small in DisCo, and they can be justified by the goal to construct design-oriented, executable specifications. The structure of the paper is as follows. Safety specification in temporal logic of actions is briefly introduced in Section 2, and in Section 3 we outline how DisCo specifications can be understood in these terms. An example that illustrates this correspondence and the modularity constructs of DisCo is given in Section 4; a more general discussion of the topics is postponed to Section 5. The paper ends with concluding remarks in Section Safety Specification in Temporal Logic of Actions Temporal logic of actions (TLA) [La90] deals with behaviors σ, defined as infinite sequences of states, σ = (s 0, s 1,...). Each state s i is a collection of values of so-called program variables, denoted collectively by u in the following. A pair of consecutive states (s i, s i+1 ) in a behavior is called a transition. If v denotes a subset of program variables, and states s i and s i+1 do not differ in the values of v, transition (s i, s i+1 ) is called a v stuttering transition. A state predicate P(u), which involves program variables u, is true for a behavior σ if it holds when u is replaced by the values of the program variables in the initial state s 0 of σ. The temporal logic formula P(u) is defined to be true if P(u) holds for all suffixes of σ, including σ itself. An action A(u, u') is a boolean-valued expression containing both primed and unprimed state variables. Transition (s i, s i+1 ) is an A transition if A(u, u') holds when u and u' are replaced by the values of the program variables in states s i and s i+1, respectively. If v is a subset of u, and A(v, v') is an action, then [A] v is defined to be true for a behavior σ, if each transition in σ is either an A transition or a v stuttering transition. (If A involves only unprimed program variables, this reduces to A for the state predicate A.) The specification of a reactive system can now be given as a formula that restricts the behaviors that the system is allowed to generate. A safety specification Φ is a formula Φ = INIT [A] u that allows any behavior where the initial state satisfies the state predicate INIT, and all transitions are either A transitions or u stuttering transitions. Since no liveness conditions are given, any finite prefix of a behavior satisfying Φ can be completed by infinite u stuttering to another behavior that also satisfies Φ. Satisfaction of Φ requires a system to possess the state variables u of Φ. In addition it may have other state variables with arbitrarily changing values. (For simplicity we ignore the situation where internal program variables are hidden in Φ by quantification, as defined in [AL88].) To allow easier manipulation of the action part A of Φ, it is often given as a disjunction of a collection of individual actions, A = i A i. 3. Specifications in DisCo DisCo specifications deal with similar infinite behaviors as TLA. Therefore, their meaning can be easily described in terms of this logic. For simplicity we omit the liveness part of also DisCo.

3 System State System state is partitioned in DisCo into a collection of local states of objects, each object x being an instantiation of some class c, x c. No global naming is provided for objects, which can therefore be identified only on the basis of their classes and local states. Classes are declared and named individually, and hence their number is finite. All objects are assumed to be instantiated in the initial state. Instead of explicit initialization, legal initial states are determined by initial conditions. When a DisCo specification is executed, a concrete initialization is given that has to satisfy these initial conditions. For each class the number of objects is not allowed to change within an execution. This imposes no essential restriction, since the number of objects need not be finite. The local states of objects are structured as hierarchical finite-state systems, with variables associated with states. To be more specific, the name of a class denotes a unique outermost state in which objects of this class always reside, and, for each state one can give zero or more declarations for variables and internal states. Each state declaration introduces a finite collection of mutually exclusive alternatives. When several state declarations are given within the same state, they introduce parallel finite-state systems. In terms of TLA program variables we can interpret DisCo class declarations as follows. Each state declaration introduces an array of program variables u[i], where the name u uniquely identifies the place of the declaration within the state hierarchy, i is an index that identifies an object of the associated class, and the type of u[i] is an enumeration type ranging over the alternative state names in the declaration. (The range ind c of index i for a class c is determined by the initial state.) Similarly, each variable declaration in DisCo introduces an array of program variables u[i] of the types of these declarations, with u identifying the place and variable name of the declaration. Obviously, any state predicate p in DisCo, referencing the local states of some objects, can be transliterated into a TLA state predicate P involving the corresponding program variables. (We adopt the convention of using lower and upper case letters to denote corresponding entities in DisCo and TLA.) In particular, the initial conditions of a DisCo system can be transliterated into an initial state predicate INIT. Compared to this interpretation in terms of TLA program variables, the syntactic form of DisCo class declarations also introduces a number of invariants for objects. For instance, DisCo variables are always typed, and an object cannot be in an internal state unless it is also in the state within which this internal state has been declared. Furthermore, each reference to a variable introduces an implicit predicate about the object being in the associated state; this often allows more concise expression of conditions Actions Apart from syntactic details, each action a is given in DisCo in terms of optional parameters p i t i, i ind p, a finite collection of participants x j c j, j ind x, an enabling guard g, and a body b. Parameters p i are values that are specified by their types t i, participants x j are objects specified by their classes c j, the guard g is a predicate involving the parameters and the local states of the participants (and possibly also other parts of the system state by quantification over objects), and b is a sequence of assignments and state transition statements (which are conceptually also assignments) describing how the local states of the participants are modified. In TLA this corresponds to an action A of the form

4 - 4 - A = i ind p, j ind x : p i t i, k j ind cj : G B. Here G is a transliteration of the guard g, where each participant x j c j is identified by its index k j ind cj. As the body b is a non-looping sequence of assignment statements, it determines a unique mapping from the old local states of the participants to their new states, which can be directly computed. Its transliteration into an expression with primed and unprimed program variables is denoted here by B. For a DisCo system with initial condition init and actions a i, the corresponding safety specification in TLA is then INIT [ i A i ] u, where INIT and A i correspond to init and a i, respectively, and u is the collection of program variables Superposition Construction of modular DisCo specifications is associated with superposition, a technique with which a system is modified by extending its state and by transforming its actions to deal with these extensions. Action guards may also be strengthened in this connection. Superposition is supported by language facilities in DisCo, with static semantics that guarantees preservation of safety properties. Let Φ = INIT [ i A i ] u be the safety formula corresponding to a DisCo system of which a new system is to be derived by superposition. For simplicity we assume that a stuttering action is explicitly given as one of the actions A i ; all other actions A i are assumed to correspond to unique DisCo actions a i. DisCo language rules now guarantee that the formula for the system that results from superposition has the form Φ' = INIT ' [ i A' i ] v, where INIT ' INIT, u v, and each A i ' is a disjunction j A' i, j where A' i, j A i for all i and j. Obviously Φ' Φ, i.e., all safety properties of the original system are preserved. Although the identity of actions is not significant in TLA, it plays a role in the DisCo rules that guarantee the correctness of superposition steps. Each A' i, j corresponds in the resulting DisCo system to a separate action a' i, j, which is called a refinement of a i. This refinement relation is syntactically determined, and a' i, j may have more parameters and participants than a i, its guard may be stronger, and its body may update state components that were not included in the original system. The new state components are either extensions to old objects or new objects belonging to new classes Combined Systems Structurally DisCo specifications are composed of modules. Modules may use other modules by importing them non-cyclically, and each module determines a complete specification. Classes of module M can be used in another module M' only if M has been imported (directly or indirectly) by M'. Otherwise, the same name denotes different things in different modules.

5 - 5 - Upper Lower High Mid When more than one module is imported, naming of classes and actions is first made unique by explicit renaming. Then the systems are combined into a single system, which can subsequently be modified by superposition in the way described above. When systems are combined, the refinement history of their actions becomes significant. In order to describe this, some terminology is needed. If system S' has been obtained of S either by superposition or by combining S with some other systems, then S is called an immediate predecessor of S'. The general predecessor relation is the transitive closure of this. If action a' is obtained of a either by refinement (as described above) or by combining it with other actions (in a way to be described below), then a is called an immediate ancestor of a'. The general ancestor relation is the transitive closure of this. Two actions in different systems are called compatible, if all their ancestors in all common predecessor systems are the same, which is a syntactic property. Let Φ j = INIT j [ i A j i] uj, j = 1,..., n be the safety formulae for n DisCo systems to be combined. We assume that the names of the state variables in Φ j have already been made unique. We also assume that stuttering actions have been explicitly included in each formula Φ j. The safety formula for the combined system is then where Figure 1. Derivation of a specification. Φ = INIT [ (A 1 i1... A n in)] u, INIT = j INIT j, u = j u j, and indices i 1,..., i n run through all combinations where the corresponding DisCo actions a 1 i1,..., a n in are mutually compatible. Each such combination A 1 i1... A n in corresponds in the combined DisCo system to a single action that has all a 1 i1,..., a n in as its ancestors. Notice that the weakest TLA formula that implies all component specifications Φ j is j Φ j, which could be expressed similarly to Φ, with indices i 1,..., i n running through all possible combinations. Obviously, Φ is in general stronger than this, Φ j Φ j. 4. Example High_and_Mid In this section we outline an example that has been considered in more detail elsewhere [JK90b]. Emphasis will here be on how DisCo systems are combined and refined.

6 - 6 - enter_mid exit_mid sender_mid send_mid channel_mid receive_mid receiver_mid Figure 2. Objects and actions in the upper interface. The example describes a simple protocol with a layered structure. The modularity in deriving this specification is illustrated in Figure 1, the lines and arrows indicating system combination and superposition. Upper is a module that describes communication at a level of abstraction where reliable communication can be assumed. Lower is an otherwise similar module, but its channels may also loose messages. High is an application module that makes use of the reliable communication services provided by Upper. Mid is an implementation of Upper by using the unreliable communication facilities of Lower. Finally, High_and_Mid is a module formed by combining both High and Mid; it describes the complete behavior of the application and the communication system, including both the underlying unreliable channels and the abstraction of the reliable channel Upper Interface Module Upper describes the behavior of Mid as seen from the environment, i.e., it describes error-free simplex point-to-point communication between two parties. In addition, since all DisCo systems are closed, i.e., contain a description of environment behavior, it needs to describe unrestricted environment behavior. Three object classes are introduced: class channel_mid is state idle, busy(data: message); initially idle; class sender_mid(n: integer; to: channel_mid) is assert n > 0 to null; queue: sequence message; initially queue = <>; class receiver_mid(n: integer; from: channel_mid) is assert n > 0 from null; queue: sequence message; initially queue = <>; assert c: channel_mid:: size(s: sender_mid s.to = c) = size(r: receiver_mid r.from = c) = 1; A channel_mid object represents a reliable channel between sender and receiver objects. It has two exclusive states: either it is idle, which is the initial state, or it is busy with a message that is kept in the associated variable data. The parameter notation for data indicates that its value cannot be changed without exiting and re-entering this state. At this point it should be pointed out that channel_mid objects should, in fact, be understood as hidden internal variables in this specification, corresponding to quantified program variables in TLA. Notice also that a higher-level specification could easily be given without such objects, and Upper could then be understood as a refinement where their introduction is based on a design decision. Each sender_mid has two parameters whose values are set at initialization: n is the capacity of the associated buffer, and to is the associated channel. In addition, it has a variable

7 - 7 - containing the buffer itself, i.e., a sequence of items of type message. Correspondingly, each receiver_mid is associated with information on its buffer size, the associated channel, and the contents of the buffer. All buffers are initialized as empty. The assertions state that each sender and receiver has a buffer and is associated with an existing channel, and that each channel is point-to-point between one sender and one receiver. No restrictions are given on their number. Figure 2 illustrates the case where only one channel exists. In terms of TLA these class declarations would introduce program variables, so that each state declaration and each variable declaration (including state parameters) would correspond to a separate array, with subscripts identifying the existing objects. Assertions and initial conditions give the initial conditions for these TLA program variables. Four actions are introduced (in Figure 2 they are given as arrows indicating the direction of message flow between participants): action enter_mid(m: message) by sm: sender_mid is when size(sm.queue) < sm.n do sm.queue := sm.queue & <m>; action send_mid(m: message) by sm: sender_mid; cm: channel_mid is when sm.to = cm size(sm.queue) > 0 cm.idle m = head(sm.queue) do cm.busy(m); sm.queue := tail(sm.queue); action receive_mid(m: message) by rm: receiver_mid; cm: channel_mid is when rm.from = cm size(rm.queue) < rm.n m = cm.busy.data do rm.queue := rm.queue & <m>; cm.idle; action exit_mid(m: message) by rm: receiver_mid is when size(rm.queue) > 0 m = head (rm.queue) do rm.queue := tail(rm.queue); Action enter_mid describes an interaction where a message is accepted to a sender_mid object. Parameter m denotes an arbitrary message that is generated nondeterministically in this action. The action is enabled if the buffer capacity has not been exhausted, and its effect is to append the message to this buffer. The type message is left arbitrary, but it can be specialized to concrete message types later, as will be shown below. Whenever there are messages in a sender buffer and the associated channel is idle, action send_mid puts the next message into the channel. In order to allow easy reference to the message in later refinements of this action, it is given as an action parameter, even though its value is uniquely determined by the guard. The arrow in the action body denotes a state transition statement where the channel enters state busy, with the value of its state parameter set to the message. Correspondingly, whenever there is a message in a channel and the buffer of the associated receiver is not full, action receive_mid appends the message to this buffer and causes an associated state transition in the channel. The message is again given as an action parameter in order to allow easy reference to it later.

8 - 8 - sender_high receiver_high enter_mid send_high receive_high exit_mid send_mid receive_mid sender_mid channel_mid receiver_mid Figure 3. Objects and actions in High, with imported components drawn in grey. Finally, action exit_mid describes an interaction where a transmitted message is given to the environment in the receiving end. Again, the message is a parameter whose value is uniquely determined by the guard. Correspondence to TLA actions should be obvious. As explained in Section 3.2, parameters and participants correspond to existentially quantified variables, guards are predicates on the source state of a transition, and bodies correspond to predicates involving both source and target states. With these class and action declarations, the system is complete in the sense that it can be simulated. Like all DisCo systems, it describes the behavior of both the system and its environment at a selected level of abstraction Application Layer As a simple application of this communication system we consider a situation where one sender is sending consecutive integers to a receiver that keeps computing their sum. Module Upper is imported, and the application is added to the system by superposition. In this process the type message is specialized into an integer, as required by the application. This means that such refinements are generated of enter_mid and exit_mid where the messages are single integers. These refinements are renamed as send_high and receive_high, respectively. The old names enter_mid and exit_mid remain to denote such implicit refinements where the message type has not been specialized. New class definitions are introduced to describe the sender and receiver objects of the application. Both need knowledge about the object with which to communicate in Upper. In addition, the sender needs a variable for the integers to be generated, and the receiver needs one for the sum to be computed: class sender_high(sm: sender_mid) is assert sm nil; i: integer; initially i = 0; class receiver_high(rm: receiver_mid) is assert rm nil; sum: integer; initially sum = 0; assert size(s: sender_high) = size(r: receiver_high) = 1 s: sender_high, r: receiver_high:: s.sm.to = r.rm.from; No new actions are introduced, but send_high and receive_high are refined as follows:

9 - 9 - enter_low exit_low Figure 4. Objects and actions in the lower interface. refined send_high by... sh: sender_high is -- derived of enter_mid(m) by sm where m = <value: integer> when... sh.sm = sm m.value = sh.i do... sh.i := sh.i + 1; refined receive_high by... rh: receiver_high is -- derived of exit_mid(m) by rm where m = <value: integer> when... rh.rm = rm do... rh.sum := rh.sum + m.value; Ellipses are a notation denoting parts taken from imported actions; double hyphens begin comments. The sender of the application level is added as a participant to send_high. The value to be communicated is restricted to be the value of i within sender_high, and variable i is also incremented. Correspondingly, the receiver of the application level is added to participate in receive_high, which is also refined to update the sum. Figure 3 indicates the structure of High, including the imported upper interface. The nonspecialized actions enter_mid and exit_mid are still available for other specializations. This means that the same channel could be used for other purposes also. Since different versions of enter_mid and exit_mid only deal with the associated specializations of the message type, there is no danger of different kinds of messages to be confused. Actions send_mid and receive_mid, on the other hand, do not distinguish between such specializations, and they transmit all messages regardless of their structures. In terms of TLA, the new class declarations introduce new program variables, the new assertions strengthen the initial condition, and action refinements strengthen the TLA actions Lower Interface Module Lower, which is illustrated in Figure 4, is similar to Upper, except that there is no buffering, and messages may be lost arbitrarily by a drop action. Since its actual representation in DisCo is unimportant for the purposes of this paper, it will be omitted Mid-Layer sender_low channel_low receiver_low send_low drop receive_low Module Mid demonstrates the refinement of a combination of two independent systems. Its purpose is to implement Upper in terms of Lower. The two systems are first combined, and this combination is then refined by superposition. To achieve reliable communication, separate channels of Lower are used for actual messages and for acknowledgments, and alternating bits are used to distinguish between consecutive messages. The resulting system still contains the reliable channel, but this has become virtual in the sense that it can be optimized away.

10 sender_high send_high High receive_high receiver_high enter_mid Upper exit_mid sender_mid send_mid channel_mid receive_mid receiver_mid Mid send_msg receive_ack receive_thru_low receive_msg send_ack enter_low exit_low Lower exit_low enter_low sender_low receiver_low receiver_low sender_low send_low receive_low receive_low send_low channel_low channel_low drop drop Figure 5. Objects and actions in High_and_Mid, with projections to all imported systems. Rather than giving the details of Mid in DisCo, we illustrate it in Figure 5 together with High, with which it forms the combined system High_and_Mid of Figure 1. The instantiation of Lower in Mid contains two (unreliable) channels, one for the actual messages (together with alternating bits), the other for acknowledgments (consisting of alternating bits only). The instantiation of Upper contains just one (reliable) channel. Since Upper and Lower have no common predecessor systems, all their actions are pairwise compatible. Therefore, the combined system would include all possible combined actions, including the ones where the stuttering action is taken from one component. According to the conventions of DisCo, all combinations with stuttering actions are always automatically included, but combinations of independent actions need be explicitly requested. In the following we comment briefly on all the actions of Mid shown in Figure 5. Action send_mid is a refinement that also stores the message in a special one-message buffer that is added to sender_mid. Once the message is here, action send_msg, which is a refinement of enter_low, gives it to sender_low. After this, actions send_low and receive_low may transmit it to the corresponding receiver_low, but it may also be lost in a drop action. As long as no acknowledgment is received, this procedure is repeated. Action receive_thru_low is a combination of receive_mid and exit_low. It becomes enabled once the same message is both in channel_mid and in the receiver_low, and it accepts the message to receiver_mid as defined by the functionality of receive_mid. Action receive_msg is another (non-combined) refinement of exit_low, which removes redundant messages that are obtained through the unreliable channel. The non-combined action receive_mid has been removed by strengthening its guard to be identically false.

11 Once a new message has been received in receive_thru_low, another refinement of enter_low, send_ack, becomes enabled for an acknowledgment, which is eventually transmitted by send_low and receive_low to the corresponding receiver_low, from where receive_ack (a refinement of exit_low) takes it to sender_mid making this ready for the next message. Notice that the reliable channel is still present in the system, even though the purpose was to implement it in terms of two unreliable channels. With suitable invariants it can be proved, however, that channel_mid has effectively turned into a ghost variable that could be deleted. Since no proof system is assumed in the language, the removal of variables is not supported by any of its constructions. Therefore, channel_mid remains there, and is still available as an abstraction in system animation. 5. Discussion DisCo is a language that draws from the tradition of programming language design. Calling it a specification language is justified by features that do not allow direct implementation, or cannot be automatically implemented in a distributed fashion. The main instances of such features are unboundedly nondeterministic action parameters, fairness conditions (which were omitted here), and non-separable guards, i.e., guards that do not directly allow distributed evaluation. In such respects DisCo is at a slightly higher level of abstraction than LOTOS [BB87], and clearly further away from programming languages than IP [FF90]. However, DisCo specifications are executable in the sense that their simulation is possible with some interactive guidance from the user. Under certain conditions they can be automatically compiled into distributed programs, which allows to use a transformational approach in system development. TLA, on the other hand, is a logic for expressing and proving properties of reactive systems. A close relationship exists between it and DisCo, in the sense that DisCo can be easily understood in its terms. Therefore, TLA is a natural vehicle for expressing properties of DisCo systems and for reasoning about them. Without an associated logic DisCo is actually insufficient for such purposes, and in this respect it is at the level of programming languages. As argued by Lamport [La90], logic is by itself sufficient for specifying reactive systems. As a language for specification and design, DisCo goes beyond the needs of pure specification. Logically this may seem like introducing implementation-oriented details that do not belong to specifications. Channel objects in the above example illustrate design decisions that would not be needed in a pure specification. We support the view, however, that formal specification should not be completely separated from design, and that a specification language should therefore contain facilities that are useful for expressing the designer's intentions and for supporting structured development of systems. The crucial questions are, of course, whether such facilities obscure the main issues by making reasoning more difficult, whether they restrict specifications unnecessarily, and whether they lead to too early commitment to certain implementation decisions. For DisCo, the first question is answered by its close relationship to TLA; the two other questions will be addressed below.

12 Structuring of State System state is partitioned in DisCo into objects of given classes. No variables can be introduced without associating them with objects. Logically such a partitioning would not be needed, and it is not present in the more general work on joint actions [BK83, BK84, BK80a, BK80b, BK90]. Its essential effect is to augment each action with an existential quantification over all objects of certain classes. Obviously this has no effect on the expressiveness of the language, but it has proved useful in supporting a style where artificial indexing and dependence on scaling factors are easily avoided. In case studies this has improved the readability and reusability of specifications. In using DisCo for design, the convention is useful that the local state of one object will not be distributed to several processes. Refinement by superposition or by other kinds of transformations can then be used to achieve a form that allows natural implementation with this assumption. Even though partitioning into objects then reflects a design decision, it does not complicate logical reasoning. In contrast to process-oriented languages like LOTOS [BB87] and IP [FF90], DisCo specifications make no distinction whether an object represents an active agent or a passive data structure. Notice that such a distinction is analogous to specifying whether a sequential program should be compiled into active code or interpreted in a passive internal representation. A notion of processes, which makes this distinction, has an effect on reasoning, and it also means a stronger commitment or bias for implementations. Some notion of this kind is, however, helpful in the visualization and animation of executable specifications, but objects are in this respect as good as processes. Within objects, DisCo combines facilities that are adopted from high-level programming languages and from hierarchical state-transition systems. Typical examples are declaration of typed variables with scopes restricted to certain states. Logically these facilities introduce invariants that could alternatively be formulated as simple theorems. Experience with programming languages shows that such facilities are desirable for expressing the intentions of the designer, and that they can improve the readability of specifications Actions and Modularity The body of each action is given in DisCo in terms of deterministic assignments. (A state transition statement can be understood as a syntactic variant of an assignment.) Since loops are disallowed, bodies can easily be converted into predicates on source and target states. Therefore, this difference between DisCo and TLA is only superficial. At first sight it might seem that determinism in action bodies would restrict the expressiveness of DisCo. However, because of the facility for action parameters, no generality is lost. In fact, for a given relation between old and new states, a DisCo action can always be written so that the new state is given by parameters, and the relation is expressed in the guard, in which case the body becomes trivially deterministic. From the viewpoint of pure specifications the separation of nondeterministic parameters from deterministic bodies has no significance. However, in the development of executable specifications this does make a difference. Deterministic bodies are directly executable, while nondeterministic choices may need guidance from the user. Action parameters provide convenient handles for expressing such choices and also for restricting them with superposition.

13 Compared to actions in TLA there is, however, one restriction: a single DisCo action can involve only a bounded number of individual changes in the state. This we do not regard as a severe limitation for reactive systems, where atomic state changes tend to be small. As a syntactic refinement mechanism superposition is obviously not as general as a semantically defined data refinement [Ba90, BK90]. The price of a more general mechanism would be a need for an associated proof system. The main limitation of superposition is that it can only extend the state but cannot at the same time remove old state components, which was also demonstrated by the above example. As for modularity, it was already stated in Section 3.4 that a combined specification in DisCo is, in general, stronger than the weakest specification that would imply all the component specifications. What is achieved, however, is that action guards and bodies in the combined specification can be directly constructed from those in the components. For practical design we consider this kind of simplicity to be more important than the minimality of specifications. 6. Concluding Remarks The basic notions and constructs of DisCo have been described in temporal logic of actions. Due to the simple execution model, and to the small number of basic notions, this is relatively straightforward. In fact, DisCo may be thought of as a TLA-oriented programming language, with an object-oriented structuring of state, and with syntactic support for modularity and readability. Similarly to high-level programming languages it guarantees syntactically whatever is possible, without relying on automated proof systems. Its constructions for superposition and combination of specifications are therefore less general than what would be semantically necessary. It also contains language facilities that are superfluous from a purely logical viewpoint, but which can be justified by their support to the design of reusable, executable specifications. In this paper we have omitted all liveness properties. This was not because of any fundamental differences in dealing with them. In fact, both DisCo and TLA use fairness with respect to actions. Preservation of liveness properties is, however, more difficult to guarantee in modular construction of specifications, and cannot, in general, be treated syntactically. For simplicity, we have also omitted the DisCo notion of inheritance, which allows somewhat more general combination of specifications than what was discussed here, and is suited for certain situations of bottom-up development. Acknowledgments The joint action approach was developed together with Ralph Back from Åbo Akademi. Research on its use as a basis for a practical specification language has been carried out in project DisCo at Tampere University of Technology. This ongoing project is part of the FINSOFT programme of the Technology Development Centre of Finland (TEKES), and is supported by four industrial partners. We are also indebted to Leslie Lamport for enlightening discussions on whether programming languages support or confuse the construction of specifications.

14 References [AL88] Abadi, M., Lamport, L., The existence of refinement mappings. Research Report 29, Digital Systems Research Center, To appear in Theoretical Computer Science. [Ba90] Back, R.J.R., Refinement calculus II: parallel and reactive programs. In Stepwise Refinement of Distributed Systems: Models, Formalisms, Correctness, LNCS 430, Springer-Verlag 1990, [BK83] Back, R.J.R., Kurki-Suonio, R., Decentralization of process nets with a centralized control. Distributed Computing 3 (1989), An earlier version in 2nd ACM SIGACT-SIGOPS Symposium on Principles of Distributed Computing, Montreal, Canada, Aug. 1983, [BK84] Back, R.J.R., Kurki-Suonio, R., A case study in constructing distributed algorithms: distributed exchange sort. In Proc. Winter School on Theoretical Computer Science, Lammi, Finland, Jan. 1984, Finnish Society of Information Processing Science, [BK88a] Back, R.J.R., Kurki-Suonio, R., Serializability in distributed systems with handshaking. In Automata, Languages and Programming (Ed. T. Lepistö and A. Salomaa), LNCS 317, Springer- Verlag 1988, [BK88b] Back, R.J.R., Kurki-Suonio, R., Distributed cooperation with action systems. ACM Trans. Programming Languages and Systems 10, 4 (Oct. 1988), [BK90] Back, R.J.R., Kurki-Suonio, R., Superposition and fairness in reactive system refinement. To be presented at the 5th Jerusalem Conference on Information Technology, Jerusalem, Oct [BB87] Bolognesi, T., Brinksma, E., Introduction to the ISO specification language LOTOS. Computer Networks and ISDN Systems 14, (1987), [CM88] Chandy, K.M., Misra, J., Parallel Program Design: A Foundation. Addison-Wesley, [FF90] Francez, N., Forman, I.R., Interacting processes: a language for coordinated distributed programming. To be presented at the 5th Jerusalem Conference on Information Technology, Jerusalem, Oct [JK90a] Järvinen, H.-M., Kurki-Suonio, R., The DisCo language. Tampere University of Technology, Software Systems Laboratory, Report 8, [JK90b] Järvinen, H.-M., Kurki-Suonio, R., DisCo specification language: marriage of actions and objects. Manuscript, [JKSS90] Järvinen, H.-M., Kurki-Suonio, R., Sakkinen, M., Systä, K., Object-oriented specification of reactive systems. Proc. 12th International Conference on Software Engineering, Nice, France, March 1990, IEEE Computer Society Press, [Ku90] Kurki-Suonio, R., Operational specification with joint actions: serializable databases. To appear in Distributed Computing. [KJ89] Kurki-Suonio, R., Järvinen, H.-M., Action system approach to the specification and design of distributed systems. In Proc. Fifth International Workshop on Software Specification and Design. ACM Software Engineering Notes 14, 3 (May 1989), [KK88] Kurki-Suonio, R., Kankaanpää, T., On the design of reactive systems. BIT 28, 3 (1988), [LS90] Lam, S.S., Shankar, A.U., A relational notation for state transition systems. IEEE Trans. on Software Engineering 16, 7 (July 1990), [La90] Lamport, L., A temporal logic of actions. Research Report 57, Digital systems Research Center, [MP83] Manna, Z., Pnueli, A., How to cook a temporal proof system for your pet language. In Proc. 10th ACM Symposium on Principles of Programming Languages, Austin, Texas, Jan. 1983, [Pn86] Pnueli, A., Applications of temporal logic to the specification and verification of reactive systems: a survey of current trends. In Current Trends in Concurrency (Ed. J.W. de Bakker, W.-P. de Roever and G. Rozenberg), LNCS 224, Springer-Verlag 1986,

Proving the Correctness of Distributed Algorithms using TLA

Proving the Correctness of Distributed Algorithms using TLA Proving the Correctness of Distributed Algorithms using TLA Khushboo Kanjani, khush@cs.tamu.edu, Texas A & M University 11 May 2007 Abstract This work is a summary of the Temporal Logic of Actions(TLA)

More information

Separating Product Variance and Domain Concepts in the Specification of Software Product Lines

Separating Product Variance and Domain Concepts in the Specification of Software Product Lines Separating Product Variance and Domain Concepts in the Specification of Software Product Lines Pertti Kellomäki Software Systems Laboratory, Tampere University of Technology P.O. Box 553, FIN-33101 Tampere,

More information

In this paper we describe some aspects of a theory that gives a simple basis for operational models of reactive systems. It allows rigorous reasoning

In this paper we describe some aspects of a theory that gives a simple basis for operational models of reactive systems. It allows rigorous reasoning Real Time in a TLA-Based Theory of Reactive Systems Reino Kurki-Suonio and Mika Katara Software Systems Laboratory Tampere University of Technology P.O. Box 553, FIN-33101 Tampere, Finland e-mail: freino.kurki-suonio,

More information

Leslie Lamport: The Specification Language TLA +

Leslie Lamport: The Specification Language TLA + Leslie Lamport: The Specification Language TLA + This is an addendum to a chapter by Stephan Merz in the book Logics of Specification Languages by Dines Bjørner and Martin C. Henson (Springer, 2008). It

More information

Composing Fair Objects

Composing Fair Objects Composing Fair Objects G.W. Hamilton School of Computer Applications Dublin City University Ireland hamilton@compapp.dcu.ie D. Méry Université Henri Poincaré Nancy France mery@loria.fr J.P. Gibson Department

More information

A UNITY-based Formalism for Dynamic Distributed Systems

A UNITY-based Formalism for Dynamic Distributed Systems A UNITY-based Formalism for Dynamic Distributed Systems Daniel M. Zimmerman Computer Science 256-80 California Institute of Technology Pasadena, California 91125 USA dmz@cs.caltech.edu Abstract We describe

More information

Specifying and Proving Broadcast Properties with TLA

Specifying and Proving Broadcast Properties with TLA Specifying and Proving Broadcast Properties with TLA William Hipschman Department of Computer Science The University of North Carolina at Chapel Hill Abstract Although group communication is vitally important

More information

Distributed Systems Programming (F21DS1) Formal Verification

Distributed Systems Programming (F21DS1) Formal Verification Distributed Systems Programming (F21DS1) Formal Verification Andrew Ireland Department of Computer Science School of Mathematical and Computer Sciences Heriot-Watt University Edinburgh Overview Focus on

More information

A Graphical Tool for Specification of Reactive Systems

A Graphical Tool for Specification of Reactive Systems A Graphical Tool for Specification of Reactive Systems Kari Systä Tampere University of Technology P.O.Box 527, SF-33101 Tampere, Finland e-mail: ks@tut.fi Abstract A prototype of a simulation tool with

More information

Programming Languages Third Edition

Programming Languages Third Edition Programming Languages Third Edition Chapter 12 Formal Semantics Objectives Become familiar with a sample small language for the purpose of semantic specification Understand operational semantics Understand

More information

Cover Page. The handle holds various files of this Leiden University dissertation

Cover Page. The handle   holds various files of this Leiden University dissertation Cover Page The handle http://hdl.handle.net/1887/22891 holds various files of this Leiden University dissertation Author: Gouw, Stijn de Title: Combining monitoring with run-time assertion checking Issue

More information

Asynchronous Models. Chapter Asynchronous Processes States, Inputs, and Outputs

Asynchronous Models. Chapter Asynchronous Processes States, Inputs, and Outputs Chapter 3 Asynchronous Models 3.1 Asynchronous Processes Like a synchronous reactive component, an asynchronous process interacts with other processes via inputs and outputs, and maintains an internal

More information

Proofs and Proof Certification in the TLA + Proof System

Proofs and Proof Certification in the TLA + Proof System Proofs and Proof Certification in the TLA + Proof System Stephan Merz Inria Nancy Grand-Est & LORIA, Villers-lès-Nancy, France Abstract TLA + is a specification language originally designed for specifying

More information

From Event-B Models to Dafny Code Contracts

From Event-B Models to Dafny Code Contracts From Event-B Models to Dafny Code Contracts Mohammadsadegh Dalvandi, Michael Butler, Abdolbaghi Rezazadeh Electronic and Computer Science School, University of Southampton Southampton, United Kingdom {md5g11,mjb,ra3}@ecs.soton.ac.uk

More information

Invariant Based Programming

Invariant Based Programming Invariant Based Programming Ralph-Johan Back Abo Akademi and TUCS June 2006 Constructing correct programs: alternative approaches A posteriori correctness proof (Floyd, Naur, Hoare,...). Prove correctness

More information

The DisCo2000 Specification Language Annotated version

The DisCo2000 Specification Language Annotated version Tampere University of Technology Software Systems Laboratory Project DisCo O IS Hannu-Matti Järvinen The DisCo2000 Specification Language Annotated version DisCo Working Paper March 25, 2003 . Introduction

More information

Appendix 1. Description Logic Terminology

Appendix 1. Description Logic Terminology Appendix 1 Description Logic Terminology Franz Baader Abstract The purpose of this appendix is to introduce (in a compact manner) the syntax and semantics of the most prominent DLs occurring in this handbook.

More information

Lecture Notes on Program Equivalence

Lecture Notes on Program Equivalence Lecture Notes on Program Equivalence 15-312: Foundations of Programming Languages Frank Pfenning Lecture 24 November 30, 2004 When are two programs equal? Without much reflection one might say that two

More information

Appendix 1. Description Logic Terminology

Appendix 1. Description Logic Terminology Appendix 1 Description Logic Terminology Franz Baader Abstract The purpose of this appendix is to introduce (in a compact manner) the syntax and semantics of the most prominent DLs occurring in this handbook.

More information

SOME TYPES AND USES OF DATA MODELS

SOME TYPES AND USES OF DATA MODELS 3 SOME TYPES AND USES OF DATA MODELS CHAPTER OUTLINE 3.1 Different Types of Data Models 23 3.1.1 Physical Data Model 24 3.1.2 Logical Data Model 24 3.1.3 Conceptual Data Model 25 3.1.4 Canonical Data Model

More information

RAISE in Perspective

RAISE in Perspective RAISE in Perspective Klaus Havelund NASA s Jet Propulsion Laboratory, Pasadena, USA Klaus.Havelund@jpl.nasa.gov 1 The Contribution of RAISE The RAISE [6] Specification Language, RSL, originated as a development

More information

Introduction to Formal Methods

Introduction to Formal Methods 2008 Spring Software Special Development 1 Introduction to Formal Methods Part I : Formal Specification i JUNBEOM YOO jbyoo@knokuk.ac.kr Reference AS Specifier s Introduction to Formal lmethods Jeannette

More information

EDMS. Architecture and Concepts

EDMS. Architecture and Concepts EDMS Engineering Data Management System Architecture and Concepts Hannu Peltonen Helsinki University of Technology Department of Computer Science Laboratory of Information Processing Science Abstract

More information

A Formalization of Transition P Systems

A Formalization of Transition P Systems Fundamenta Informaticae 49 (2002) 261 272 261 IOS Press A Formalization of Transition P Systems Mario J. Pérez-Jiménez and Fernando Sancho-Caparrini Dpto. Ciencias de la Computación e Inteligencia Artificial

More information

ARELAY network consists of a pair of source and destination

ARELAY network consists of a pair of source and destination 158 IEEE TRANSACTIONS ON INFORMATION THEORY, VOL 55, NO 1, JANUARY 2009 Parity Forwarding for Multiple-Relay Networks Peyman Razaghi, Student Member, IEEE, Wei Yu, Senior Member, IEEE Abstract This paper

More information

INCREMENTAL SOFTWARE CONSTRUCTION WITH REFINEMENT DIAGRAMS

INCREMENTAL SOFTWARE CONSTRUCTION WITH REFINEMENT DIAGRAMS INCREMENTAL SOFTWARE CONSTRUCTION WITH REFINEMENT DIAGRAMS Ralph-Johan Back Abo Akademi University July 6, 2006 Home page: www.abo.fi/~backrj Research / Current research / Incremental Software Construction

More information

Handout 9: Imperative Programs and State

Handout 9: Imperative Programs and State 06-02552 Princ. of Progr. Languages (and Extended ) The University of Birmingham Spring Semester 2016-17 School of Computer Science c Uday Reddy2016-17 Handout 9: Imperative Programs and State Imperative

More information

This is already grossly inconvenient in present formalisms. Why do we want to make this convenient? GENERAL GOALS

This is already grossly inconvenient in present formalisms. Why do we want to make this convenient? GENERAL GOALS 1 THE FORMALIZATION OF MATHEMATICS by Harvey M. Friedman Ohio State University Department of Mathematics friedman@math.ohio-state.edu www.math.ohio-state.edu/~friedman/ May 21, 1997 Can mathematics be

More information

MA651 Topology. Lecture 4. Topological spaces 2

MA651 Topology. Lecture 4. Topological spaces 2 MA651 Topology. Lecture 4. Topological spaces 2 This text is based on the following books: Linear Algebra and Analysis by Marc Zamansky Topology by James Dugundgji Fundamental concepts of topology by Peter

More information

Monitoring Interfaces for Faults

Monitoring Interfaces for Faults Monitoring Interfaces for Faults Aleksandr Zaks RV 05 - Fifth Workshop on Runtime Verification Joint work with: Amir Pnueli, Lenore Zuck Motivation Motivation Consider two components interacting with each

More information

One of the most important areas where quantifier logic is used is formal specification of computer programs.

One of the most important areas where quantifier logic is used is formal specification of computer programs. Section 5.2 Formal specification of computer programs One of the most important areas where quantifier logic is used is formal specification of computer programs. Specification takes place on several levels

More information

Guarded Operations, Refinement and Simulation

Guarded Operations, Refinement and Simulation Guarded Operations, Refinement and Simulation Steve Reeves and David Streader Department of Computer Science University of Waikato Hamilton, New Zealand stever,dstr@cs.waikato.ac.nz Abstract Simulation

More information

STABILITY AND PARADOX IN ALGORITHMIC LOGIC

STABILITY AND PARADOX IN ALGORITHMIC LOGIC STABILITY AND PARADOX IN ALGORITHMIC LOGIC WAYNE AITKEN, JEFFREY A. BARRETT Abstract. Algorithmic logic is the logic of basic statements concerning algorithms and the algorithmic rules of deduction between

More information

8. Relational Calculus (Part II)

8. Relational Calculus (Part II) 8. Relational Calculus (Part II) Relational Calculus, as defined in the previous chapter, provides the theoretical foundations for the design of practical data sub-languages (DSL). In this chapter, we

More information

How to Make a Correct Multiprocess Program Execute Correctly on a Multiprocessor

How to Make a Correct Multiprocess Program Execute Correctly on a Multiprocessor How to Make a Correct Multiprocess Program Execute Correctly on a Multiprocessor Leslie Lamport 1 Digital Equipment Corporation February 14, 1993 Minor revisions January 18, 1996 and September 14, 1996

More information

SOFTWARE ENGINEERING DESIGN I

SOFTWARE ENGINEERING DESIGN I 2 SOFTWARE ENGINEERING DESIGN I 3. Schemas and Theories The aim of this course is to learn how to write formal specifications of computer systems, using classical logic. The key descriptional technique

More information

Term Algebras with Length Function and Bounded Quantifier Elimination

Term Algebras with Length Function and Bounded Quantifier Elimination with Length Function and Bounded Ting Zhang, Henny B Sipma, Zohar Manna Stanford University tingz,sipma,zm@csstanfordedu STeP Group, September 3, 2004 TPHOLs 2004 - p 1/37 Motivation: Program Verification

More information

Goals: Define the syntax of a simple imperative language Define a semantics using natural deduction 1

Goals: Define the syntax of a simple imperative language Define a semantics using natural deduction 1 Natural Semantics Goals: Define the syntax of a simple imperative language Define a semantics using natural deduction 1 1 Natural deduction is an instance of first-order logic; that is, it is the formal

More information

Complexity Theory. Compiled By : Hari Prasad Pokhrel Page 1 of 20. ioenotes.edu.np

Complexity Theory. Compiled By : Hari Prasad Pokhrel Page 1 of 20. ioenotes.edu.np Chapter 1: Introduction Introduction Purpose of the Theory of Computation: Develop formal mathematical models of computation that reflect real-world computers. Nowadays, the Theory of Computation can be

More information

Safe Stratified Datalog With Integer Order Does not Have Syntax

Safe Stratified Datalog With Integer Order Does not Have Syntax Safe Stratified Datalog With Integer Order Does not Have Syntax Alexei P. Stolboushkin Department of Mathematics UCLA Los Angeles, CA 90024-1555 aps@math.ucla.edu Michael A. Taitslin Department of Computer

More information

Guidelines for the Specification of Managed Object Behaviors with TIMS

Guidelines for the Specification of Managed Object Behaviors with TIMS Guidelines for the Specification of Managed Object ehaviors with TIMS 1 Guidelines for the Specification of Managed Object ehaviors with TIMS Institut Eurecom, 2229 rte des Cretes, P.193, 06904 Sophia

More information

RSL Reference Manual

RSL Reference Manual RSL Reference Manual Part No.: Date: April 6, 1990 Original Authors: Klaus Havelund, Anne Haxthausen Copyright c 1990 Computer Resources International A/S This document is issued on a restricted basis

More information

Rule Formats for Nominal Modal Transition Systems

Rule Formats for Nominal Modal Transition Systems Rule Formats for Nominal Modal Transition Systems Anke Stüber Universitet Uppsala, Uppsala, Sweden anke.stuber@it.uu.se Abstract. Modal transition systems are specification languages that allow the expression

More information

Joint Entity Resolution

Joint Entity Resolution Joint Entity Resolution Steven Euijong Whang, Hector Garcia-Molina Computer Science Department, Stanford University 353 Serra Mall, Stanford, CA 94305, USA {swhang, hector}@cs.stanford.edu No Institute

More information

StateClock: a Tool for Timed Reactive Modules

StateClock: a Tool for Timed Reactive Modules StateClock: a Tool for Timed Reactive Modules Jonathan S. Ostroff Department Of Computer Science, York University, Toronto, Canada, M3J 1P3. Email: jonathan@yorku.ca Abstract: We provide an overview of

More information

Interprocess Communication By: Kaushik Vaghani

Interprocess Communication By: Kaushik Vaghani Interprocess Communication By: Kaushik Vaghani Background Race Condition: A situation where several processes access and manipulate the same data concurrently and the outcome of execution depends on the

More information

Breakpoints and Halting in Distributed Programs

Breakpoints and Halting in Distributed Programs 1 Breakpoints and Halting in Distributed Programs Barton P. Miller Jong-Deok Choi Computer Sciences Department University of Wisconsin-Madison 1210 W. Dayton Street Madison, Wisconsin 53706 Abstract Interactive

More information

Foundations of AI. 9. Predicate Logic. Syntax and Semantics, Normal Forms, Herbrand Expansion, Resolution

Foundations of AI. 9. Predicate Logic. Syntax and Semantics, Normal Forms, Herbrand Expansion, Resolution Foundations of AI 9. Predicate Logic Syntax and Semantics, Normal Forms, Herbrand Expansion, Resolution Wolfram Burgard, Andreas Karwath, Bernhard Nebel, and Martin Riedmiller 09/1 Contents Motivation

More information

On the Definition of Sequential Consistency

On the Definition of Sequential Consistency On the Definition of Sequential Consistency Ali Sezgin Ganesh Gopalakrishnan Abstract The definition of sequential consistency is compared with an intuitive notion of correctness. A relation between what

More information

Automata Theory for Reasoning about Actions

Automata Theory for Reasoning about Actions Automata Theory for Reasoning about Actions Eugenia Ternovskaia Department of Computer Science, University of Toronto Toronto, ON, Canada, M5S 3G4 eugenia@cs.toronto.edu Abstract In this paper, we show

More information

CSC 501 Semantics of Programming Languages

CSC 501 Semantics of Programming Languages CSC 501 Semantics of Programming Languages Subtitle: An Introduction to Formal Methods. Instructor: Dr. Lutz Hamel Email: hamel@cs.uri.edu Office: Tyler, Rm 251 Books There are no required books in this

More information

The Encoding Complexity of Network Coding

The Encoding Complexity of Network Coding The Encoding Complexity of Network Coding Michael Langberg Alexander Sprintson Jehoshua Bruck California Institute of Technology Email: mikel,spalex,bruck @caltech.edu Abstract In the multicast network

More information

Research Report. (Im)Possibilities of Predicate Detection in Crash-Affected Systems. RZ 3361 (# 93407) 20/08/2001 Computer Science 27 pages

Research Report. (Im)Possibilities of Predicate Detection in Crash-Affected Systems. RZ 3361 (# 93407) 20/08/2001 Computer Science 27 pages RZ 3361 (# 93407) 20/08/2001 Computer Science 27 pages Research Report (Im)Possibilities of Predicate Detection in Crash-Affected Systems Felix C. Gärtner and Stefan Pleisch Department of Computer Science

More information

6.001 Notes: Section 6.1

6.001 Notes: Section 6.1 6.001 Notes: Section 6.1 Slide 6.1.1 When we first starting talking about Scheme expressions, you may recall we said that (almost) every Scheme expression had three components, a syntax (legal ways of

More information

Fundamental Concepts. Chapter 1

Fundamental Concepts. Chapter 1 Chapter 1 Fundamental Concepts This book is about the mathematical foundations of programming, with a special attention on computing with infinite objects. How can mathematics help in programming? There

More information

Hypertext A Case Study of Formal Object-Oriented Software Development

Hypertext A Case Study of Formal Object-Oriented Software Development Hypertext A Case Study of Formal Object-Oriented Software Development Andreas Rüping Forschungszentrum Informatik (FZI) Bereich Programmstrukturen Haid-und-Neu-Straße 10-14 D-76131 Karlsruhe e-mail: rueping@fzi.de

More information

An implementation model of rendezvous communication

An implementation model of rendezvous communication G.Winskel Eds. Appears in Seminar on Concurrency S.D.Brookds, A.W.Roscoe, and Lecture Notes in Computer Science 197 Springer-Verlag, 1985 An implementation model of rendezvous communication Luca Cardelli

More information

Chapter 3. Semantics. Topics. Introduction. Introduction. Introduction. Introduction

Chapter 3. Semantics. Topics. Introduction. Introduction. Introduction. Introduction Topics Chapter 3 Semantics Introduction Static Semantics Attribute Grammars Dynamic Semantics Operational Semantics Axiomatic Semantics Denotational Semantics 2 Introduction Introduction Language implementors

More information

A Brief Introduction to Coloured Petri Nets

A Brief Introduction to Coloured Petri Nets A Brief Introduction to Coloured Petri Nets Kurt Jensen Computer Science Department, University of Aarhus NyMunkegade, Bldg. 540, DK-8000 AarhusC, Denmark E-mml: kjensen9 WWV~: http://www.daimi.aau.dk/~kjensen/

More information

A Lightweight Language for Software Product Lines Architecture Description

A Lightweight Language for Software Product Lines Architecture Description A Lightweight Language for Software Product Lines Architecture Description Eduardo Silva, Ana Luisa Medeiros, Everton Cavalcante, Thais Batista DIMAp Department of Informatics and Applied Mathematics UFRN

More information

15-819M: Data, Code, Decisions

15-819M: Data, Code, Decisions 15-819M: Data, Code, Decisions 08: First-Order Logic André Platzer aplatzer@cs.cmu.edu Carnegie Mellon University, Pittsburgh, PA André Platzer (CMU) 15-819M/08: Data, Code, Decisions 1 / 40 Outline 1

More information

A taxonomy of race. D. P. Helmbold, C. E. McDowell. September 28, University of California, Santa Cruz. Santa Cruz, CA

A taxonomy of race. D. P. Helmbold, C. E. McDowell. September 28, University of California, Santa Cruz. Santa Cruz, CA A taxonomy of race conditions. D. P. Helmbold, C. E. McDowell UCSC-CRL-94-34 September 28, 1994 Board of Studies in Computer and Information Sciences University of California, Santa Cruz Santa Cruz, CA

More information

Operational Semantics

Operational Semantics 15-819K: Logic Programming Lecture 4 Operational Semantics Frank Pfenning September 7, 2006 In this lecture we begin in the quest to formally capture the operational semantics in order to prove properties

More information

Byzantine Consensus in Directed Graphs

Byzantine Consensus in Directed Graphs Byzantine Consensus in Directed Graphs Lewis Tseng 1,3, and Nitin Vaidya 2,3 1 Department of Computer Science, 2 Department of Electrical and Computer Engineering, and 3 Coordinated Science Laboratory

More information

Computer Science Technical Report

Computer Science Technical Report Computer Science Technical Report Feasibility of Stepwise Addition of Multitolerance to High Atomicity Programs Ali Ebnenasir and Sandeep S. Kulkarni Michigan Technological University Computer Science

More information

JOURNAL OF OBJECT TECHNOLOGY

JOURNAL OF OBJECT TECHNOLOGY JOURNAL OF OBJECT TECHNOLOGY Online at www.jot.fm. Published by ETH Zurich, Chair of Software Engineering JOT, 2002 Vol. 1, No. 2, July-August 2002 The Theory of Classification Part 2: The Scratch-Built

More information

Chapter 2 Overview of the Design Methodology

Chapter 2 Overview of the Design Methodology Chapter 2 Overview of the Design Methodology This chapter presents an overview of the design methodology which is developed in this thesis, by identifying global abstraction levels at which a distributed

More information

How useful is the UML profile SPT without Semantics? 1

How useful is the UML profile SPT without Semantics? 1 How useful is the UML profile SPT without Semantics? 1 Susanne Graf, Ileana Ober VERIMAG 2, avenue de Vignate - F-38610 Gières - France e-mail:{susanne.graf, Ileana.Ober}@imag.fr http://www-verimag.imag.fr/~{graf,iober}

More information

CS Bootcamp Boolean Logic Autumn 2015 A B A B T T T T F F F T F F F F T T T T F T F T T F F F

CS Bootcamp Boolean Logic Autumn 2015 A B A B T T T T F F F T F F F F T T T T F T F T T F F F 1 Logical Operations 1.1 And The and operator is a binary operator, denoted as, &,, or sometimes by just concatenating symbols, is true only if both parameters are true. A B A B F T F F F F The expression

More information

Uncertain Data Models

Uncertain Data Models Uncertain Data Models Christoph Koch EPFL Dan Olteanu University of Oxford SYNOMYMS data models for incomplete information, probabilistic data models, representation systems DEFINITION An uncertain data

More information

Discrete Mathematics Lecture 4. Harper Langston New York University

Discrete Mathematics Lecture 4. Harper Langston New York University Discrete Mathematics Lecture 4 Harper Langston New York University Sequences Sequence is a set of (usually infinite number of) ordered elements: a 1, a 2,, a n, Each individual element a k is called a

More information

The alternator. Mohamed G. Gouda F. Furman Haddix

The alternator. Mohamed G. Gouda F. Furman Haddix Distrib. Comput. (2007) 20:21 28 DOI 10.1007/s00446-007-0033-1 The alternator Mohamed G. Gouda F. Furman Haddix Received: 28 August 1999 / Accepted: 5 July 2000 / Published online: 12 June 2007 Springer-Verlag

More information

Chapter 3. Describing Syntax and Semantics

Chapter 3. Describing Syntax and Semantics Chapter 3 Describing Syntax and Semantics Chapter 3 Topics Introduction The General Problem of Describing Syntax Formal Methods of Describing Syntax Attribute Grammars Describing the Meanings of Programs:

More information

Temporal Logic of Actions (TLA) (a brief introduction) Shmuel Katz Computer Science Department The Technion

Temporal Logic of Actions (TLA) (a brief introduction) Shmuel Katz Computer Science Department The Technion Temporal Logic of Actions (TLA) (a brief introduction) Shmuel Katz Computer Science Department The Technion CS236368 Formal Specifications Lecture-- TLA 1 Basic Idea Combine transitions with temporal logic

More information

FAdo: Interactive Tools for Learning Formal Computational Models

FAdo: Interactive Tools for Learning Formal Computational Models FAdo: Interactive Tools for Learning Formal Computational Models Rogério Reis Nelma Moreira DCC-FC& LIACC, Universidade do Porto R. do Campo Alegre 823, 4150 Porto, Portugal {rvr,nam}@ncc.up.pt Abstract

More information

Quo Vadis Program Verification

Quo Vadis Program Verification Quo Vadis Program Verification p. 1/2 Quo Vadis Program Verification Krzysztof R. Apt CWI, Amsterdam, the Netherlands, University of Amsterdam We would like to use correct programs. Quo Vadis Program Verification

More information

Modelling, Specification and Verification of an Emergency Closing System

Modelling, Specification and Verification of an Emergency Closing System From: FLAIRS-00 Proceedings. Copyright 2000, AAAI (www.aaai.org). All rights reserved. Modelling, Specification and Verification of an Emergency Closing System Werner Stephan and Georg Rock and Michael

More information

Enhancing The Fault-Tolerance of Nonmasking Programs

Enhancing The Fault-Tolerance of Nonmasking Programs Enhancing The Fault-Tolerance of Nonmasking Programs Sandeep S Kulkarni Ali Ebnenasir Department of Computer Science and Engineering Michigan State University East Lansing MI 48824 USA Abstract In this

More information

(Refer Slide Time: 4:00)

(Refer Slide Time: 4:00) Principles of Programming Languages Dr. S. Arun Kumar Department of Computer Science & Engineering Indian Institute of Technology, Delhi Lecture - 38 Meanings Let us look at abstracts namely functional

More information

A Mechanically and Incremental Development of the Remote Authentication Dial-In User Service Protocol

A Mechanically and Incremental Development of the Remote Authentication Dial-In User Service Protocol A Mechanically and Incremental Development of the Remote Authentication Dial-In User Service Protocol Sanae El Mimouni, Rajaa Filali, Anas Amamou, Bahija Boulamaat and Mohamed Bouhdadi Abstract The Remote

More information

Model checking pushdown systems

Model checking pushdown systems Model checking pushdown systems R. Ramanujam Institute of Mathematical Sciences, Chennai jam@imsc.res.in Update Meeting, IIT-Guwahati, 4 July 2006 p. 1 Sources of unboundedness Data manipulation: integers,

More information

IEEE LANGUAGE REFERENCE MANUAL Std P1076a /D3

IEEE LANGUAGE REFERENCE MANUAL Std P1076a /D3 LANGUAGE REFERENCE MANUAL Std P1076a-1999 2000/D3 Clause 10 Scope and visibility The rules defining the scope of declarations and the rules defining which identifiers are visible at various points in the

More information

Semantics via Syntax. f (4) = if define f (x) =2 x + 55.

Semantics via Syntax. f (4) = if define f (x) =2 x + 55. 1 Semantics via Syntax The specification of a programming language starts with its syntax. As every programmer knows, the syntax of a language comes in the shape of a variant of a BNF (Backus-Naur Form)

More information

Lecture 1 Contracts : Principles of Imperative Computation (Fall 2018) Frank Pfenning

Lecture 1 Contracts : Principles of Imperative Computation (Fall 2018) Frank Pfenning Lecture 1 Contracts 15-122: Principles of Imperative Computation (Fall 2018) Frank Pfenning In these notes we review contracts, which we use to collectively denote function contracts, loop invariants,

More information

ACONCURRENT system may be viewed as a collection of

ACONCURRENT system may be viewed as a collection of 252 IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS, VOL. 10, NO. 3, MARCH 1999 Constructing a Reliable Test&Set Bit Frank Stomp and Gadi Taubenfeld AbstractÐThe problem of computing with faulty

More information

Knowledge representation Semantic networks and frames

Knowledge representation Semantic networks and frames Knowledge representation Semantic networks and frames CmSc310 Artificial Intelligence 1. Introduction: What is knowledge? The science that studies various issues about knowledge is called epistemology.

More information

Lecture 11 Lecture 11 Nov 5, 2014

Lecture 11 Lecture 11 Nov 5, 2014 Formal Verification/Methods Lecture 11 Lecture 11 Nov 5, 2014 Formal Verification Formal verification relies on Descriptions of the properties or requirements Descriptions of systems to be analyzed, and

More information

Automatic synthesis of switching controllers for linear hybrid systems: Reachability control

Automatic synthesis of switching controllers for linear hybrid systems: Reachability control Automatic synthesis of switching controllers for linear hybrid systems: Reachability control Massimo Benerecetti and Marco Faella Università di Napoli Federico II, Italy Abstract. We consider the problem

More information

From Types to Sets in Isabelle/HOL

From Types to Sets in Isabelle/HOL From Types to Sets in Isabelle/HOL Extented Abstract Ondřej Kunčar 1 and Andrei Popescu 1,2 1 Fakultät für Informatik, Technische Universität München, Germany 2 Institute of Mathematics Simion Stoilow

More information

PROPER TECHNIQUE OF SOFTWARE INSPECTION USING GUARDED COMMAND LANGUAGE

PROPER TECHNIQUE OF SOFTWARE INSPECTION USING GUARDED COMMAND LANGUAGE International Journal of Computer Science and Communication Vol. 2, No. 1, January-June 2011, pp. 153-157 PROPER TECHNIQUE OF SOFTWARE INSPECTION USING GUARDED COMMAND LANGUAGE Neeraj Kumar Singhania University,

More information

Reasoning about modules: data refinement and simulation

Reasoning about modules: data refinement and simulation Reasoning about modules: data refinement and simulation David Naumann naumann@cs.stevens-tech.edu Stevens Institute of Technology Naumann - POPL 02 Java Verification Workshop p.1/17 Objectives of talk

More information

CHAPTER III TMN MANAGEMENT

CHAPTER III TMN MANAGEMENT CHAPTER III TMN MANAGEMENT TMN Management TMN Management The term TMN is introduced by the ITU-T (the former CCITT) as an abbreviation for 'Telecommunications Management Network'. The concept of a TMN

More information

CITS5501 Software Testing and Quality Assurance Formal methods

CITS5501 Software Testing and Quality Assurance Formal methods CITS5501 Software Testing and Quality Assurance Formal methods Unit coordinator: Arran Stewart May 1, 2018 1 / 49 Sources Pressman, R., Software Engineering: A Practitioner s Approach, McGraw-Hill, 2005

More information

Formal semantics of loosely typed languages. Joep Verkoelen Vincent Driessen

Formal semantics of loosely typed languages. Joep Verkoelen Vincent Driessen Formal semantics of loosely typed languages Joep Verkoelen Vincent Driessen June, 2004 ii Contents 1 Introduction 3 2 Syntax 5 2.1 Formalities.............................. 5 2.2 Example language LooselyWhile.................

More information

Enhancing Datalog with Epistemic Operators to Reason About Systems Knowledge in

Enhancing Datalog with Epistemic Operators to Reason About Systems Knowledge in Enhancing Datalog with Epistemic Operators to Enhancing ReasonDatalog About Knowledge with Epistemic in Distributed Operators to Reason About Systems Knowledge in Distributed (Extended abstract) Systems

More information

Formal Methods in Software Engineering. Lecture 07

Formal Methods in Software Engineering. Lecture 07 Formal Methods in Software Engineering Lecture 07 What is Temporal Logic? Objective: We describe temporal aspects of formal methods to model and specify concurrent systems and verify their correctness

More information

Model-based Testing Using Scenarios and Event-B Refinements

Model-based Testing Using Scenarios and Event-B Refinements Model-based Testing Using Scenarios and Event-B Refinements Qaisar A. Malik, Johan Lilius, and Linas Laibinis Åbo Akademi University, Department of Information Technologies Turku Centre for Computer Science

More information

7. Relational Calculus (Part I) 7.1 Introduction

7. Relational Calculus (Part I) 7.1 Introduction 7. Relational Calculus (Part I) 7.1 Introduction We established earlier the fundamental role of relational algebra and calculus in relational databases (see 5.1). More specifically, relational calculus

More information

Universal Timestamp-Scheduling for Real-Time Networks. Abstract

Universal Timestamp-Scheduling for Real-Time Networks. Abstract Universal Timestamp-Scheduling for Real-Time Networks Jorge A. Cobb Department of Computer Science Mail Station EC 31 The University of Texas at Dallas Richardson, TX 75083-0688 jcobb@utdallas.edu Abstract

More information

Module 11. Directed Graphs. Contents

Module 11. Directed Graphs. Contents Module 11 Directed Graphs Contents 11.1 Basic concepts......................... 256 Underlying graph of a digraph................ 257 Out-degrees and in-degrees.................. 258 Isomorphism..........................

More information