Instituto Superior Técnico

MEIC-A · Instituto Superior Técnico

Software Analysis and Specification

EspSoftCourse Page
  • 6 ECTS
  • P1
  • Exam: Mandatory
Overall
5
3
4
1
3
2
2
1
1
0
3.9
★★★★★
7 ratings
Workload
Very light
2
Light
2
Moderate
2
Heavy
0
Very heavy
0
Light6 ratings

Feedback

2025/2026
★★★★★
Workload:Moderate

9 months ago

This course was mediocre. It is split into 2 distinct parts, with 2 different professors that switch in the middle of course. The project is not very interesting, but also not very difficult. I suggest you attend the lab classes, since they provide you with exercises very similar to the project.

I did not attend a singular theoretical class and I think it would have made no difference if I did, but then again, I cannot give you insight on how useful they are.

★★★★★
Workload:Very light

last year

Project: 2 projects, one in Alloy and one in Dafny. Both projects are easy. Groups of 2.

Exam: The exam isn't as easy as the project but as it doesn't have minimum grade it's easy to pass the course due to the project's grade. The classes are nice, especially from prof. José Fragoso. The problem is that the contents of this course are the most useless I have ever seen. I've never taken a course with so much subjects that I thought "What will I use this for in my life?".

Overall: Great course if you don't want too much workload. It is really easy to pass. The contents are awful. In my opinion, you'll learn nothing valuable.

★★★★★
Workload:Light

last year

It's an easy course but you definitely have to attend the classes to keep up, even though none are mandatory. As long as you attend all the classes you'll barely have to study and will finish with a good grade.

This year the course was split into 2 parts, with 1 project for each part, and a final exam with both parts.

First part was taught by José Fragoso who is a 10/10 professor, and it was very enjoyable. Second part was taught by Bernardo Toninho. This part was ok, but far from as good as the 1st part.

★★★★★
Workload:Light

9 months ago

★★★★★
Workload:Moderate

last year

The reviews below this point may be outdated. Course content, teaching methods, and requirements may have changed since then.

2023/2024
★★★★★
Workload:Very light

last year

Pessoalmente esta cadeira foi das melhores que tive no mestrado e sem dúvida a melhora da especialização de engenharia de software. Basicamente aprendes alguns métodos (em código) que analisam se um programa satisfaz determinadas especificações/condições. A matéria pode não parecer muito interessante, mas o que me fez adorar a cadeira foi o professor Fragoso. Se for este o professor, recomendo a 100% esta cadeira. É um professor excelente, explica muitoooo bem nas aulas, por isso vale muito a pena assistir a todas. O projeto é acessível e bem orientado, grande parte é dada nas aulas também, e o exame é muito semelhante ao projeto.

★★★★★

2 years ago

It's a cool course, and in my opinion, it's the most interesting one in the Software Engineering specialization.

You use formal specification languages to model software and verify code against those specifications. You work with Dafny, where you check preconditions, invariants, and postconditions; and with Alloy, which is an open source language and analyzer for software modeling. Look up these languages to see if you're into them.

All classes were taught by Professor José Fragoso, who is particularly good at explaining this type of material. There are lots of practical exercises during class, and the professor usually points out the kinds of questions that show up in the exam, so students know exactly what they need to study.

Bring a notebook and pen or pencil to class: in this course, you write code, but you also do a lot of sketches and doodles xD.

About the course

Objectives

To be acquainted with formal specifications and formal methods for software engineering, as well as tools/methods for automatic analysis of program properties. This course provides training in: 1. Design and modeling of software systems using a formal specification language. Automated verification of models and their properties. Declarative specification language for expressing constraints and behavior of software systems. States and traces. Static vs dynamic modelling. 2. Verification of programs (functional and imperative) against specifications. Verification of functional properties. Construction of verified programs by annotating code with theorems, pre- and post-conditions, loop invariants, assertions. 3. Techniques and tools for automatic program verification based on abstract interpretation.

Syllabus

Introduction - Motivation for usage of formal specifications and formal methods, motivation for using formal methods tools, and declarative vs operational languages. Specification of Software Systems: Structural modeling of system properties with relational logic and first-order logic and dynamic modeling with linear temporal logic. Applications: test generation for object- oriented programs and modeling of distributed protocols. Tools and frameworks: Alloy, TLA+, and Spin. Verification of Properties of Imperative Programs: Foundations of program logics; Hoare calculus: pre- and post-conditions, loop invariants, and assertions; verification of heap-manipulating programs: permission logics, frame specification, and ghost state; tools Dafny and Viper. Automatic Verification of Program Properties: Abstract interpretation foundations; abstract domains, Galois connections, fixpoint computation, widening and narrowing; frameworks Infer.ai, Astrée, and Redex.

Prerequisites

This course requires familiarity with imperative and object-oriented programming, as well as elementary notions of discrete mathematics.

Cross Competence Component

No explicit soft-skill component. However the two projects, carried out by 2 or 3 students, will promote student's transversal competences in Critical Thinking and Intra-personal Competences.

Laboratorial Component

Exercises on systems modeling: structural and dynamic modeling of software systems with relational logic and linear temporal logic. Test generation and modeling distributed systems with industry-strength specification tools such as the Alloy analyser. Exercises on program logics: writing specifications involving pre- and post-conditions, loop invariants, and assertions. Construction of verified programs using state-of-the-art verification tools such as the Viper and Dafny verification tools. Exercises on automatic program verification with abstract interpretation: design and implementation of abstract interpreters; design and implementation of abstract domains; automatic verification with industrial analysers.

Programming And Computing Component

In the degree where this course is offered the Programming and Computing Component complies with MEPP 2122.

Ethical Principles

All members of a group are responsible for the group's work. In any assessment, every student shall honestly disclose any help received and sources used. In an oral assessment, every student shall be able to present and answer questions about the entire assignment and solution.

Something missing or out of date?

Assessment

Exam (40%) and two projects (30% + 30%)

Has the assessment changed, or is something missing?

Bibliography

Bibliografia Principal

  • Software Abstractions, Logic, Language, and Analysis: Daniel Jackson 2011 MIT Press
    • The Calculus of Computation: Decision Procedures with Applications to Verification: Aaron R. Bradley and Zohar Manna 2007 Springer
    • Developing Verified Programs with Dafny: K. Rustan and M. Leino 2012 Springer
    • Introduction to Static Analysis: An Abstract Interpretation Perspective: X. Rival and K. Yi 2023 MIT Press
    • Principles of Program Analysis Corrected: F. Nielson, H. R. Nielson, C. Hankin 1999 Springer

Missing a book or some materials?