skip to main content
article

Implementation of automatic differentiation tools

Published: 14 January 2002 Publication History

Abstract

Automatic differentiation is a semantic transformation that applies the rules of differential calculus to source code. It thus transforms a computer program that computes a mathematical function into a program that computes the function and its derivatives. Derivatives play an important role in a wide variety of scientific computing applications, including optimization, solution of nonlinear equations, sensitivity analysis, and nonlinear inverse problems. We describe a simple component architecture for developing tools for automatic differentiation and other mathematically oriented semantic transformations of scientific software. This architecture consists of a compiler-based, language-specific front-end for source transformation, loosely coupled with one or more language-independent "plug-in" transformation modules. The coupling mechanism between the front-end and transformation modules is provided by the XML Abstract Interface Form (XAIF). XAIF provides an abstract, language-independent representation of language constructs common in imperative languages, such as C and Fortran. We describe the use of this architecture in constructing tools for automatic differentiation of Fortran 77 and ANSI C, and we discuss how access to compiler optimization techniques can enable more efficient derivative augmentation.

References

[1]
ABATE, J., BISCHOF, C., CARLE, A., AND ROH, L. Algorithms and design for a second-order automatic differentiation module. In Proc. Int. Symposium on Symbolic and Algebraic Computing (ISSAC) '97 (New York, 1997), Association of Computing Machinery, pp. 149-155.
[2]
AIF Developer's Page. www-unix.mcs.anl.gov/autodiff/AIF.
[3]
BARTHOLOMEW-BIGGS, M. OPFAD - a users guide to the OPtima Forward Automatic Differentiation tool. Tech. rep., Numerical Optimization Centre, University of Hertfordsshire, 1995.
[4]
BENDTSEN, C., AND STAUNING, O. FADBAD, A Flexible C++ Package for Automatic Differentiation, Using the Forward and Backward Methods. Tech. Rep. IMM-REP-1996-17, Department of Mathematical Modelling, Technical University of Denmark, Aug. 1996.
[5]
BERZ, M. High-order computation and normal form analysis of repetitive systems. In Physics of Particle Accelerators, M. Month, Ed., vol. AIP 249. American Institute of Physics, Woodbury, NY, 1991, p. 456.
[6]
BERZ, M., BISCHOF, C., CORLISS, G., AND GRIEWANK, A. Computational Differentiation: Techniques, Applications, and Tools. SIAM, Philadelphia, 1996.
[7]
BISCHOF, C. Automatic differentiation and numerical software design. In The Quality of Numerical Software: Assessment and Enhancement (London, 1997), R. Boisvert, Ed., Chapman & Hall, pp. 287-299.
[8]
BISCHOF, C., CARLE, A., CORLISS, G., GRIEWANK, A., AND HOVLAND, P. ADIFOR: Generating derivative codes from Fortran programs. Scientific Programming 1, 1 (1992), 11-29.
[9]
BISCHOF, C., CARLE, A., KHADEMI, P., AND MAUER, A. ADIFOR 2.0: Automatic differentiation of Fortran 77 programs. IEEE Computational Science & Engineering 3, 3 (1996), 18-32.
[10]
BISCHOF, C., CARLE, A., KHADEMI, P., MAUER, A., AND HOVLAND, P. ADIFOR 2.0 user's guide (Revision C). Tech. Rep. ANL/MCS-TM-192, Mathematics and Computer Science Division, Argonne National Laboratory, 1995.
[11]
BISCHOF, C., CORLISS, G., AND GRIEWANK, A. ADIFOR exception handling. Tech. Rep. ANL/MCS-TM-159, Mathematics and Computer Science Division, Argonne National Laboratory, 1991.
[12]
BISCHOF, C., CORLISS, G., AND GRIEWANK, A. Structured second- and higher-order derivatives through univariate Taylor series. Optimization Methods and Software 2 (1993), 211-232.
[13]
BISCHOF, C., AND ROH, L. The automatic differentiation intermediate form (AIF), 1996. Unpublished Information.
[14]
BISCHOF, C., ROH, L., AND MAUER, A. ADIC - An extensible automatic differentiation tool for ANSI-C. Software-Practice and Experience 27, 12 (1997), 1427-1456.
[15]
BISCHOF, C. H., AND HAGHIGHAT, M. R. On hierarchical differentiation. In Computational Differentiation: Techniques, Applications, and Tools, M. Berz, C. Bischof, G. Corliss, and A. Griewank, Eds. SIAM, Philadelphia, 1996, pp. 83-94.
[16]
BROWN, S. OPRAD - a users guide to the OPtima Reverse Automatic Differentiation tool. Tech. rep., Numerical Optimization Centre, University of Hertfordsshire, 1995.
[17]
GIERING, R. Tangent linear and adjoint model compiler, users manual. Unpublished Information, Max-Planck Institut f~r Meteorologie, Hamburg, Germany, 1996.
[18]
GILL, P. E., MURRAY, W., AND WRIGHT, M. H. Practical Optimization. Academic Press, London, 1981.
[19]
GOLDMAN, V. V., AND CATS, G. Automatic adjoint modeling within a program generation framework: A case study for a weather forecasting grid-point model. In Computational Differentiation: Techniques, Applications, and Tools, M. Berz, C. Bischof, G. Corliss, and A. Griewank, Eds. SIAM, Philadelphia, 1996, pp. 185-194.
[20]
GRIEWANK, A. On automatic differentiation. In Mathematical Programming: Recent Developments and Applications (Amsterdam, 1989), Kluwer Academic Publishers, pp. 83-108.
[21]
GRIEWANK, A. Evaluating Derivatives: Principles and Techniques of Algorithmic Differentiation. SIAM, Philadelphia, 2000.
[22]
GRIEWANK, A., JUEDES, D., AND UTKE, J. ADOL-C, a package for the automatic differentiation of algorithms written in C/C++. ACM Transactions on Mathematical Software 22, 2 (1996), 131-167.
[23]
GRIEWANK, A., AND REESE, S. On the calculation of Jacobian matrices by the Markowitz rule. In Automatic Differentiation of Algorithms: Theory, Implementation, and Application, A. Griewank and G. F. Corliss, Eds. SIAM, Philadelphia, 1991, pp. 126-135.
[24]
MONAGAN, M., AND RODONI, R. R. An implementation of the forward and reverse mode of automatic differentiation in Maple. In Computational Differentiation: Techniques, Applications, and Tools, M. Berz, C. Bischof, G. Corliss, and A. Griewank, Eds. SIAM, Philadelphia, 1996, pp. 353-362.
[25]
PRESS, W. H., AND TEUKOLSKY, S. A. Numerical calculation of derivatives. Computers in Physics 5, 1 (Jan./Feb. 1991), 88-89.
[26]
PRYCE, J. D., AND REID, J. K. AD01 - a Fortran 90 code for automatic differentiation. Unpublished information, Rutherford Appleton Laboratory, Oxon, U.K., 1996.
[27]
RALL, L. B. Automatic Differentiation: Techniques and Applications, vol. 120 of Lecture Notes in Computer Science. Springer Verlag, Berlin, 1981.
[28]
ROH, L., HOVLAND, P. D., ABATE, J., AND BISCHOF, C. AIF component system. Unpublished Information.
[29]
ROSTAING, N., DALMAS, S., AND GALLIGO, A. Automatic differentiation in Odyssee. Tellus 45a, 5 (October 1993), 558-568.
[30]
SHIRIAEV, D., AND GRIEWANK, A. ADOL-F: Automatic differentiation of Fortran codes. In Computational Differentiation: Techniques, Applications, and Tools, M. Berz, C. Bischof, G. Corliss, and A. Griewank, Eds. SIAM, Philadelphia, 1996, pp. 375-384.

Cited By

View all

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM SIGPLAN Notices
ACM SIGPLAN Notices  Volume 37, Issue 3
March 2002
142 pages
ISSN:0362-1340
EISSN:1558-1160
DOI:10.1145/509799
Issue’s Table of Contents
  • cover image ACM Conferences
    PEPM '02: Proceedings of the 2002 ACM SIGPLAN workshop on Partial evaluation and semantics-based program manipulation
    January 2002
    146 pages
    ISBN:158113455X
    DOI:10.1145/503032
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 14 January 2002
Published in SIGPLAN Volume 37, Issue 3

Check for updates

Author Tags

  1. Automatic Differentiation
  2. Component Software
  3. Semantic Transformation
  4. intermediate representation
  5. source transformation

Qualifiers

  • Article

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)9
  • Downloads (Last 6 weeks)2
Reflects downloads up to 15 Jan 2025

Other Metrics

Citations

Cited By

View all

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media