|
Organizers |
MIPAD : an Automatic Differentiation Package
by
Miloslav Grundmann
MIP - CNRS - University Paul Sabatier - Toulouse
Coauthors: Mohamed Masmoudi
Some existing automatic differentiation packages have general purpose : first and higher order derivatives, computation by the forward and reverse modes, ... (ADOLC, FADBAD, TADIFF, ...).
Mipad is designed to compute higher order derivatives (Taylor's expansion) in an efficient manner.
There are two versions of Mipad. The first one is an arbitrary differentiation order version. It uses operator overloading in C++ to include evaluation of derivatives along with the arithmetic computations. Expression template technique is used to optimize the computed expressions. In order to reduce the number of system calls the memory allocation is optimized using a huge buffer.
We designed also a fixed order version: for a given (arbitrary) differentiation order we have to recompile a specific C++ source file. The generated object code is optimized ; the Taylor's expansion of each variable is not stored in a table but in separated variables and loops are unrolled (they are replaced by a sequence of instructions).
The first version is more flexible but the second one is far more efficient.
The generated code is optimized even if an original code is not. In this way we can avoid a heavy optimization of the original code and save its readability and portability.
The MIPAD library was tested with a Finite Differences Time Domain (FDTD) electromagnetic code and thanks to fixed derivation order version we obtained better than theoretical performance results.
http://mip.ups-tlse.fr/~grundman/ad2000.ps
Date received: February 21, 2000
Copyright © 2000 by the author(s). The author(s) of this document and the organizers of the conference have granted their consent to include this abstract in Atlas Conferences Inc. Document # cads-91.