Skip to Main Content
Browse Books & eBooks > Certified Programming with Dep...
The technology of mechanized program verification can play a supporting role in many kinds of research projects in computer science, and related tools for formal proof-checking are seeing increasing adoption in mathematics and engineering. This book provides an introduction to the Coq software for writing and checking mathematical proofs. It takes a practical engineering focus throughout, emphasizing techniques that will help users to build, understand, and maintain large Coq developments and minimize the cost of code change over time. Two topics, rarely discussed elsewhere, are covered in detail: effective dependently typed programming (making productive use of a feature at the heart of the Coq system) and construction of domain-specific proof tactics. Almost every subject covered is also relevant to interactive computer theorem proving in general, not just program verification, demonstrated through examples of verified programs applied in many different sorts of formalizations. The book develops a unique automated proof style and applies it throughout; even experienced Coq users may benefit from reading about basic Coq concepts from this novel perspective. The book also offers a library of tactics, or programs that find proofs, designed for use with examples in the book. Readers will acquire the necessary skills to reimplement these tactics in other settings by the end of the book. All of the code appearing in the book is freely available online.
MIT Press eBook Chapters
| Quick Abstract | Full Text: PDF
This chapter contains sections titled: Half Title, Title, Copyright, Contents, Acknowledgement View full abstract»
This chapter contains sections titled: 1.1 Whence This Book?, 1.2 Why Coq?, 1.3 Why Not a Different Dependently Typed Language?, 1.4 Engineering with a Proof Assistant, 1.5 Prerequisites, 1.6 Using This Book View full abstract»
This chapter contains sections titled: 2.1 Arithmetic Expressions over Natural Numbers, 2.2 Typed Expressions View full abstract»
The technology of mechanized program verification can play a supporting role in many kinds of research projects in computer science, and related tools for formal proof-checking are seeing increasing adoption in mathematics and engineering. This book provides an introduction to the Coq software for writing and checking mathematical proofs. It takes a practical engineering focus throughout, emphasizing techniques that will help users to build, understand, and maintain large Coq developments and minimize the cost of code change over time. Two topics, rarely discussed elsewhere, are covered in detail: effective dependently typed programming (making productive use of a feature at the heart of the Coq system) and construction of domain-specific proof tactics. Almost every subject covered is also relevant to interactive computer theorem proving in general, not just program verification, demonstrated through examples of verified programs applied in many different sorts of formalizations. The book develops a unique automated proof style and applies it throughout; even experienced Coq users may benefit from reading about basic Coq concepts from this novel perspective. The book also offers a library of tactics, or programs that find proofs, designed for use with examples in the book. Readers will acquire the necessary skills to reimplement these tactics in other settings by the end of the book. All of the code appearing in the book is freely available online. View full abstract»
This chapter contains sections titled: 3.1 Proof Terms, 3.2 Enumerations, 3.3 Simple Recursive Types, 3.4 Parameterized Types, 3.5 Mutually Inductive Types, 3.6 Reflexive Types, 3.7 An Interlude on Induction Principles, 3.8 Nested Inductive Types, 3.9 Manual Proofs about Constructors View full abstract»
This chapter contains sections titled: 4.1 Propositional Logic, 4.2 What Does It Mean to Be Constructive?, 4.3 First-Order Logic, 4.4 Predicates with Implicit Equality, 4.5 Recursive Predicates View full abstract»
This chapter contains sections titled: 5.1 Computing with Infinite Data, 5.2 Infinite Proofs View full abstract»
This chapter contains sections titled: 6.1 Introducing Subset Types, 6.2 Decidable Proposition Types, 6.3 Partial Subset Types, 6.4 Monadic Notations, 6.5 A Type-Checking Example View full abstract»
This chapter contains sections titled: 7.1 Well-Founded Recursion, 7.2 A Nontermination Monad Inspired by Domain Theory, 7.3 Co-inductive Nontermination Monads, 7.4 Comparing the Alternatives View full abstract»
This chapter contains sections titled: 8.1 Length-Indexed Lists, 8.2 The One Rule of Dependent Pattern Matching in Coq, 8.3 A Tagless Interpreter, 8.4 Dependently Typed Red-Black Trees, 8.5 A Certified Regular Expression Matcher View full abstract»
This chapter contains sections titled: 9.1 More Length-Indexed Lists, 9.2 Heterogeneous Lists, 9.3 Recursive Type Definitions, 9.4 Data Structures as Index Functions, 9.5 Choosing between Representations View full abstract»
This chapter contains sections titled: 10.1 The Definitional Equality, 10.2 Heterogeneous Lists Revisited, 10.3 Type Casts in Theorem Statements, 10.4 Heterogeneous Equality, 10.5 Equivalence of Equality Axioms, 10.6 Equality of Functions View full abstract»
This chapter contains sections titled: 11.1 Reifying Datatype Definitions, 11.2 Recursive Definitions, 11.3 Proving Theorems about Recursive Definitions View full abstract»
This chapter contains sections titled: 12.1 The Type Hierarchy, 12.2 The Prop Universe, 12.3 Axioms View full abstract»
This chapter contains sections titled: 13.1 Introducing Logic Programming, 13.2 Searching for Underconstrained Values, 13.3 Synthesizing Programs, 13.4 More on auto Hints, 13.5 Rewrite Hints View full abstract»
This chapter contains sections titled: 14.1 Some Built-in Automation Tactics, 14.2 Ltac Programming Basics, 14.3 Functional Programming in Ltac, 14.4 Recursive Proof Search, 14.5 Creating Unification Variables View full abstract»
This chapter contains sections titled: 15.1 Proving Evenness, 15.2 Reifying the Syntax of a Trivial Tautology Language, 15.3 A Monoid Expression Simplifier, 15.4 A Smarter Tautology Solver, 15.5 Building a Reification Tactic That Recurses under Binders View full abstract»
This chapter contains sections titled: 16.1 Ltac Antipatterns, 16.2 Debugging and Maintaining Automation, 16.3 Modules, 16.4 Build Processes View full abstract»
This chapter contains sections titled: 17.1 Dependent de Bruijn Indices, 17.2 Parametric Higher-Order Abstract Syntax View full abstract»
Back to Top