A case study in programming coinductive proofs: Howe’s method
Bisimulation proofs play a central role in programming languages in establishing rich properties such as contextual equivalence. They are also challenging to mechanize, since they require a combination of inductive and coinductive reasoning on open terms. In this paper, we describe mechanizing the p...
Published in: | Mathematical Structures in Computer Science |
---|---|
Main Authors: | , , |
Format: | Article in Journal/Newspaper |
Language: | English |
Published: |
Cambridge University Press (CUP)
2018
|
Subjects: | |
Online Access: | http://dx.doi.org/10.1017/s0960129518000415 https://www.cambridge.org/core/services/aop-cambridge-core/content/view/S0960129518000415 |
id |
crcambridgeupr:10.1017/s0960129518000415 |
---|---|
record_format |
openpolar |
spelling |
crcambridgeupr:10.1017/s0960129518000415 2024-09-15T17:58:56+00:00 A case study in programming coinductive proofs: Howe’s method MOMIGLIANO, ALBERTO PIENTKA, BRIGITTE THIBODEAU, DAVID 2018 http://dx.doi.org/10.1017/s0960129518000415 https://www.cambridge.org/core/services/aop-cambridge-core/content/view/S0960129518000415 en eng Cambridge University Press (CUP) https://www.cambridge.org/core/terms Mathematical Structures in Computer Science volume 29, issue 8, page 1309-1343 ISSN 0960-1295 1469-8072 journal-article 2018 crcambridgeupr https://doi.org/10.1017/s0960129518000415 2024-07-17T04:02:17Z Bisimulation proofs play a central role in programming languages in establishing rich properties such as contextual equivalence. They are also challenging to mechanize, since they require a combination of inductive and coinductive reasoning on open terms. In this paper, we describe mechanizing the property that similarity in the call-by-name lambda calculus is a pre-congruence using Howe’s method in the Beluga formal reasoning system. The development relies on three key ingredients: (1) we give a higher order abstract syntax (HOAS) encoding of lambda terms together with their operational semantics as intrinsically typed terms, thereby avoiding not only the need to deal with binders, renaming and substitutions, but keeping all typing invariants implicit; (2) we take advantage of Beluga ’s support for representing open terms using built-in contexts and simultaneous substitutions: this allows us to directly state central definitions such as open simulation without resorting to the usual inductive closure operation and to encode very elegantly notoriously painful proofs such as the substitutivity of the Howe relation; (3) we exploit the possibility of reasoning by coinduction in Beluga ’s reasoning logic. The end result is succinct and elegant, thanks to the high-level abstractions and primitives Beluga provides. We believe that this mechanization is a significant example that illustrates Beluga ’s strength at mechanizing challenging (co)inductive proofs using HOAS encodings. Article in Journal/Newspaper Beluga Beluga* Cambridge University Press Mathematical Structures in Computer Science 29 8 1309 1343 |
institution |
Open Polar |
collection |
Cambridge University Press |
op_collection_id |
crcambridgeupr |
language |
English |
description |
Bisimulation proofs play a central role in programming languages in establishing rich properties such as contextual equivalence. They are also challenging to mechanize, since they require a combination of inductive and coinductive reasoning on open terms. In this paper, we describe mechanizing the property that similarity in the call-by-name lambda calculus is a pre-congruence using Howe’s method in the Beluga formal reasoning system. The development relies on three key ingredients: (1) we give a higher order abstract syntax (HOAS) encoding of lambda terms together with their operational semantics as intrinsically typed terms, thereby avoiding not only the need to deal with binders, renaming and substitutions, but keeping all typing invariants implicit; (2) we take advantage of Beluga ’s support for representing open terms using built-in contexts and simultaneous substitutions: this allows us to directly state central definitions such as open simulation without resorting to the usual inductive closure operation and to encode very elegantly notoriously painful proofs such as the substitutivity of the Howe relation; (3) we exploit the possibility of reasoning by coinduction in Beluga ’s reasoning logic. The end result is succinct and elegant, thanks to the high-level abstractions and primitives Beluga provides. We believe that this mechanization is a significant example that illustrates Beluga ’s strength at mechanizing challenging (co)inductive proofs using HOAS encodings. |
format |
Article in Journal/Newspaper |
author |
MOMIGLIANO, ALBERTO PIENTKA, BRIGITTE THIBODEAU, DAVID |
spellingShingle |
MOMIGLIANO, ALBERTO PIENTKA, BRIGITTE THIBODEAU, DAVID A case study in programming coinductive proofs: Howe’s method |
author_facet |
MOMIGLIANO, ALBERTO PIENTKA, BRIGITTE THIBODEAU, DAVID |
author_sort |
MOMIGLIANO, ALBERTO |
title |
A case study in programming coinductive proofs: Howe’s method |
title_short |
A case study in programming coinductive proofs: Howe’s method |
title_full |
A case study in programming coinductive proofs: Howe’s method |
title_fullStr |
A case study in programming coinductive proofs: Howe’s method |
title_full_unstemmed |
A case study in programming coinductive proofs: Howe’s method |
title_sort |
case study in programming coinductive proofs: howe’s method |
publisher |
Cambridge University Press (CUP) |
publishDate |
2018 |
url |
http://dx.doi.org/10.1017/s0960129518000415 https://www.cambridge.org/core/services/aop-cambridge-core/content/view/S0960129518000415 |
genre |
Beluga Beluga* |
genre_facet |
Beluga Beluga* |
op_source |
Mathematical Structures in Computer Science volume 29, issue 8, page 1309-1343 ISSN 0960-1295 1469-8072 |
op_rights |
https://www.cambridge.org/core/terms |
op_doi |
https://doi.org/10.1017/s0960129518000415 |
container_title |
Mathematical Structures in Computer Science |
container_volume |
29 |
container_issue |
8 |
container_start_page |
1309 |
op_container_end_page |
1343 |
_version_ |
1810435903856836608 |