[ADOL-C] Possible bugs in ADOL-C
Christian Wolf
ChristianLupus at gmx.de
Wed Nov 5 08:09:34 EST 2014
Hello,
I am trying to build/use ADOL-C and I am running into the following issues:
1. I built colpack with MPI (--enable-openmp) support. To allow ADOL-C
to compile I have to use
> LIBS=-lgopm ./configure ....
2. The documentation seems (at least with respect to the sparse driver)
a bit outdated/buggy.
3. (The main bug (?)) As far as I understand things the compresses
hessian matrix (called for example "B") must fullfill the equation B = H
S where S is the seed matrix. Please correct me if this is not correct.
I tried with various builds (2.4.1 and trunk) to compile and run the
program ADOL-C/examples/additional_examples/sparse/sparse_hessian. Just
by looking at the output (no modifications to the SVN version) of the
default output I get
Sparsity pattern of Hessian:
0: 0 1
1: 0 1 4
2: 2 5
3: 3
4: 1 4 5
5: 2 4 5
Seed matrix
0: 1.0000 0.0000 0.0000 0.0000
1: 0.0000 1.0000 0.0000 0.0000
2: 1.0000 0.0000 0.0000 0.0000
3: 1.0000 0.0000 0.0000 0.0000
4: 1.0000 0.0000 0.0000 0.0000
5: 0.0000 0.0000 1.0000 0.0000
<snip>
H
0: 1.0000 0.0000 0.0000 0.0000 0.0000 0.0000
1: 5.0000 3.5787 0.0000 0.0000 0.0000 0.0000
2: 0.0000 0.0000 1.8000 0.0000 0.0000 0.0000
3: 0.0000 0.0000 0.0000 -0.9602 0.0000 0.0000
4: 0.0000 -0.5820 0.0000 0.0000 95.4314 0.0000
5: 0.0000 0.0000 22026.4658 0.0000 79.4007 88169.4721
compressed H: (Here called B)
0: 1.0000 5.0000 0.0000 0.0000
1: 4.4180 3.5787 0.0000 0.0000
2: 1.8000 0.0000 22026.4658 0.0000
3: -0.9602 0.0000 0.0000 0.0000
4: 95.4314 -0.5820 79.4007 0.0000
5: 22105.8665 0.0000 88169.4721 0.0000
Clearly the sparsity pattern is correct (while H shows only the lower
triangle). On manually evaluating the value B[1][0] I get a value of 5.
In [1] the author writes that there are several ways to choose the seed
matrtix. At the moment it seems to be constructed that the i-th row of B
and the j-th column of the seed matrix must be multiplyed (matrix or
scalar product) to obtain H[i][j]. This is (as far as I think) related
to the fact that at the moment the direct approach is used (only
permutation of identy matrix).
Can I rely on this fact that there will be no change in the future to
the default behavior?
Thanks a lot
Christian
[1] "Computing Sparse Hessians with Automatic Differentiation" from
ANDREA WALTHER at the Institute of Scientific Computing, Technische
Universität Dresden
More information about the ADOL-C
mailing list