On two Friends for getting Correct Programs Automatically Translating Event B Specifications to Recursive Algorithms in Rodin
Résumé
We report on our progress-to-date in implementing a software de- velopment environment which integrates the efforts of two formal software engineering techniques: program refinement as supported by Event B and program verification as supported by the Spec# programming system. Our objective is to improve the usability of formal verification tools by providing a general framework for integrating these two approaches to software veri- fication. We show how the two approaches Correctness-by-Construction and Post-hoc Verification can be used in a productive way. Here, we focus on the final steps in this process where the final concrete specification is transformed into an executable algorithm. We present EB2RC,a plug-in for the Rodin platform, that reads in an Event B model and uses the control framework introduced during its refinement to generate a graphical representation of the executable algorithm. EB2RC also generates a recursive algorithm that is eas- ily translated into executable code. We illustrate our technique through case studies and their analysis.