22c:181 (055:181)

Formal Methods in Software Engineering

Department of Computer Science

The University of Iowa

Spring 2008


Course Syllabus

Lectures

TuTh 2:30pm - 3:45pm, 1100 UCC

Instructor

Prof. Cesare Tinelli
201F MLH
335-0735
tinelli(AT)cs(DOT)uiowa(DOT)edu

Office hours: Tue 4:00-5:30pm, Fri 2:00-3:30pm and by appointment.

Teaching Assistant

George Hagen
317 MLH
335-1325
ghagen(AT)cs(DOT)uiowa(DOT)edu

Office hours: Wed 2:00-3:00pm (may stay later on request), Thu 1:30-2:30pm, both in 301 MLH (SW corner "cubicles").

Prerequisites

22c:180 or equivalent, or consent of instructor.

Web Page

Most of the information about the class, including handouts and assignments, will be available from the class web site:

http://www.cs.uiowa.edu/~tinelli/181

Students are expected to check both the web site and its related bulletin board on a regular basis (at least every other day) for announcements regarding the course.

Course Purpose

The purpose of formal methods is to enable the construction of large, highly reliable software. Their foundation is the precise specification of the run-time properties that a software system is expected to satisfy. The case for having precise specifications is fairly obvious: without a precise specification of the software system to be built it is not possible tell that the right system is being built. Formal methods are concerned with specifications that are precise for being stated in languages endowed with a formal syntax, semantics, and theory. Formality helps the specification process in at least two ways:

  1. it naturally leads to unambiguous, high-quality specifications, and
  2. it provides the bases for automated tool support.

As we will see in this course, formal specification techniques allow for the construction of automated verification tools that can perform tests on specifications and corresponding code to find errors in requirements, models, designs, and implementations. The course will focus on two particular styles of formal methods for software: automatic and interactive methods. Each style will be introduced using a particular set of concrete tools for developing software in that style.

For the automatic style, which inherently places restrictions on the kind of software that can be developed, we will use the real-time synchronous programming language Lustre and associated tools. The main automatic method we will concentrate on is the verification of safety properties using temporal induction techniques. For this method we will use a state of the art verifier developed here at Iowa.

For the interative style, which has a more general scope, we will concentrate on JavaCard, a subset of Java, and use the KeY tool. KeY is an integrated tool for object-oriented design and formal verification developed at Chalmers university and at University of Karlsruhe. KeY supports UML class diagrams, formal specification in OCL, translation from OCL into logic, and an interactive theorem prover that is used to formally verify statements about specifications and programs.

Some familiarity with Java, UML, and predicate logic (first-order logic) is will be helpful but is not required.

Students should be prepared to put in considerable time and effort into reading to become familiar with the course's topics, and into homeworks and exercises to gain experience with the techniques seen in class.

Textbook and readings

There is no required textbook for this course. Reading materials will be available on the course web site. They will include several papers on formal software specification and verification, a number of papers on how to use the specification/verification tools adopted in the course, and various class notes and handouts.

Homework Assignments

Several small exercises will be given during the course of the semester, covering the material from the textbook and the lectures. These exercises are highly recommended but not obligatory. They will not be collected or graded. There will be 2 or 3 graded mini-projects, to be done in small teams. More information on them will be posted on the course website.

Exams

There will be one midterm exam, during class time, and one final exam, held as per university schedule.

Grading

The weighting of items in grade determination will be the following:

Mini Projects 30%
Midterm 35%
Final Exam 35%

The following cutoffs will be used to determine letter grades. In the ranges below, x stands for your total score at the end of the semester. Final scores near a cutoff will be individually considered for the next higher grade. Plus(+) and minus(-) grades will also be given; their cutoffs will be determined at the end of the semester.

Score  Grade
88 <= x < 100 A
75 <= x < 88

B

60 <= x < 75 C
50 <= x < 60 D
00 <= x < 50 F

Grades are not curved in this course. It is theoretically possible for everyone in the class to get an A (or an F). Your final grade depends only on your own performance and not on that of others.

Course Policies

Assigned readings: Students are expected to study all the material in each chapter covered in the readings, even if that material is not explicitly discussed in class or in the homeworks.

Optional readings and discussions: Students are urged to consult sources other than our textbooks, including both reserve books and on-line material, even if there is no directed outside reading assignment. Students are also encouraged to discuss the course topics with their classmates. It is a genuinely helpful learning activity having to formulate one's own thoughts about the material well enough to express them to others.

Attendance: Students are expected to attend all classes. Their knowledge and therefore their grade depends on it. They are responsible for all announcements and material covered during class even if they did not attend.

Cheating: Sharing solutions of graded assignments and projects, or copying someone else's work, is not allowed. Doing that will result in a zero on the assignment for the first offense and an F in the course for the second offense.

Extra credit: No extra-credit assignments or tests will be given on an individual basis (although they maybe given to the whole class).

Make-up exams: Make-up exams will be offered only if there is a serious, documented reason for not being able to attend a scheduled exam, and if the request is made at least a week before the scheduled exam.

Regrading: Students thinking a graded assignment or a test has been misgraded and deserves a regrading are invited to let the instructor know. The instructor welcomes and will give full consideration to all well motivated regrading requests.

General CLAS Policies

Administrative Home: The College of Liberal Arts and Sciences is the administrative home of this course and governs matters such as the add/drop deadlines, the second-grade-only option, and other related issues. Different colleges may have different policies. Questions may be addressed to 120 Schaeffer Hall or see the Academic Handbook. www.clas.uiowa.edu/students/academic_handbook/index.shtml

Academic Fraud: Plagiarism and any other activities when students present work that is not his or her own are academic fraud. Academic fraud is reported to the departmental DEO and to the Associate Dean for Academic Programs and Services who enforces the appropriate consequences. www.clas.uiowa.edu/students/academic_handbook/ix.shtm

Making a Suggestion or a Complaint: Students with a suggestion or complaint should first visit the instructor, then the course supervisor and the departmental DEO. Complaints must be made within six months of the incident. www.clas.uiowa.edu/students/academic_handbook/ix.shtml#5

Accommodations for Disabilities: A student seeking academic accommodations should register with Student Disability Services and meet privately with the course instructor to make particular arrangements www.uiowa.edu/~sds/

Understanding Sexual Harassment: Sexual harassment subverts the mission of the University and threatens the well-being of students, faculty, and staff. www.sexualharassment.uiowa.edu

Reacting Safely to Severe Weather: In severe weather, the class members will seek shelter in the innermost part of the building, if possible at the lowest level, staying clear of windows and free-standing expanses. (Operations Manual 16.14. i.)