Haskell Matrix Library...
droundy at abridgegame.org
Mon Jun 13 19:11:54 EDT 2005
On Sun, Jun 12, 2005 at 08:00:02PM +0100, Keean Schupke wrote:
> - Standard arithmetic operators do standard matrix operations (except
> "/" is unimplemented - until I write a Gaussian-elimination routine)
It would be nice to at least implement "/" for division by scalars... yes
one could use ./ for that, but it's less nice.
> - 'dot' operators '.*' './' do elementwise operations on matrices, and
> are composed into a matrix level analogue of the
> standard Numeric class hierachy.
> - Any operation involving a scalar applies that operation to each
> element in the matrix.
> - operations in Floating that have no obvious matrix equivalents are
> applied elementwise (sin/cos/tan)
At least sin and cos do have matrix equivalents (imag(mexp(M)), etc)...
> - operations in Floating that have matrix equivalents (exp) are applied
> elementwise for consistancy with the other functions in the Floating
Okay... I don't really expect to use mexp anyways (although it *is* handy
in quantum mechanics, if you can store the entire hamiltonian).
Shouldn't this be an instance of Functor, and have the mmap be called fmap?
I'd would lean towards making 'exp' be matrix exponentiation.
> I will add features as I require them, but if anyone actually wants to
> use it, I will consider patches and requests for features...
I don't suppose there's a chance you could set up a public darcs repository
> Idea's and improvements greatly appreciated...
One thing that would really help would be a nicer show instance. As a
corollary, a read instance would also be nice.
More information about the Libraries