Skip navigation.
Home

Formal Methods for Java

Instructors & Assistants

Date & Location

Lectures

  • Tuesday 11:00 a.m. (c.t.) - 01:00 p.m., SR 02-017 Geb. 52
  • Thursday 11:00 a.m. (c.t.) - 01:00 p.m., SR 00-034 Geb.51
  • 3 hours per week on average

Exercises (Discussion Groups)

  • Tuesday 10:00 a.m. (c.t) 00-016 Geb. 52

Summary

Recently, formal methods have been successfully used to specify and verify large software system. A current example is the Verisoft project, whose goal is to create a fully verified processor, operating system and compiler. In this lecture we will investigate the exising methods for the language Java.

The language Java was chosen because it is a mature language, with a semi-formal definition of its semantics (The Java Language Specification). However, to use mathematical reasoning, we need a precise definition of the semantics. Therefore, we will sketch the definition of an operational semantics for Java. Furthermore, we will investigate different formal methods for Java. The starting point will be the language extension JML that allows Design by Contract. This allows to add pre- and postconditions to methods and invariants to classes and loops. These assertions can be checked during runtime and this is the purpose of the JML runtime assertion checker (jmlrac). On the other hand, there are static methods, e.g., ESC/Java and Jahob, that automatically provide mathematical proofs that the Java code ensures the post-condition for each possible pre-condition. If these proofs cannot be find automatically, one can also use theorem provers that assists finding a proof manually.

In this lecture, we will present the different approaches for verification of Java code. In the exercise you can investigate different tools on small practical examples.

Exercise Sheets

Slides

    Material

    Links & Literature