[Haskell-cafe] Are there arithmetic composition of functions?
Jerzy Karczmarczuk
jerzy.karczmarczuk at unicaen.fr
Tue Mar 20 14:14:47 CET 2012
Richard O'Keefe :
> You may have no intention of discussing the issue,
> but it seems to*me* that "this will not work in 2012
> Haskell compiler mostly conforming to Haskell 2010
> because Haskell 2010 says it shouldn't work" is a pretty
> sound position to take.
The existence of standards is not an answer concerning their "goodness".
The numerical properties of objects are orthogonal to their "external
representation", and often to the possibility of asking whether they are
equal.
I used Haskell to work with *abstract* vectors in Hilbert space (quantum
states). Here, the linearity, the possibility to copute the
representants (Dirac brackets : scalar products), etc. is essential. And
they are functional objects.
In a slightly more abstract than usual approach to differential
geometry, the concept of vector is far from a classical data structure.
It IS a linear mapping, or, say a differential operator. Again a
functional object.
There are approaches to stream processing, where streams are functions,
and some people would like to add them independently of their
instantiations as sequences of numbers.
==
I think that many people agree that Num was not the best idea... This
class combines the addition with the multiplication, which is not
explicitly natural, and it has been done probably because of the
simplicity of the "vision" of the Authors : there are integer numbers,
there are reals (which ask for a special class with division), and
that's it. You cannot compute the exponential [using the standard name]
of a power series, unless you declare this series, which may be a list
of rational coefficients, a "Floating".
Thank you.
Jerzy Karczmarczuk
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20120320/b1937c3e/attachment.htm>
More information about the Haskell-Cafe
mailing list