Combinatory Adjoints and Differentiation

07/02/2022
by   Martin Elsman, et al.
0

We develop a compositional approach for automatic and symbolic differentiation based on categorical constructions in functional analysis where derivatives are linear functions on abstract vectors rather than being limited to scalars, vectors, matrices or tensors represented as multi-dimensional arrays. We show that both symbolic and automatic differentiation can be performed using a differential calculus for generating linear functions representing Fréchet derivatives based on rules for primitive, constant, linear and bilinear functions as well as their sequential and parallel composition. Linear functions are represented in a combinatory domain-specific language. Finally, we provide a calculus for symbolically computing the adjoint of a derivative without using matrices, which are too inefficient to use on high-dimensional spaces. The resulting symbolic representation of a derivative retains the data-parallel operations from the input program. The combination of combinatory differentiation and computing formal adjoints turns out to be behaviorally equivalent to reverse-mode automatic differentiation. In particular, it provides opportunities for optimizations where matrices are too inefficient to represent linear functions.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
04/05/2019

On the Equivalence of Forward Mode Automatic Differentiation and Symbolic Differentiation

We show that forward mode automatic differentiation and symbolic differe...
research
02/24/2016

Differentiation of the Cholesky decomposition

We review strategies for differentiating matrix-based computations, and ...
research
07/12/2021

On the Computational Complexity of the Chain Rule of Differential Calculus

Many modern numerical methods in computational science and engineering r...
research
12/22/2017

Differential geometry and stochastic dynamics with deep learning numerics

In this paper, we demonstrate how deterministic and stochastic dynamics ...
research
05/24/2019

Landau: language for dynamical systems with automatic differentiation

Most numerical solvers used to determine free variables of dynamical sys...
research
04/24/2019

The differential calculus of causal functions

Causal functions of sequences occur throughout computer science, from th...
research
02/26/2019

Banded Matrix Operators for Gaussian Markov Models in the Automatic Differentiation Era

Banded matrices can be used as precision matrices in several models incl...

Please sign up or login with your details

Forgot password? Click here to reset