Boost logo

Boost :

From: Martin Weiser (weiser_at_[hidden])
Date: 2002-02-13 05:12:11

Dear Peter,

here a few comments after a short glance at the code. Take in mind that
I'm no AD expert and may misjudge the situation.

(i) I'd really like to have a templated, lightweight "runtime automatic
differentiation" library available, preferably in boost. My applications
are differential equation solvers, where I need derivatives (up to 2nd)
of medium size arithmetic expressions (one to two lines of code usually).

(ii) However, your library seems to fall short of my needs. In general
one is interested in derivatives with respect to several distinct
variables -- but storing one derivative value right inside the variable
itself looks like the implicit assumption you're differentiating only wrt
exactly one variable.

(iii) There are a lot of automatic differentiation tools available (see, most of which are
preprocessor type solutions. The tool that comes closest to your approach
is ADOL-C (
This is, however, neither templated nor lightweight. There used to be
another C++ AD library around, FADBAD/TADIFF, but it seems to have ceased
to exist.

Conclusion: While I'd like to see some boost-style AD library in boost, I
do suspect your current library design is not sufficient to satisfy any
but the most basic needs. I'd like to encourage you to extend the design
of your library to handle differentiation wrt several variables before
submitting it to boost.


On Tuesday, 12. February 2002 12:06, Peter Schmitteckert wrote:
> Dear All,
> I would like to request comments on a first step towards a
> "Differential Arithmetic Library".
> You can find the sources and a little documentation at
> The main idea of this templated library is to provide the calculation
> of a function including the derivative of the function at a given
> value. The use is as complicated as using complex<double> :).
> Since I'd like to extend this library to include taylor series and
> more intersting things I'd like to ask if this might be interesting
> for Boost and if it's reasonable to spend some effort on boostifying it
> (what ever this means), more specific: is there someone interested in
> using it?
> Best wishes,
> looking forward for your comments,
> Peter

Dr. Martin Weiser            Zuse Institute Berlin
weiser_at_[hidden]                Scientific Computing     Numerical Analysis and Modelling

Boost list run by bdawes at, gregod at, cpdaniel at, john at