Functional Programming with Hypergraph Transformation
Jin Sano
Key points
From the paper's conclusion- We formalise HyperLMNtal as a term-based graph transformation formalism, then define the syntax and call-by-value semantics of untyped $\lambda_{GT}$ and implement a prototype interpreter.
Abstract
Complex data structures are difficult to manipulate declaratively while preserving their shape invariants. Functional languages offer pattern matching and strong static guarantees, but their type systems primarily describe tree-shaped data. Graph transformation languages support richer structures, yet their state-oriented models do not integrate naturally with value- and function-based programming. This dissertation introduces $\lambda_{GT}$, a functional language that integrates port-hypergraph transformation. It represents complex data as port hypergraphs, manipulates them by pattern matching, and uses types to specify global shape invariants. We formalise HyperLMNtal as a term-based graph transformation formalism, then define the syntax and call-by-value semantics of untyped $\lambda_{GT}$ and implement a prototype interpreter. We develop a core type system for $\lambda_{GT}$, prove its soundness, and relate it to graph-grammar-based typing. We extend the system with linear implication types to describe incomplete graphs arising during pattern matching. The extended system is sound with dynamic pattern-matching checks and is conservative over complete graph types. We also identify a statically safe fragment in which these checks can be eliminated. Finally, we mechanise the definitions and meta-theory in Isabelle/HOL.
Read the paper
Discussion
Science Skim's AI key points, plus readers' public thoughts
Readers' thoughts
No reader thoughts yet.
Related papers
- Programming with Composable Recursive Patterns and TransformationsProceedings of the ACM on Programming Languages · 2026
- Decoupling Data Layouts from Algebraic Data TypesarXiv · 2026
- Type-Checking for Pattern-Based Tree TransformationsarXiv · 2026
- Higher-order bialgebraic semanticsJournal of Functional Programming · 2026
- SymFC: Configurable Semantics for All Paths Symbolic Execution in Haskell via EmbeddingsarXiv · 2026
- Vy ZX: Formal Verification of a Graphical Quantum LanguageACM Transactions on Programming Languages and Systems · 2026