
Predicate calculus and program semantics
by Edsger Wybe Dijkstra · first published 1990
15mentions
1recommended by
4HN commenters
2017–2026first – last mentioned
25% recommend75% neutral
Affiliate links. As an Amazon Associate I earn from qualifying purchases.







Dijkstra and Scholten's Predicate Calculus and Program Semantics is a good textbook on the subject. Dijkstra's a Discipline of Programming is much more informal, but I find it more readable and it has a number of good examples.
on “Proofs are Programs – 19th Century Logic and 21st Century Computing (2000) [pdf]” ↗It’s a wonderful book. The “sequel” Predicate Calculus and Program Semantics by Dijkstra and Scholten gives a more rigorous treatment of the ideas presented in A Discipline of Programming. Both are fantastic.
on “A bestiary of single-file implementations of programming languages” ↗…preserve the given invariants, perhaps using TLA+ or something similar. Anyone that wants to learn more on the subject of deriving programs should read one or both of A Discipline of Programming[1] and Predicate Calculus and Program Semantics[2]. The former is more approachable for the programmer who isn't as inclined toward formal mathematics. The latter basically takes the same concepts and treats them with much greater mathematical rigor.…
on “A commemoration of Edsger Dijkstra [pdf]” ↗Dijkstra’s A Discipline of Programming and its spiritual successor that he did with Scholten Predicate Calculus and Program Semantics. They changed how I think about programming.
on “Ask HN: Which books do you consider real gems in your field of work/study?” ↗The predicate calculus. I regularly review Predicate Calculus and Program Semantics[1] to increase my fluency in the techniques. I also recommend A Discipline of Programming[2] as a gentler introduction to the subject for those who do not consider themselves particularly mathematically…
on “Ask HN: What kind of math do you study in your free time?” ↗It sounds like you might appreciate Predicate Calculus and Program Semantics[1] which is a rigorous formal treatment of the subject. Dijkstra's earlier work, A Discipline of Programming[2] lacks mathematical rigor, but is still quite pragmatic and is arguably a much gentler introduction…
on “Vitalik Buterin Proposes New EIP to Tackle Ethereum’s Sky-High Gas Fees” ↗…although you'll definitely want to skim or skip large chunks of it. Also some of the papers are just acerbic observations on life, which some people like and some don't. And there's it's big brother Predicate Calculus and Program Semantics by Dijkstra and Scholten that more rigorously formalizes the same approach. Dafny[2] is one approach out of Microsoft Research that attempts to provide automated tooling around some of those concepts.…
on “Ask HN: Programming Courses for Experienced Coders?” ↗This[1] contains an explanation of his proof format. More generally many of the later monographs from that archive have interesting proofs. Also the book Predicate Calculus and Program Semantics is chock full of proofs. [1] https://www.cs.utexas.edu/users/EWD/transcriptions/EWD13xx/E...
on “The Mechanics of Proof” ↗Really? He is saying that Dijkstra's own book Predicate Calculus and Program Semantics ("D&S") suffered because "in general computer people seem to have a penchant for whipping up homebrew logics," and Codd is another example. Anyway if he were giving Dijkstra's opinion that makes the lack…
on “A Bridge Too Far: E.W. Dijkstra and Logic” ↗I'm actually a fan of dense. If I have to reread a well written paragraph five times to understand that's fine by me. When I'm reading serious non-fiction (currently Predicate Calculus and Program Semantics by Dijkstra and Scholten) I consider it normal to just make it through a handful of pages per day.
on “Rules for Choosing Nonfiction Books” ↗Dijkstra’s A Disciple of Programming is a relatively gentle introduction to this programming style using examples. Predicate Calculus and Program Semantics is a much more rigorous formal treatment of the same subject, but arguably a harder read.
on “Go to Statement Considered Harmful (1968) [pdf]” ↗Amen! Thine Church sits alongside "The Church of Edsger Dijkstra" and his Predicate Calculus and Program Semantics is its bible. Syntax is but mere "ashes and dust" while Semantics are "eternal"! And brother; hast thou forgotten "The Church of Logic Programming"? Ruled over by its venerated Pope, Robert Kowalski,…
on “The Legend of von Neumann (1973) [pdf]” ↗I take it that means you've never read Discipline or Predicate Calculus and Program Semantics. I don't doubt your expertise in TLA+, as I hope you can see from my studious agreement with you on the items that are clearly within your expertise, but on this point you're not even wrong. You are…
on “Using TLA+ in the Real World to Understand a Glibc Bug” ↗https://www.cs.utexas.edu/users/EWD/transcriptions/EWD10xx/E... is an example. That site has many others. Predicate Calculus and Program Semantics is a book that is based on the technique.
on “Leslie Lamport Tells Mathematicians How to Write Proofs (2014)” ↗That certainly sounds like him! Actually I have an even more amazing artifact. He wrote out the entire book "Predicate Calculus and Program Semantics" as a manuscript, beautifully formatted two pages to a letter-sized sheet, page numbers and all. It is nearly perfect but does have a few crossed out bits. I can't find that anywhere online, and just…
on “A handwritten letter from Dijkstra to an aspiring teenager (1989)” ↗