The algebra of non-deterministic programs: demonic operators, orders and axioms

Robin Hirsch,Szabolcs Mikulás,Tim Stokes
DOI: https://doi.org/10.48550/arXiv.2009.12081
2021-01-13
Abstract:Demonic composition, demonic refinement and demonic union are alternatives to the usual "angelic" composition, angelic refinement (inclusion) and angelic (usual) union defined on binary relations. We first motivate both the angelic and demonic via an analysis of the behaviour of non-deterministic programs, with the angelic associated with partial correctness and demonic with total correctness, both cases emerging from a richer algebraic model of non-deterministic programs incorporating both aspects. Zareckii has shown that the isomorphism class of algebras of binary relations under angelic composition and inclusion is finitely axiomatised as the class of ordered semigroups. The proof can be used to establish that the same axiomatisation applies to binary relations under demonic composition and refinement, and a further modification of the proof can be used to incorporate a zero element representing the empty relation in the angelic case and the full relation in the demonic case. For the signature of angelic composition and union, it is known that no finite axiomatisation exists, and we show the analogous result for demonic composition and demonic union by showing that the same axiomatisation holds for both. We show that the isomorphism class of algebras of binary relations with the "mixed" signature of demonic composition and angelic inclusion has no finite axiomatisation. As a contrast, we show that the isomorphism class of partial algebras of binary relations with the partial operation of constellation product and inclusion (also a "mixed" signature) is finitely axiomatisable.
Logic in Computer Science,Computation and Language
What problem does this paper attempt to address?
The problems that this paper attempts to solve mainly focus on the behavior modeling of non - deterministic programs and the axiomatic description of their algebraic structures. Specifically: 1. **Algebraic Model of Non - deterministic Programs**: The paper explores how to model the behavior of non - deterministic programs through the algebraic structure of binary relations. In particular, the paper introduces "demonic" operations and sequences, which correspond to the traditional "angelic" operations and sequences respectively, and are used to describe the partial correctness and total correctness of programs. 2. **Axiomatic Description**: One of the core objectives of the paper is to study whether these algebraic structures can be finitely axiomatized. Specifically, the paper discusses the following situations: - Whether the binary relation algebra containing only "angelic" operations and sequences can be finitely axiomatized. - Whether the binary relation algebra containing only "demonic" operations and sequences can be finitely axiomatized. - Whether the binary relation algebra containing mixed operations (such as "demonic" composition and "angelic" sequence) can be finitely axiomatized. 3. **Properties of Specific Algebraic Structures**: The paper also explores the properties of some specific algebraic structures, for example: - The algebraic structure of binary relations under "angelic" composition and union. - The algebraic structure of binary relations under "demonic" composition and "demonic" union. - The properties of partial algebraic structures under constellation product and sequence. 4. **Introduction of Zero and Unit Elements**: The paper further studies the influence of introducing zero and unit elements in the algebraic structure, and whether these structures can still be finitely axiomatized. ### Specific Problems - **Algebraic Representation of Partial and Total Correctness**: The paper distinguishes the partial and total correctness of programs through "angelic" and "demonic" operations, and explores the algebraic significance of these operations. - **Axiomatization Problem**: The paper proves that some algebraic structures (such as the structure of binary relations under "angelic" composition and sequence) can be finitely axiomatized, while other structures (such as the structure containing mixed operations) cannot be finitely axiomatized. - **Influence of Zero and Unit Elements**: The paper studies the change in the properties of these structures after introducing zero and unit elements in the algebraic structure, and explores the influence of these changes on axiomatization. ### Conclusion The main contribution of the paper lies in the systematic study of the algebraic models of non - deterministic programs, and on the basis of these models, it explores their axiomatization problems. By introducing "demonic" operations and sequences, the paper provides a new perspective for understanding the behavior of non - deterministic programs, and has achieved important theoretical results in the axiomatization of algebraic structures.