Correctness of Automatic Differentiation via Diffeologies and Categorical Gluing
Not on the map. Why?
Abstract (arXiv)
We present semantic correctness proofs of Automatic Differentiation (AD). We consider a forward-mode AD method on a higher order language with algebraic data types, and we characterise it as the unique structure preserving macro given a choice of derivatives for basic operations. We describe a rich semantics for differentiable programming, based on diffeological spaces. We show that it interprets our language, and we phrase what it means for the AD method to be correct with respect to this semantics. We show that our characterisation of AD gives rise to an elegant semantic proof of its correctness based on a gluing construction on diffeological spaces. We explain how this is, in essence, a logical relations argument. Finally, we sketch how the analysis extends to other AD methods by considering a continuation-based method.
Key facts. Cited by 11 papers in the map (data through 7 Oct 2026). First posted on arXiv 7 Jan 2020.
Builds on
No reference list yet.
Built on by
Citing papers per year: 2021: 1; 2022: 2; 2023: 5; 2024: 1; 2025: 0; 2026: 2.
11 papers.
- 2024Probabilistic Programming with Programmable Variational Inferencecited by 4
- 2023On the Correctness of Automatic Differentiation for Neural Networks with Machine-Representable Parameterscited by 3
- 2021Functorial String Diagrams for Reverse-Mode Automatic Differentiationcited by 2
- 2023Automatic Functional Differentiation in JAXcited by 2
- 2023ωPAP Spaces: Reasoning Denotationally About Higher-Order, Recursive Probabilistic and Differentiable Programscited by 1
- 2023Understanding Automatic Differentiation Pitfallscited by 1
- 2022Differentiable Quantum Programming with Unbounded Loopscited by 0
- 2022Efficient and Sound Differentiable Programming in a Functional Array-Processing Languagecited by 0
- 2023nablaSD: Differentiable Programming for Sparse Tensorscited by 0
- 2026GradInf: Gradient Estimation as Probabilistic Inferencecited by 0
- 2026LazyHMC: Hamiltonian Monte Carlo Simulation for Lazy, Infinite Dimensional Probabilistic Programscited by 0
- 2026LazyHMC: Hamiltonian Monte Carlo Simulation for Lazy, Infinite Dimensional Probabilistic Programs9 Aug 2026
- 2026GradInf: Gradient Estimation as Probabilistic Inference8 Jul 2026
- 2024Probabilistic Programming with Programmable Variational Inference22 Jun 2024
- 2023Automatic Functional Differentiation in JAX30 Nov 2023
- 2023Understanding Automatic Differentiation Pitfalls12 May 2023
- 2023nablaSD: Differentiable Programming for Sparse Tensors13 Mar 2023
- 2023ωPAP Spaces: Reasoning Denotationally About Higher-Order, Recursive Probabilistic and Differentiable Programs21 Feb 2023
- 2023On the Correctness of Automatic Differentiation for Neural Networks with Machine-Representable Parameters31 Jan 2023
- 2022Efficient and Sound Differentiable Programming in a Functional Array-Processing Language20 Dec 2022
- 2022Differentiable Quantum Programming with Unbounded Loops8 Nov 2022
- 2021Functorial String Diagrams for Reverse-Mode Automatic Differentiation28 Jul 2021