The Kleene Algebra of Nested Pointer Structures: Theory and Applications

Thorsten Ehm

The Kleene Algebra of Nested Pointer Structures: Theory and Applications

Dissertation, Universität Augsburg.
Erstgutachter: Professor Dr. B. Möller
Zweitgutachter: Professor Dr. R. Berghammer (Uni Kiel)
erschienen 12/2003


Software controlled systems more and more become established in our daily life. Thus, the probability to be confronted with system crashes, breakdowns or erroneous behaviour due to slovenly programmed code is increased considerably. While this may only be annoying for electronic entertainment products it could be dangerous to life in traffic and nuclear power plant control systems or medical tools. Applications from all these areas require a formal software development process to assure correctness.

Although there are several methods to achieve this goal in general, verification and development of correct pointer algorithms, which are most susceptible to errors, have to a large extent defied a general formal treatment.

In this thesis this insufficiency is dealt with in two ways. First, an abstract calculus for the treatment of labeled graphs and pointer structures is presented. The framework is based on Kleene algebra, which despite its simple structure has been successfully applied to a variety of different problems. Simplicity and succinctness is inherited directly by the pointer Kleene algebra defined here. It enables a compact representation without preventing access to the internal structure. We introduce higher-level operators to describe reachability constraints, allocation, selection and projection. Localization properties that allow restricting the effects of modifications to particular parts of the memory are proved.

A second part presents applications of pointer Kleene algebra to the software development process. The algebra is used as formal basis for a transformation system to derive correct pointer algorithms from functional specifications. To cover the whole scope from specification to implementation this method is extended by a general transformation scheme to create efficient imperative algorithms. As a further application it is shown that pointer Kleene algebra can also serve as an algebraic model behind a Hoare-style verification system for algorithms on linked data structures.