Term Graphs for Computing Derivatives in Imperative Languages

Paul D. Hovland, Boyana Norris, Michelle Mills Strout, Jean Utke

Research output: Contribution to journalArticlepeer-review

Abstract

Automatic differentiation is a technique for the rule-based transformation of a subprogram that computes some mathematical function into a subprogram that computes the derivatives of that function. Automatic differentiation algorithms are typically expressed as operating on a weighted term graph called a linearized computational graph. Constructing this weighted term graph for imperative programming languages such as C/C++ and Fortran introduces several challenges. Alias and definition-use information is needed to construct term graphs for individual statements and then combine them into one graph for a collection of statements. Furthermore, the resulting weighted term graph must be represented in a language-independent fashion to enable the use of AD algorithms in tools for various languages. We describe the construction and representation of weighted term graphs for C/C++ and Fortran, as implemented in the ADIC 2.0 and OpenAD/F tools for automatic differentiation.

Original languageEnglish (US)
Pages (from-to)99-111
Number of pages13
JournalElectronic Notes in Theoretical Computer Science
Volume176
Issue number1
DOIs
StatePublished - May 28 2007
Externally publishedYes

Keywords

  • automatic differentiation
  • computational graph
  • term graph

ASJC Scopus subject areas

  • Theoretical Computer Science
  • General Computer Science

Fingerprint

Dive into the research topics of 'Term Graphs for Computing Derivatives in Imperative Languages'. Together they form a unique fingerprint.

Cite this