[ADOL-C] extra arguments
Alfonso Callejo
alcallejo at gmail.com
Fri Mar 9 06:23:09 EST 2012
Hi again,
Here's another question.
Let our function be:
y = myfunction(double x, double aux){
trace_on(0);
adouble xa, auxa;
auxa <<= aux;
xa <<= x;
auxa * xa >>= y;
trace_off();
}
where "aux" is an extra parameter (and therefore we'll only want dy/dx).
As far as I know, dauxa/dx is assumed to be zero. Is there any way of
giving dauxa/dx an initial value (different from zero)? Ideally, it would
be something like:
auxa <<= aux;
auxa.derivative() = whatever
Thanks a lot.
Alfonso
El 6 de marzo de 2012 03:02, Andrea Walther
<awalther at math.uni-paderborn.de>escribió:
> Hi Alfonso,
>
>
> The problem with the approach you suggest is that the evaluation of
>> jacobian() and the other drivers would return, in addition to the "true"
>> derivatives, the derivatives of the dependent variables with respect to
>> those "fake" independent variables, right?
>>
>
> yes that is true. However, usually this would not harm the computing time
> too much and one can just ignore the additional derivatives.
>
> Currently, this is the easiest way to take additional parameters into
> account.
>
> Best regards,
>
>
> Andrea
>
> --
> Prof. Dr. Andrea Walther
> Lehrstuhl fuer Mathematik und ihre Anwendungen
> Institut fuer Mathematik
> Universitaet Paderborn
> Warburger Str. 100
> 33098 Paderborn
>
> Email: andrea.walther at uni-paderborn.**de <andrea.walther at uni-paderborn.de>
> Phone: ++49 5251 602721
> ++49 5251 602724 (sekr.)
> Fax: ++49 5251 603728
>
> **********
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://list.coin-or.org/pipermail/adol-c/attachments/20120309/27fa9e0d/attachment.html>
More information about the ADOL-C
mailing list