
27 Jun
2005
27 Jun
'05
2:58 a.m.
Benjamin Franksen
Certainly not "of course", because e.g. 'exp' and 'sin' are "of course" applied element-wise in the library proposal.
I wasn't refering to the library proposal. And element-wise definitions of 'exp' and 'sin' for matrices may be natural in certain contexts, but certainly not as /the/ general definition.
Perhaps I haven't followed this discussion closely enough, but I'm not sure this kind of element-wise functions should be provided at all. Isn't a Functor¹ instance (and the consequent "fmap sin") so much clearer that it is worth the extra typing? -k ¹ Or something similar, if you really must preserve the matrix' type. -- If I haven't seen further, it is by standing in the footprints of giants