Re: [eigen] unpleasant surprise mit math functions

[ Thread Index | Date Index | More Archives ]

Hi Helmut,

just out of curiosity:
which unified behavior do you expect for exp(A), sin(A) and cos(A), with A being a dense matrix? If you want it to act on each entry separately, then the result of exp(A) is probably not what a significant number of people may expect. However, using a power series expansion for exp, sin and cos is clearly not equivalent to sin(t.array())...

Best regards,

Quoting Helmut Jarausch <jarausch@xxxxxxxxxxxxxxxxxxx>:

On 09/22/2012 10:21:11 PM, Gael Guennebaud wrote:

there is indeed something very strange happening. I've no idea why
sin(t) with t a VectorXd does compile.


what rational forces one to disallow sin(t) for t beeing a DenseMatrix
Couldn't it be defined resorting to  sin(t.array()) internally?


Mail converted by MHonArc 2.6.19+