Interaction Equivalence
arXiv:2409.18709 · doi:10.1145/3704891
Abstract
Contextual equivalence is the de facto standard notion of program equivalence. A key theorem is that contextual equivalence is an equational theory. Making contextual equivalence more intensional, for example taking into account the time cost of the computation, seems a natural refinement. Such a change, however, does not induce an equational theory, for an apparently essential reason: cost is not invariant under reduction. In the paradigmatic case of the untyped -calculus, we introduce interaction equivalence. Inspired by game semantics, we observe the number of interaction steps between terms and contexts but -- crucially -- ignore their own internal steps. We prove that interaction equivalence is an equational theory and we characterize it as , the well-known theory induced by Böhm tree equality. Ours is the first observational characterization of obtained without enriching the discriminating power of contexts with extra features such as non-determinism. To prove our results, we develop interaction-based refinements of the Böhm-out technique and of intersection types.
Version with proof Appendix of the POPL 2025 paper with the same title
References in corpus (7)
- Intersection Types and (Positive) Almost-Sure Termination
- Recurrence Extraction for Functional Programs through Call-by-Push-Value (Extended Version)
- Discriminating Lambda-Terms Using Clocked Boehm Trees
- Normal Form Bisimulations By Value
- Higher-Order Bayesian Networks, Exactly (Extended version)
- Denotational semantics as a foundation for cost recurrence extraction for functional languages
- An Introduction to the Clocked Lambda Calculus