commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Luc Maisonobe <Luc.Maison...@free.fr>
Subject Re: [math] Numerical derivatives in Commons Math
Date Fri, 12 Aug 2011 10:35:52 GMT
Hi Sébastien,

Le 12/08/2011 07:50, Sébastien Brisard a écrit :
> As Patrick suggested, this approach should really be extended to
> multivariate functions. To cite but one example, I recently attended a
> conf where Pr. Prevost (Princeton) talked about non-linear finite
> elements calcs. The long standing approach had always been to
> implement the analytical expressions tangent stiffness (which is
> nothing but a jacobian matrix). He argued strongly against it for at
> least two reasons
>    - it is error-prone,
>    - most of the time, the expressions are so complex that their
> evaluation is just as time-consuming as a numerical derivative.

I don't fully agree with this. Both numerical and analytical approach 
are useful and have advantages and drawbacks.

The fact analytical approach is error-prone is true only when analytical 
differentiation is done manually. Using automatic differentiation 
completely removes this problem (take a look at Nabla).

The fact expression are has time consuming as numerical derivatives is 
simply false when speaking about multivariate functions. This result is 
known as the "cheap gradient" property. The relative computing effort 
for gradients or Jacobians using finite differences for an n variables 
function with respect to the basic function evaluation is roughly 2n. 
Using the automatic differentiation technique known as "reverse mode" 
(which is not implemented in Nabla but should be in the unknown future), 
this cost is about 4 and is *independent of n*, which is really an 
amazing result.

> So, having some robust algorithms for multidimensional functions
> already implemented in CM would in my view be invaluable.

I agree with that.

Luc

> Sébastien
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Mime
View raw message