Semantics, Specification Logic, and Hoare Logic of Exact Real Computation
Preprint
Abstract
We propose a simple imperative programming language, ERC, that features arbitrary real numbers as primitive data type, exactly. Equipped with a denotational semantics, ERC provides a formal programming language-theoretic foundation to the algorithmic processing of real numbers. In order to capture multi-valuedness, which is well-known essential to real number computation, we use a carefully designed Plotkin powerdomain. This makes our programming language semantics computable and complete: all and only real functions computable in computable analysis can be realized in ERC. The base programming language supports real arithmetic as well as implicit limits; expansions support additional primitive operations (such as a user-defined exponential function). By restricting integers to Presburger arithmetic and real coercion to the `precision' embedding $Z\ni p\mapsto 2^p\in R$, we arrive at a first-order theory which we prove to be decidable, model-complete, and expressive for the base programming language. Based on said logic as specification language for preconditions and postconditions, we extend Hoare logic to a sound (w.r.t. the denotational semantics) and expressive system for deriving correct TOTAL correctness predicates. Various examples demonstrate the practicality and convenience of our language and proof rules.
Keywords
All Related Versions
This publication has 22 references indexed in Scilit:
- Proving Bounds on Real-Valued Functions with Computations2008
- Classroom examples of robustness problems in geometric computationsComputational Geometry, 2008
- Quantifier elimination for the reals with a predicate for the powers of twoTheoretical Computer Science, 2007
- Spaces allowing Type‐2 Complexity Theory revisitedMathematical Logic Quarterly, 2004
- Computational complexity on computable metric spacesMathematical Logic Quarterly, 2003
- A Real Number Structure that is Effectively CategoricalMathematical Logic Quarterly, 1999
- Feasible Real Random Access MachinesJournal of Complexity, 1998
- Topological Complexity with Continuous OperationsJournal of Complexity, 1996
- A fundamental effect in computations on real numbersTheoretical Computer Science, 1977
- LCF considered as a programming languageTheoretical Computer Science, 1977