paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Formalising Graph Algorithms with Coinduction

用余归纳形式化图算法
POPL 9(POPL)2025匹配度 2/10 · 论文属于纯形式化验证/定理证明领域(图算法的余归纳形式化),与用户核心研究方向(AI与PL交叉,特别是LLM/Agent用于静态分析/形式化验证)无直接关联,也未涉及浮点或贝叶斯程序分析。引用 2 inbox
Donnacha Oisín Kidney, Nicolas Wu
crossref: 2026-09-10

AI 速览

一句话:提出以余归纳结构为起点的图与图算法形式化理论,并在 Agda 中实现可复用技术。

图及其算法是计算机科学的基础,但在依赖类型证明助手中形式化尤为困难:图不像树或列表那样是良基的归纳数据类型,标准图算法也常不是结构递归。本文不试图把图改造成普通归纳类型,而是从一开始就把图视为余归纳结构,建立图与图算法的形式理论,并在 Agda 中实现。该路线面临 Agda 更擅长归纳而非余归纳、且形式化依赖商类型(quotient types)而商类型会进一步增加余归纳处理难度等挑战。作者发展出可复用技术来应对这些问题;其核心的简洁图表示被证明灵活、强大且可形式化。

问题
在依赖类型证明助手中形式化图及其算法很困难,因为图并非良基归纳类型,标准图算法也常非结构递归。
方法
将图从头视为余归纳结构,在 Agda 中建立图与图算法的形式理论,并开发可复用技术处理余归纳与商类型带来的困难。
评估
通过 Agda 形式化实现来验证该路线;结果显示核心的简洁图表示灵活、强大且可形式化。
原文摘要(Abstract)

Graphs and their algorithms are fundamental to computer science, but they can be difficult to formalise, especially in dependently-typed proof assistants. Part of the problem is that graphs aren’t as well-behaved as inductive data types like trees or lists; another problem is that graph algorithms (at least in standard presentations) often aren’t structurally recursive. Instead of trying to find a way to make graphs behave like other familiar inductive types, this paper builds a formal theory of graphs and their algorithms where graphs are treated as coinductive structures from the beginning. We formalise our theory in Agda. This approach has its own unique challenges: Agda is more comfortable with induction than coinduction. Additionally, our formalisation relies on quotient types, which tend to make coinduction even harder to deal with. Nonetheless, we develop reusable techniques to deal with these difficulties, and the simple graph representation at the heart of our work turns out to be flexible, powerful, and formalisable.

链接与引用

DOI 原文 · PDF(开放获取) · DBLP

BibTeX
@article{KidneyW25,
  title = {Formalising Graph Algorithms with Coinduction},
  author = {Donnacha Oisín Kidney and Nicolas Wu},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {9},
  number = {POPL},
  year = {2025},
  doi = {10.1145/3704892}
}