Mathematical foundations for symmetric programming and reasoning
Ohad Kammar, Matija Pretnar
Abstract
We develop a mathematical abstraction for uniformly exploiting symmetries in programming and reasoning based on the mathematical proof principle `without-loss-of-generality' (w.l.o.g.). Given: group actions that describe symmetries of the input and the output; and a canoniser, which captures how arbitrary inputs get sent to canonical ones, our construction extends any function from the canonical inputs to the whole domain. We characterise the conditions on the canonisers which guarantee that the construction gives the unique equivariant (i.e. symmetry-preserving) extension. Furthermore, we adapt the construction to a dependently-typed setting, where it captures traditional symmetric w.l.o.g. arguments via the Curry-Howard correspondence. Finally, we extend the construction to algebraic data types, where the symmetries of the constructors both uniquely determine the symmetries of the data type and pave the way for efficient execution.
Create a lesson
Related papers
Countable Nondeterminism in Weighted Programming with an Application to Mechanized Foundations for Probabilistic Program Verification
Shared title terminology · Sebastian Körner, Oliver Emil Bøving, Christoph Matheja
Tenon: A Unified Programming Framework for Retargetable PIM Compilation
Shared title terminology · Niansong Zhang, Shiran Guo, Zhiru Zhang
When Is Program Structure Required? Certificate-Grounded Calibration of Program-Induction Difficulty
Shared title terminology · Wenzhang Du
Statically Typed Purely Functional Definitional Interpreters for Essentials of Programming Languages
Shared title terminology · Kwanghoon Choi
Simulating Quantum Computation Using Probabilistic Programming
Shared title terminology · Yafei Yang, Chung-chieh Shan
Agent-Native by Design: A Programming Language for Agentic Applications
Shared title terminology · Jayanaka Dantanarayana, Savini Kashmira, Xiaoyu Ma et al.